GetGuildMaster » 历史记录 » 版本 3
tejie, 2025-09-16 17:11
| 1 | 2 | tejie | h4. _*%{color:green}getGuildMaster%*_ |
|---|---|---|---|
| 2 | |||
| 3 | 1 | yangdefeng | 获得指定行会会长名称 |
| 4 | |||
| 5 | 3 | tejie | |注: |
| 6 | 角色跨服时,无法从主服获取从服玩家的行会信息。 |
||
| 7 | <notextile></notextile> |
||
| 8 | 请在相应跨服表中记录相关信息,比如行会名称,行会会长。 |
||
| 9 | <notextile></notextile> |
||
| 10 | 比如 |
||
| 11 | 用 行会名_服务器id 作为关键字,构建跨服用的行会信息表。 |
||
| 12 | <notextile></notextile> |
||
| 13 | *相关变量* |
||
| 14 | <$crsSverId> 可获得跨服玩家 原服务器id| |
||
| 15 | |||
| 16 | |||
| 17 | 2 | tejie | 标签:命令定义^getGuildMaster |
| 18 | 1 | yangdefeng | |
| 19 | *格式* |
||
| 20 | |命令名 |参数1 |参数2 | |
||
| 21 | |getGuildMaster |待查询行会名 |返回变量 | |
||
| 22 | |||
| 23 | *说明* |
||
| 24 | 2 | tejie | |参数1|待查询行会名字符串| |
| 25 | |参数2|返回存储会长名称的变量| |
||
| 26 | 1 | yangdefeng | |
| 27 | - |
||
| 28 | - |
||
| 29 | |||
| 30 | *%{color:deepskyblue}特戒引擎脚本示例:%* |
||
| 31 | |||
| 32 | bq. [<notextile>@</notextile>main] |
||
| 33 | #say |
||
| 34 | <创建行会/<notextile>@@</notextile>inputString0>\\ \\ |
||
| 35 | <解散行会/<notextile>@</notextile>解散行会>\\ \\ |
||
| 36 | <查询指定行会会长/<notextile>@@</notextile>inputString1>\\ \\ |
||
| 37 | |
||
| 38 | [<notextile>@</notextile>inputString0] |
||
| 39 | #if |
||
| 40 | [[checkGuildName]] s0 |
||
| 41 | #act |
||
| 42 | [[sendMsg]] 6 该行会名称已被占用 |
||
| 43 | break |
||
| 44 | |
||
| 45 | #if |
||
| 46 | not [[haveGuild]] |
||
| 47 | #act |
||
| 48 | [[addGuild]] <$str(s0)> self |
||
| 49 | 3 | tejie | [[sendMsg]] 6 创建行会【<$guildName>】 |
| 50 | 1 | yangdefeng | #elseAct |
| 51 | 3 | tejie | [[sendMsg]] 6 角色已在行会【<$guildName>】中 |
| 52 | 1 | yangdefeng | |
| 53 | [<notextile>@</notextile>解散行会] |
||
| 54 | #if |
||
| 55 | not [[isGuildMaster]] |
||
| 56 | #act |
||
| 57 | 3 | tejie | [[sendMsg]] 6 角色不是行会会长 |
| 58 | 1 | yangdefeng | break |
| 59 | |
||
| 60 | #if |
||
| 61 | #act |
||
| 62 | 3 | tejie | [[mov]] s$行会名称 <$guildName> |
| 63 | [[disband]] |
||
| 64 | [[sendMsg]] 6 解散了行会【<$str(s$行会名称)>】 |
||
| 65 | 1 | yangdefeng | |
| 66 | [<notextile>@</notextile>inputString1] |
||
| 67 | #if |
||
| 68 | not [[checkOfGuild]] <$str(s1)> |
||
| 69 | #act |
||
| 70 | 3 | tejie | [[sendMsg]] 6 没有这个行会 |
| 71 | 1 | yangdefeng | break |
| 72 | |
||
| 73 | #if |
||
| 74 | #act |
||
| 75 | *%{color:green}getGuildMaster%* <$str(s1)> s$行会会长 |
||
| 76 | 3 | tejie | [[sendMsg]] 6 【<$str(s1)>】行会会长是:<$str(s$行会会长)> |