装备强星 » 历史记录 » 版本 1
yangdefeng, 2022-05-07 17:48
| 1 | 1 | yangdefeng | |
|---|---|---|---|
| 2 | 标签:模块示例|装备强星 |
||
| 3 | |||
| 4 | *模块说明* |
||
| 5 | 根据条件,筛选出装备列表 |
||
| 6 | 自定义对话框指定位置,生成上述装备列表 |
||
| 7 | 点击装备列表某个单元,将选中单元放入自定义装备位 |
||
| 8 | |||
| 9 | *相关命令* |
||
| 10 | |设置装备列表模板 |[[setModule]] | |
||
| 11 | |将指定实例化装备,放入指定itemBox |[[putinBox]] | |
||
| 12 | |根据筛选条件,取出装备列表 |[[getEquipList]] | |
||
| 13 | |取出装备列表中第1件装备的实例化id |[[getEquipListFirst]] | |
||
| 14 | |\2. | |
||
| 15 | |装备列表模板定义项 |[[dlg_itemInsId_|<itemInsId:]] | |
||
| 16 | |装备列表模板定义项 |[[dlg_itemBoxEx_|<itemBoxEx:]] | |
||
| 17 | |自定义对话框中显示装备列表的属性配置 |[[dlg_equipList_|<equipList:]] | |
||
| 18 | |||
| 19 | *注意事项* |
||
| 20 | #say命令中出现以下命令时, |
||
| 21 | <temList: |
||
| 22 | <itemGrid: |
||
| 23 | <equipList: |
||
| 24 | %{color:deepPink}#say中<>模块必须以“\”结尾% |
||
| 25 | 参见以下脚本示例 |
||
| 26 | |||
| 27 | - |
||
| 28 | - |
||
| 29 | |||
| 30 | *%{color:deepskyblue}特戒引擎脚本示例:%* |
||
| 31 | |||
| 32 | *使用前提1* |
||
| 33 | 请开启配置开关\"isUseCustomOKPanel\" |
||
| 34 | |配置文件|...\Mir200\Tejieconfig\Tejieconfig.txt | |
||
| 35 | |配置节点|[tjconfig] | |
||
| 36 | |配置项 |isUseCustomOkPanel=1 | |
||
| 37 | |||
| 38 | |||
| 39 | *使用前提2* |
||
| 40 | 请配置补丁资源\"lc\",即找到以下配置项,加入 %{color:deeppink}lc% |
||
| 41 | |配置文件|...\Mir200\Tejieconfig\Tejieconfig.txt | |
||
| 42 | |配置节点|[tjconfig] | |
||
| 43 | |配置项 |patch=aa,bb,lc | |
||
| 44 | |||
| 45 | |||
| 46 | *使用前提3* |
||
| 47 | 配置装备类型名称与显示序号 |
||
| 48 | |配置文件|...\Mir200\Tejieconfig\Tejieconfig.txt | |
||
| 49 | |配置节点|[[upGradeItem|[upGradeItem]]] | |
||
| 50 | |||
| 51 | 配置举例 |
||
| 52 | [upGradeItem] |
||
| 53 | 5 1 武器 |
||
| 54 | 10 2 衣服[男] |
||
| 55 | 11 3 衣服[女] |
||
| 56 | 15 4 头盔 |
||
| 57 | 19 5 项链 |
||
| 58 | 26 6 手镯 |
||
| 59 | 22 7 戒指 |
||
| 60 | 64 8 腰带 |
||
| 61 | 62 9 鞋子 |
||
| 62 | |||
| 63 | - |
||
| 64 | - |
||
| 65 | |||
| 66 | bq. [<notextile>@</notextile>main] |
||
| 67 | #act |
||
| 68 | %{color:lightGrey};--设置装备列表模板% |
||
| 69 | [[mov]] s$module (<[[dlg_itemSize_|itemSize]]:400:150:index> %{color:lightGrey};定义装备列表单元宽高% |
||
| 70 | [[inc]] s$module <[[dlg_itemToggle_|itemToggle]]:huishouwupin_xuanzhongkuang:denglu_liebiao_weixuanzhong/<notextile>@</notextile>装备列表点击> %{color:lightGrey};定义装备列表单元选中与未选中图片% |
||
| 71 | inc s$module <[[dlg_itemInsId_|itemInsId]]:instanceId> %{color:lightGrey};道具实例id:程序项,无须定义% |
||
| 72 | inc s$module <[[dlg_itemBoxEx_|itemBoxEx]]:itemId:instanceId:sourceType:equipplace:20:20:wupinkuang:looks:effectname:animation> %{color:lightGrey};定义道具图标在装备列表单元中的坐标% |
||
| 73 | inc s$module <[[dlg_text_|text]]:itemName{scolor=168}:140:30> %{color:lightGrey};定义道具名称在装备列表单元中的文本属性% |
||
| 74 | inc s$module <text:itemType{scolor=25}:160:90>) %{color:lightGrey};定义道具部位名称在装备列表单元中的文本属性% |
||
| 75 | *[[setModule]]* s$module |
||
| 76 | |
||
| 77 | %{color:lightGrey};--设定"身上"与"背包"切换按钮% |
||
| 78 | mov s$切换按钮 ( |
||
| 79 | inc s$切换按钮 <[[dlg_itemIndex_|itemIndex]]:1> |
||
| 80 | inc s$切换按钮 <itemToggle:lc_shijieliaotian_xuanzhong:lc_shijieliaotian_weixuanzhong/<notextile>@</notextile>身背切换(1)> |
||
| 81 | inc s$切换按钮 <text:身上装备{scolor=150}:75:50> |
||
| 82 | inc s$切换按钮 ) |
||
| 83 | |
||
| 84 | inc s$切换按钮 ( |
||
| 85 | inc s$切换按钮 <itemIndex:2> |
||
| 86 | inc s$切换按钮 <itemToggle:lc_shijieliaotian_xuanzhong:lc_shijieliaotian_weixuanzhong/<notextile>@</notextile>身背切换(2)> |
||
| 87 | inc s$切换按钮 <text:背包装备{scolor=150}:75:50> |
||
| 88 | inc s$切换按钮 ) |
||
| 89 | |
||
| 90 | mov s$激活列表 1 |
||
| 91 | goto <notextile>@</notextile>获取装备列表 |
||
| 92 | |
||
| 93 | [<notextile>@</notextile>获取装备列表] |
||
| 94 | #act |
||
| 95 | *[[getEquipList]]* 1 <$str(s$激活列表)> s$装备列表 |
||
| 96 | *[[getEquipListFirst]]* s$装备列表 |
||
| 97 | goto <notextile>@</notextile>星数刷新 |
||
| 98 | goto <notextile>@</notextile>显示界面 |
||
| 99 | goto <notextile>@</notextile>装备列表点击 |
||
| 100 | |
||
| 101 | [<notextile>@</notextile>星数刷新] |
||
| 102 | #act |
||
| 103 | %{color:lightGrey};--获取itemBox中道具星数% |
||
| 104 | [[getItemStarNum]] -1 n$星星数 |
||
| 105 | |
||
| 106 | mov s$item1 (<itemsize:500:100> |
||
| 107 | inc s$item1 <text:星星数<$str(n$星星数)>:150:0>) |
||
| 108 | mov s$itemList <$str(s$item1)> |
||
| 109 | |
||
| 110 | [[refreshItem]] 星数刷新 1 s$item1 0 |
||
| 111 | |
||
| 112 | [<notextile>@</notextile>装备强星] |
||
| 113 | #act |
||
| 114 | [[changeItemUpgradeCount]] -1 + 1 |
||
| 115 | goto <notextile>@</notextile>装备列表点击 %{color:lightGrey};刷新box中的道具tips% |
||
| 116 | |
||
| 117 | [<notextile>@</notextile>装备列表点击] |
||
| 118 | #act |
||
| 119 | %{color:lightGrey};--putinBox 物品唯一id itemBox编号 1身上,2背包% |
||
| 120 | [[putinBox]] <$str(s0)> 0 <$str(s$激活列表)> |
||
| 121 | goto <notextile>@</notextile>星数刷新 |
||
| 122 | |
||
| 123 | [<notextile>@</notextile>显示界面] |
||
| 124 | #act |
||
| 125 | [[openMerchantBigDlg]] lc_chuangti 4 0 0 1 0 0 |
||
| 126 | #say |
||
| 127 | <[[dlg_panelSize_|panelSize]]:700:600>\ |
||
| 128 | <[[dlg_itemGrid_|itemGrid]]:<$str(s$切换按钮)>:切换按钮,<$str(s$激活列表)>,0,1:10:70:220,85:1,2,90,0:1>\ |
||
| 129 | <[[dlg_equipList_|equipList]]:<$str(s$装备列表)>:装备强星,1:20:160:1,715,1:0>\ |
||
| 130 | |
||
| 131 | #if |
||
| 132 | not [[equal]] <$str(s$装备列表)> |
||
| 133 | #say |
||
| 134 | <[[dlg_itemBox_|itemBox]]:0:-100001:0:875:400:50:50:*:251>\ |
||
| 135 | <[[dlg_itemList_|itemList]]:<$str(s$itemList)>:星数刷新:700:500:1,50,0:5>\ |
||
| 136 | <[[dlg_imgButton_|imgButton]]:lc_anniu01:845:715:装备强星/<notextile>@</notextile>装备强星>\ |
||
| 137 | #elseSay |
||
| 138 | <text:没有可装备列表:900:300> |
||
| 139 | |
||
| 140 | [<notextile>@</notextile>身背切换] |
||
| 141 | #if |
||
| 142 | not equal s$激活列表 [[checkScriptParam|<$scriptParam1>]] |
||
| 143 | #act |
||
| 144 | mov s$激活列表 <$scriptParam1> |
||
| 145 | goto <notextile>@</notextile>获取装备列表 |