赞 | 0 |
VIP | 0 |
好人卡 | 2 |
积分 | 4 |
经验 | 20278 |
最后登录 | 2024-11-12 |
在线时间 | 296 小时 |
Lv2.观梦者
- 梦石
- 0
- 星屑
- 358
- 在线时间
- 296 小时
- 注册时间
- 2013-6-1
- 帖子
- 121
|
我看直接給腳本好了
在MAIN上面插入即可- #==============================================================================
- # ** Heal On Level Up
- # By Ccoa
- #------------------------------------------------------------------------------
- # When you level up all your HP and SP will be return to max
- #==============================================================================
-
- class Game_Actor < Game_Battler
- alias exp_normal exp
- def exp=(exp)
- [url=home.php?mod=space&uid=13302]@exp[/url] = [[exp, 99999999999].min, 0].max
- # Level up
- while @exp >= @exp_list[@level+1] and @exp_list[@level+1] > 0
- [url=home.php?mod=space&uid=22147]@level[/url] += 1
- # Learn skill
- for j in $data_classes[@class_id].learnings
- if j.level == @level
- learn_skill(j.skill_id)
- end
- end
- # heal
- @hp = self.maxhp
- @sp = self.maxsp
- end
- # Level down
- while @exp < @exp_list[@level]
- @level -= 1
- end
- # Correction if exceeding current max HP and max SP
- @hp = [@hp, self.maxhp].min
- @sp = [@sp, self.maxsp].min
- end
- end
复制代码 |
|