AddUiDlg » 历史记录 » 版本 15
tejie, 2025-11-27 14:07
| 1 | 2 | yangdefeng | h4. _*%{color:green}addUiDlg%*_ |
|---|---|---|---|
| 2 | 1 | machenhe | |
| 3 | 根据约定的ID向对应UI添加自定义内容 |
||
| 4 | |||
| 5 | 9 | tejie | 标签:命令定义^addUiDlg |
| 6 | 1 | machenhe | |
| 7 | *格式* |
||
| 8 | |命令名 |参数1 |参数2 |参数3 |参数4 |参数5 | |
||
| 9 | |addUiDlg |内容id |界面id |显示内容 |坐标(x,y) |平台 | |
||
| 10 | |||
| 11 | 14 | tejie | - |
| 12 | - |
||
| 13 | |||
| 14 | h4. *说明* |
||
| 15 | |||
| 16 | 11 | tejie | |^.参数1|对话框id,模板模式 |
| 17 | 可以向指定系统界面添加多条内容,以此id区别 |
||
| 18 | 模板模式=1,开启模板模式;缺省为非模板模式| |
||
| 19 | 9 | tejie | |^.参数2|[[系统界面id设定]] |
| 20 | %{color:fireBrick}主界面设定% |
||
| 21 | 参数2可写作 *27,锚点id* |
||
| 22 | 27代表主界面 |
||
| 23 | 锚点id 1-9(屏幕9个区域:左上,中上,右上,左中,正中,右中,左下,中下,右下) |
||
| 24 | <notextile></notextile> |
||
| 25 | %{color:fireBrick}非主界面设定% |
||
| 26 | 参数2可写作 系统界面id,子界面id,屏幕锚点id(可缺省) |
||
| 27 | 6 | tejie | 举例 |
| 28 | 3 | yangdefeng | 7,1(系统设置中基础设置界面内添加内容,以基础设置自身左上为锚点) |
| 29 | 1 | machenhe | 7,1,1(系统设置中基础设置界面内添加内容,以屏幕左上为锚点) |
| 30 | 13(充值界面内添加内容,以充值界面自身左上为锚点) |
||
| 31 | 9 | tejie | 13,,7(充值界面内添加内容,以屏幕左下为锚点)| |
| 32 | 1 | machenhe | |^.参数3|需要显示的内容,支持文字、图片、图标、特效 |
| 33 | 参见自定义对话框命令| |
||
| 34 | 14 | tejie | |^.参数4|自定义内容在指定系统UI中的显示位置和层级 |
| 35 | 4.1 指定系统UI中的X坐标 |
||
| 36 | 4.2 指定系统UI中的Y坐标 |
||
| 37 | 4.3 |
||
| 38 | 层级设定,可缺省 |
||
| 39 | 1 say对话框内置顶 |
||
| 40 | 2 全局置顶| |
||
| 41 | 9 | tejie | |^.参数5|平台设定 |
| 42 | 0 手机 |
||
| 43 | 1 PC| |
||
| 44 | 1 | machenhe | |
| 45 | - |
||
| 46 | - |
||
| 47 | |||
| 48 | 2 | yangdefeng | h4. *%{color:deepskyblue}特戒引擎脚本示例:%* |
| 49 | 1 | machenhe | |
| 50 | bq. [<notextile>@</notextile>main] |
||
| 51 | <text:添加自定义UI:50:100/<notextile>@</notextile>添加自定义UI> |
||
| 52 | <text:删除自定义UI:50:200/<notextile>@</notextile>删除自定义UI> |
||
| 53 | |
||
| 54 | [<notextile>@</notextile>添加自定义UI] |
||
| 55 | |
||
| 56 | #act |
||
| 57 | mov s$name1 <text:充值更多优惠,上top166.com{fcolor=251}:0:0> |
||
| 58 | mov s$name2 <text:反馈更多问题,上top166.com{fcolor=251}:0:0> |
||
| 59 | mov s$name3 <text:玩游戏,上top166.com{fcolor=251}:0:0> |
||
| 60 | %{color:lightGrey};充值% |
||
| 61 | 8 | tejie | *{color:green}addUiDlg* 1 13 <$str(s$name1)> 580,-880 0 |
| 62 | 1 | machenhe | %{color:lightGrey};BUG建议% |
| 63 | 8 | tejie | *{color:green}addUiDlg* 1 7,6 <$str(s$name2)> 409,-605 0 |
| 64 | 1 | machenhe | %{color:lightGrey};账号% |
| 65 | addUiDlg 1 7,5 <$str(s$name3)> 409,-489 0 |
||
| 66 | |
||
| 67 | %{color:lightGrey};充值% |
||
| 68 | 8 | tejie | *{color:green}addUiDlg* 1 13 <$str(s$name1)> 580,-880 1 |
| 69 | 1 | machenhe | %{color:lightGrey};BUG建议% |
| 70 | 8 | tejie | *{color:green}addUiDlg* 1 7,6 <$str(s$name2)> 409,-605 1 |
| 71 | 1 | machenhe | %{color:lightGrey};账号% |
| 72 | 8 | tejie | *{color:green}addUiDlg* 1 7,5 <$str(s$name3)> 409,-489 1 |
| 73 | 1 | machenhe | |
| 74 | [<notextile>@</notextile>删除自定义UI] |
||
| 75 | #act |
||
| 76 | 7 | tejie | [[delUiDlg]] 1 13 0 |
| 77 | [[delUiDlg]] 1 7,5 0 |
||
| 78 | [[delUiDlg]] 1 7,6 0 |
||
| 79 | 1 | machenhe | |
| 80 | 7 | tejie | [[delUiDlg]] 1 13 1 |
| 81 | [[delUiDlg]] 1 7,5 1 |
||
| 82 | [[delUiDlg]] 1 7,6 1 |
||
| 83 | 10 | tejie | |
| 84 | - |
||
| 85 | - |
||
| 86 | |||
| 87 | 12 | tejie | h4. *%{color:deepskyblue}模板模式脚本示例:%* |
| 88 | |||
| 89 | 对于反复出现的对话框,可以通过模板模式,提升客户端性能。 |
||
| 90 | |||
| 91 | bq. <notextile>[@main]</notextile> |
||
| 92 | %{color:lightGrey};--刷新 addUiDlg 对话框中的数据% |
||
| 93 | #if |
||
| 94 | #act |
||
| 95 | [[mov]] n0 0 |
||
| 96 | <notextile></notextile> |
||
| 97 | #if |
||
| 98 | #say |
||
| 99 | <notextile><添加获得道具对话框/@添加获得道具对话框></notextile> |
||
| 100 | <notextile></notextile> |
||
| 101 | <notextile>[@添加获得道具对话框]</notextile> |
||
| 102 | %{color:lightGrey};--定义对话框数据模板% |
||
| 103 | #if |
||
| 104 | #act |
||
| 105 | [[mov]] s0 |
||
| 106 | [[inc]] s0 <[[dlg_Img_|img]]:huodewupin_di:0:0:1:/@点地板占位> |
||
| 107 | [[inc]] s0 <[[dlg_Img_|img]]:buji_tanchu_wupinkuangdi:37:20:1::201:45> |
||
| 108 | [[inc]] s0 <[[dlg_Img_|img]]:ui_alpha0:165:-35:::250:130/<notextile>@</notextile>关闭> |
||
| 109 | [[inc]] s0 <[[dlg_ImgButton_|imgButton]]:ui_guanbianniu:200:0:/<notextile>@</notextile>关闭> |
||
| 110 | [[inc]] s0 <[[dlg_itemShow_|itemShow]],<notextile></notextile>*{color:purple}1*<notextile></notextile>:16501:<$str(n0)>:90:90:1> |
||
| 111 | [[inc]] s0 <[[dlg_textex_|textEx]]:获得道具:95:40,28:200,1:1:30> |
||
| 112 | [[inc]] s0 <[[dlg_textex_|textEx]],<notextile></notextile>*{color:purple}2*<notextile></notextile>:经验丹11:95:40,200:210,1:1:30> |
||
| 113 | [[inc]] s0 <[[dlg_Img_|img]]:ui_alpha0:0:200:::250:130/<notextile>@</notextile>使用> |
||
| 114 | [[inc]] s0 <[[dlg_ImgButton_|imgButton]]:ui_anniu_hong_02:60:250:/<notextile>@</notextile>使用> |
||
| 115 | [[inc]] s0 <[[dlg_textex_|textEx]]:使用:95:55,265:190,1:1:30> |
||
| 116 | <notextile></notextile> |
||
| 117 | <notextile></notextile> |
||
| 118 | #if |
||
| 119 | #act |
||
| 120 | [[addUiDlg]] 602,<notextile></notextile>*{color:red}1*<notextile></notextile> 27,5 <$str(s0)> 270,50,1 0 |
||
| 121 | [[inc]] n0 1 |
||
| 122 | <notextile></notextile> |
||
| 123 | %{color:lightGrey};--变动数据赋值% |
||
| 124 | [[setItemShow]] 1 [[dlg_itemShow_|itemShow]],<notextile></notextile>*{color:purple}1*<notextile></notextile>:16501:<$str(n0)>:90:90:1 27 |
||
| 125 | [[setTextEx]] 2 [[dlg_textex_|textEx]],<notextile></notextile>*{color:purple}2*<notextile></notextile>:经验丹<$str(n0)>:95:40,200:210,1:1:30 27 |
||
| 126 | <notextile></notextile> |
||
| 127 | <notextile>[@关闭]</notextile> |
||
| 128 | #if |
||
| 129 | #act |
||
| 130 | [[delUiDlg]] 602 27,5 0 2 |
||
| 131 | |||
| 132 | - |
||
| 133 | - |
||
| 134 | |||
| 135 | 13 | tejie | h4. %{color:LightSeaGreen}示例--addUiDlg支持的循环列表% |
| 136 | 10 | tejie | |
| 137 | 13 | tejie | 脚本下载-->"示例-circleList勾选":http://112.124.36.36/redmine/attachments/download/1223/示例-circleList勾选.7z |
| 138 | 15 | tejie | |
| 139 | - |
||
| 140 | - |
||
| 141 | |||
| 142 | h4. %{color:LightSeaGreen}示例-addUiDlg层级% |
||
| 143 | |||
| 144 | 脚本下载-->"示例-addUiDlg层级":http://112.124.36.36/redmine/attachments/download/1254/示例-addUiDlg层级.7z |