脚本详情
传奇自定义变量教程
作者:传奇精英 来源:本站原创 日期:2018/10/22 9:30:26 点击:6082 属于:传奇脚本教程
功能: 自定义变量功能,不再受固定几个变量限制.使用方法: 三个步骤: 1、首先要声明变量 2、读取变量 3、保存变量该变量支持增加、减少、脚本查看、检查大小等功能,该功能的开发突破了变量使用受限制,利用该变量可制作出超强功能脚本。
脚本样例:=========================================<声明变量/@newvarInteger> \<查看变量/@viewvarInteger> \<读取变量/@loadvarInteger> \<保存变量/@savevarInteger> \<增加变量/@calcvarinc> <检查变量是否大于5/@checklarage5>\<减少变量/@calcvardec> <检查变量是否小于5/@checksmall5>\<检查变量是否等于5/@checkequal5>[@calcvarinc]#IF#ACTCALCVAR HUMAN QQQQ + 5 ;脚本命令CALCVAR支持对变量进行+ - * / =五种操作GOTO @varcontrol[@calcvardec]#IF#ACTCALCVAR HUMAN QQQQ - 5GOTO @varcontrol[@checkequal5]#IFCHECKVAR HUMAN QQQQ = 5#ACTSendMsg 7 等于5GOTO @varcontrol#ELSEACTSendMsg 7 不等于5GOTO @varcontrol[@checklarage5]#IF CHECKVAR HUMAN QQQQ > 5#ACT sendmsg 7 大于5 goto @varcontrol#ELSEACT sendmsg 7 小于5 goto @varcontrol[@checksmall5]#IF CHECKVAR HUMAN QQQQ < 5#ACT sendmsg 7 小于5 goto @varcontrol#ELSEACT sendmsg 7 大于5 goto @varcontrol
[@decInteger]
#ACT
DEC QQQQ 1
sendmsg 7 <$HUMAN(QQQQ)>
goto @varcontrol
[@addInteger]
#ACT
INC QQQQ 1
sendmsg 7 <$HUMAN(QQQQ)>
goto @varcontrol
[@loadvarInteger]
#IF
#ACT
LOADVAR HUMAN QQQQ VarSave.txt
sendmsg 7 OK
GOTO @varcontrol
[@savevarInteger]
#IF
#ACT
SAVEVAR HUMAN QQQQ VarSave.txt
sendmsg 7 OK
GOTO @varcontrol
[@viewvarInteger]
#ACT
sendmsg 7 <$HUMAN(QQQQ)>
GOTO @varcontrol
[@newvarInteger]
#IF
#ACT
VAR Integer HUMAN QQQQ
sendmsg 7 OK
GOTO @varcontrol
[@viewvarString]
<$HUMAN(QQQS)>
脚本样例:=========================================<声明变量/@newvarInteger> \<查看变量/@viewvarInteger> \<读取变量/@loadvarInteger> \<保存变量/@savevarInteger> \<增加变量/@calcvarinc> <检查变量是否大于5/@checklarage5>\<减少变量/@calcvardec> <检查变量是否小于5/@checksmall5>\<检查变量是否等于5/@checkequal5>[@calcvarinc]#IF#ACTCALCVAR HUMAN QQQQ + 5 ;脚本命令CALCVAR支持对变量进行+ - * / =五种操作GOTO @varcontrol[@calcvardec]#IF#ACTCALCVAR HUMAN QQQQ - 5GOTO @varcontrol[@checkequal5]#IFCHECKVAR HUMAN QQQQ = 5#ACTSendMsg 7 等于5GOTO @varcontrol#ELSEACTSendMsg 7 不等于5GOTO @varcontrol[@checklarage5]#IF CHECKVAR HUMAN QQQQ > 5#ACT sendmsg 7 大于5 goto @varcontrol#ELSEACT sendmsg 7 小于5 goto @varcontrol[@checksmall5]#IF CHECKVAR HUMAN QQQQ < 5#ACT sendmsg 7 小于5 goto @varcontrol#ELSEACT sendmsg 7 大于5 goto @varcontrol
[@decInteger]
#ACT
DEC QQQQ 1
sendmsg 7 <$HUMAN(QQQQ)>
goto @varcontrol
[@addInteger]
#ACT
INC QQQQ 1
sendmsg 7 <$HUMAN(QQQQ)>
goto @varcontrol
[@loadvarInteger]
#IF
#ACT
LOADVAR HUMAN QQQQ VarSave.txt
sendmsg 7 OK
GOTO @varcontrol
[@savevarInteger]
#IF
#ACT
SAVEVAR HUMAN QQQQ VarSave.txt
sendmsg 7 OK
GOTO @varcontrol
[@viewvarInteger]
#ACT
sendmsg 7 <$HUMAN(QQQQ)>
GOTO @varcontrol
[@newvarInteger]
#IF
#ACT
VAR Integer HUMAN QQQQ
sendmsg 7 OK
GOTO @varcontrol
[@viewvarString]
<$HUMAN(QQQS)>
打击盗版支持正版游戏,任何组织或个人未经同意,不得使用和传播盗版游戏 桂ICP备2022007420号
承接:传奇零基础技术培训,传奇SF一条龙,传奇改版本,传奇新增功能,传奇版本模仿,网站制作,服务器,免备案空间域名
免责声明:本站内容均自动采集互联网,请在下载后24小时内删除,如果侵犯您的权益,请致邮箱sunshine19231@qq.com,我们会及时删除侵权内容