赞 | 76 |
VIP | 0 |
好人卡 | 0 |
积分 | 97 |
经验 | 554 |
最后登录 | 2024-9-11 |
在线时间 | 570 小时 |
Lv4.逐梦者
- 梦石
- 0
- 星屑
- 9677
- 在线时间
- 570 小时
- 注册时间
- 2017-9-28
- 帖子
- 208
|
再添加下述代码(在更改装备/强制更改装备时做和上面代码一样的操作)即可处理装备附带技能的情况- class Game_Actor
- alias change_equip_skill_not change_equip
- def change_equip(slot_id, item)
- last_skills = skills
- change_equip_skill_not(slot_id, item)
- (skills - last_skills).each do |skill|
- skill_not[skill.id] = SharedSkill[skill.id] if SharedSkill[skill.id]
- end
- (last_skills - skills).each do |skill|
- SharedSkill[skill.id] = skill_not[skill.id] if skill_not[skill.id] >= 0
- end
- end
- alias force_change_equip_skill_not force_change_equip
- def force_change_equip(slot_id, item)
- last_skills = skills
- force_change_equip_skill_not(slot_id, item)
- (skills - last_skills).each do |skill|
- skill_not[skill.id] = SharedSkill[skill.id] if SharedSkill[skill.id]
- end
- (last_skills - skills).each do |skill|
- SharedSkill[skill.id] = skill_not[skill.id] if skill_not[skill.id] >= 0
- end
- end
- end
复制代码 |
评分
-
查看全部评分
|