项目

一般

简介

行为

多选背包 » 历史记录 » 修订 1

修订 1/2 | 下一页 »
tejie, 2024-02-20 17:53


多选背包

模块说明
对背包中的道具格,进行勾选。
对勾选结果进行批量处理。

相关命令
openChkBag
打开多选背包界面

setBagGrid
设置指定背包格的选中状态

sbmtBagChk
提交多选结果

delBagGrid
删除指定背包格中的道具

相关qf触发器
[@clkChkBag]
点击多选背包中的格子时,触发
返回以下变量值
s0-格子id
s1-物品名称
s2-物品数量
s3-选中状态

相关系统表
sys_tbl_bagSlct
提交多选结果时,对应的选中结果表
key-背包格id
name字段-物品名称
num字段-物品数量


特戒引擎脚本示例:



[@main]
#say
<打开多选背包/@打开多选背包>\ \
<提交多选结果/@提交多选结果>

[@打开多选背包]
#if
#act
openChkBag

[@提交多选结果]
#if
#act
sbmtBagChk

#if tbl sys_tbl_bagSlct s0
#act
mov s$背包格 <$str(s0)>
mov s$物品名 <$str(sys_tbl_bagSlct,s0,name)>
mov s$数量 <$str(sys_tbl_bagSlct,s0,num)>
delBagGrid s$背包格
;-删除勾选物品同时,可在此处给予对应货币。


--..\Mir200\Envir\Market_Def\QFunction-0.txt
配置触发器

[@clkChkBag]
#if
#act
;-此处是调试信息输出
print 格子--id:<$str(s0)>
print 物品名称:<$str(s1)>
print 物品数量:<$str(s2)>
print 选中状态:<$str(s3)>

#if
;-此处可设定,满足条件才可勾选
equal s3 0
#act
;-满足选中条件的格子,设置为未选中
setBagGrid s0 0
break

#if
equal s3 1
#act
;-满足未选中条件的格子,设置为选中
setBagGrid s0 1
break

tejie 更新于 7 个月 之前 · 1 修订