| 赞 | 0 |
| VIP | |
| 好人卡 | |
| 积分 | 6 |
| 经验 | |
| 最后登录 | 2026-5-4 |
| 在线时间 | 921 小时 |
- 梦石
- 0
- 星屑
- 632
- 在线时间
- 921 小时
- 注册时间
- 2013-3-13
- 回帖
- 503
|
发表于 2016-8-16 09:04:50
|
显示全部楼层
本帖最后由 crow2006 于 2016-8-16 09:08 编辑
- #-------------------------------------------------------------------------------
- #--------打折技能制作,任意队伍成员习得该技能后即可在商店购买物品时享受折扣
- #--------by crow2006 from 66RPG-----------------------------------------------
- #--------20160816---------------------------------------------------------------
- module RPG
- $discount1 = 75 #此处设置打折的百分比 打七五折就填75
- class Item
- def price
- return Integer(@price * $discount1 / 100) if $game_party.discount?
- return @price
- end
- end
-
- class Weapon
- def price
- return Integer(@price * $discount1 / 100) if $game_party.discount?
- return @price
- end
- end
- class Armor
- def price
- return Integer(@price * $discount1 / 100) if $game_party.discount?
- return @price
- end
- end
- end
- class Game_Party < Game_Unit
- def discount?
- $discount2 = 1 #此处设置打折技能的编号
- for actor in members
- return true if actor.skill_learn?($data_skills[$discount2])
- end
- return false
- end
- end
复制代码 |
评分
-
查看全部评分
|