Project1

标题: 找到一个承担伤害的状态但不知道怎么改成敌人用的求助 [打印本页]

作者: 347780682    时间: 2018-10-19 01:58
标题: 找到一个承担伤害的状态但不知道怎么改成敌人用的求助
哪位大大帮我改下,能让这个状态技能敌人也可以生效

JAVASCRIPT 代码复制
  1. <Custom React Effect>
  2. // Split the damage
  3. value = Math.floor(value / $gameParty.aliveMembers().length);
  4. // Start loop
  5. for (var i = 0; i < $gameParty.aliveMembers().length; i++) {
  6. var actor = $gameParty.aliveMembers()[i];
  7. // Ignore actor if the actor is the target (= Don't damage the target twice)
  8. if (actor === target) { continue };
  9. // Actor loses HP
  10. actor.gainHp(-value);
  11. actor.startDamagePopup();
  12. actor.clearResult();
  13. // Collapse Actor if dead
  14. if (actor.isDead()) { actor.performCollapse() };
  15. };
  16. </Custom React Effect>





欢迎光临 Project1 (https://rpg.blue/) Powered by Discuz! X3.1