赞 | 0 |
VIP | 1 |
好人卡 | 28 |
积分 | 2 |
经验 | 9126 |
最后登录 | 2023-2-13 |
在线时间 | 191 小时 |
Lv1.梦旅人
- 梦石
- 0
- 星屑
- 236
- 在线时间
- 191 小时
- 注册时间
- 2010-6-22
- 帖子
- 233
|
回复 退屈£无聊 的帖子
我的脚本:- #==============================================================================
- # ■ Window_BattleResult
- #------------------------------------------------------------------------------
- # 战斗结束时、显示获得的 EXP 及金钱的窗口。
- #==============================================================================
- class Window_BattleResult < Window_Base
- #--------------------------------------------------------------------------
- # ● 初始化对像
- # exp : EXP
- # gold : 金钱
- # treasures : 宝物
- #--------------------------------------------------------------------------
- def initialize(exp, gold, treasures)
- @exp = exp
- @gold = gold
- @treasures = treasures
- for actor in $game_party.actors
- actor.hp += (actor.maxhp-actor.hp)*3/10
- actor.sp += (actor.maxsp-actor.sp)*2/10
- end
- super(160, 0, 320, @treasures.size * 32 + 64)
- self.windowskin = RPG::Cache.windowskin("skin2")
- self.contents = Bitmap.new(width - 32, height - 32)
- self.y = 160 - height / 2
- self.back_opacity = 1000
- self.visible = false
- refresh
- end
- #--------------------------------------------------------------------------
- # ● 刷新
- #--------------------------------------------------------------------------
- def refresh
- self.contents.clear
- x = 4
- self.contents.font.color = normal_color
- cx = contents.text_size(@exp.to_s).width
- self.contents.draw_text(x, 0, cx, 32, @exp.to_s)
- x += cx + 4
- self.contents.font.color = system_color
- cx = contents.text_size("经验").width
- self.contents.draw_text(x, 0, 64, 32, "经验")
- x += cx + 16
- self.contents.font.color = normal_color
- cx = contents.text_size(@gold.to_s).width
- self.contents.draw_text(x, 0, cx, 32, @gold.to_s)
- x += cx + 4
- self.contents.font.color = system_color
- self.contents.draw_text(x, 0, 128, 32, $data_system.words.gold)
- y = 32
- for item in @treasures
- draw_item_name(item, 4, y)
- y += 32
- end
- end
- end
复制代码 刚才的应该加到哪里? |
|