设为首页收藏本站|繁體中文

Project1

 找回密码
 注册会员
搜索

问一下这个yep公式怎么错了

查看数: 74 | 评论数: 3 | 收藏 0
关灯 | 提示:支持键盘翻页<-左 右->
    组图打开中,请稍候......
发布时间: 2024-9-15 20:41

正文摘要:

式子:   <Help Description> :消耗该状态使用特殊技能。每5充能状态升级。 充能一级:双攻+20% 充能二级:额外提升敏捷+35%,命中率+5% 充能三级:tp恢复率+30% 当充能为20时,发生过载,双攻-50% </Help ...

回复

忧郁答辩 发表于 5 天前
KB.Driver 发表于 2024-9-15 20:50
有两处 user.removeStateState,看上去是拼写错误
改成 user.removeState 之后看看:

好的!谢谢了!我不小心复制粘贴两个state了!
KB.Driver 发表于 5 天前
有两处 user.removeStateState,看上去是拼写错误
改成 user.removeState 之后看看:

<Help Description>
:消耗该状态使用特殊技能。每5充能状态升级。
充能一级:双攻+20%
充能二级:额外提升敏捷+35%,命中率+5%
充能三级:tp恢复率+30%
当充能为20时,发生过载,双攻-50%
</Help Description>

// 这里是大佬写的子弹公式,我拿来用
<Custom Battle Effect>
user._ammunition1 = 1;
user.setStateCounter(166, user._ammunition1);
user.clampStateCounter(166, 0, 20);
</Custom Battle Effect>

<Custom Turn Start Effect>
user._ammunition1 = user._ammunition1 || 0;
user.setStateCounter(166, user._ammunition1);
user.clampStateCounter(166, 0, 20);
</Custom Turn Start Effect>

<Custom Action Start Effect>
user._ammunition1 = user._ammunition1 || 0;
user.setStateCounter(166, user._ammunition1);
user.clampStateCounter(166, 0, 20);
</Custom Action Start Effect>

<Custom Action End Effect>
user._ammunition1 = user._ammunition1 || 0;
user.setStateCounter(166, user._ammunition1);
user.clampStateCounter(166, 0, 20);
</Custom Action End Effect>

<Custom Initiate Effect>
user._ammunition1 = user._ammunition1 || 0;
user.setStateCounter(166, user._ammunition1);
user.clampStateCounter(166, 0, 20);
</Custom Initiate Effect>

<Custom Select Effect>
target._ammunition1 = target._ammunition1 || 0;
target.setStateCounter(166, target._ammunition1);
target.clampStateCounter(166, 0, 20);
</Custom Select Effect>

<Custom Confirm Effect>
user._ammunition1 = user._ammunition1 || 0;
user.setStateCounter(166, user._ammunition1);
user.clampStateCounter(166, 0, 20);
</Custom Confirm Effect>

<Custom React Effect>
target._ammunition1 = target._ammunition1 || 0;
target.setStateCounter(166, target._ammunition1);
target.clampStateCounter(166, 0, 20);
</Custom React Effect>

<Custom Respond Effect>
target._ammunition1 = target._ammunition1 || 0;
target.setStateCounter(166, target._ammunition1);
target.clampStateCounter(166, 0, 20);
</Custom Respond Effect>

<Custom Establish Effect>
user._ammunition1 = user._ammunition1 || 0;
user.setStateCounter(166, user._ammunition1);
user.clampStateCounter(166, 0, 20);
</Custom Establish Effect>

<Custom Deselect Effect>
target._ammunition1 = target._ammunition1 || 0;
target.setStateCounter(166, target._ammunition1);
target.clampStateCounter(166, 0, 20);
</Custom Deselect Effect>

<Custom Conclude Effect>
user._ammunition1 = user._ammunition1 || 0;
user.setStateCounter(166, user._ammunition1);
user.clampStateCounter(166, 0, 20);
</Custom Conclude Effect>

// 这下面是不同层不同增益的(我自己照葫芦画瓢写的)

<Custom Turn Start Effect>
if (user._ammunition1>=20) {
user.addState(170)
user.removeState(167)
user.removeState(168)
user.removeState(169);
} else if (user._ammunition1>=15) {
user.addState(169)
user.removeState(167)
user.removeState(168)
user.removeState(170);
} else if (user._ammunition1>=10) {
user.addState(168)
user.removeState(167)
user.removeState(169)
user.removeState(170);
} else if (user._ammunition1>=5) {
user.addState(167)
user.removeState(168)
user.removeState(169)
user.removeState(170); //user.removeStateState(170);
}
</Custom Turn Start Effect>

<Custom Remove Effect>
user.removeState(167)
user.removeState(168)
user.removeState(169)
user.removeState(170); //user.removeStateState(170);
</Custom Remove Effect>
忧郁答辩 发表于 5 天前
这个式子错误的地方是,假如我有12层,我释放技能减了4层,然后当人物回合时候就报错了。不知道怎么做,我这是按着大佬照葫芦画瓢写的,如果有更简单的式子更好了
拿上你的纸笔,建造一个属于你的梦想世界,加入吧。
 注册会员
找回密码

站长信箱:[email protected]|手机版|小黑屋|无图版|Project1游戏制作

GMT+8, 2024-9-20 15:05

Powered by Discuz! X3.1

© 2001-2013 Comsenz Inc.

快速回复 返回顶部 返回列表