赞 | 0 |
VIP | 275 |
好人卡 | 23 |
积分 | 1 |
经验 | 53671 |
最后登录 | 2018-3-5 |
在线时间 | 2980 小时 |
Lv1.梦旅人 星君
- 梦石
- 0
- 星屑
- 83
- 在线时间
- 2980 小时
- 注册时间
- 2011-10-9
- 帖子
- 2317
 
|
本帖最后由 皮卡星 于 2011-11-4 00:01 编辑
唔,就是一个hud……- class Goods_Window < Window_Base
- def initialize
- super(0,0,544,88)
- self.opacity = 0
- update
- end
- def update
- if $game_switches[Saba::WAGoods::HIDE_SWITCH]
- self.visible = false
- else
- self.visible = true
- end
- actor = $game_party.members[0]
- draw_actor_hp_menu(actor, 0, 0,"HP")
- end
- def draw_actor_hp_menu(actor, x, y,file)
- bar = Cache.system("goods_bar")
- cw = bar.width * actor.hp / actor.maxhp
- ch = bar.height
- src_rect = Rect.new(0, 0, cw, ch)
- self.contents.blt(x + 437, y - ch + 17, bar, src_rect)
- end
- end
- class Scene_Map < Scene_Base
- alias goods_hud_start start
- def start
- goods_hud_start
- @GOODS_HUD = Goods_Window.new
- end
- alias goods_hud_terminate terminate
- def terminate
- goods_hud_terminate
- @GOODS_HUD.dispose
- end
- alias goods_hud_update update
- def update
- goods_hud_update
- @GOODS_HUD.update
- end
- end
复制代码 嗯,如上……- alias goods_hud_terminate terminate
- def terminate
- goods_hud_terminate
- @GOODS_HUD.dispose
- end
复制代码 请问……明明有.dispose……但是到了其他Scene还显示0 0
如下:
地图显示正常:
菜单里……还留着……囧……:
于是求解决方法 |
|