赞 | 0 |
VIP | 3 |
好人卡 | 7 |
积分 | 7 |
经验 | 34794 |
最后登录 | 2024-2-21 |
在线时间 | 684 小时 |
Lv2.观梦者
- 梦石
- 0
- 星屑
- 719
- 在线时间
- 684 小时
- 注册时间
- 2009-5-29
- 帖子
- 461
|
加入我们,或者,欢迎回来。
您需要 登录 才可以下载或查看,没有帐号?注册会员
x
昨天心血来潮把战斗人数增加到了5个,然后重调了一下BattleStatus的显示,如图:
注意下面有个小三角形~~说明显示不完全~~
轮到5号角色选择指令时会变成这样:
这是什么巫术?
然后我试了一下,将BattleStatus的显示行数调至5以上时就不会有这种情况,一切正常,但是行数4就会悲剧...求指教...
附上BattleStatus的代码:- #encoding:utf-8
- #==============================================================================
- # ■ Window_BattleStatus
- #------------------------------------------------------------------------------
- # 战斗画面中,显示“队伍成员状态”的窗口。
- #==============================================================================
- class Window_BattleStatus < Window_Selectable
- #--------------------------------------------------------------------------
- # ● 初始化对象
- #--------------------------------------------------------------------------
- def initialize
- super(0, 0, window_width, window_height)
- refresh
- self.openness = 0
- self.opacity = 255
- end
- #--------------------------------------------------------------------------
- # ● 获取窗口的宽度
- #--------------------------------------------------------------------------
- def window_width
- Graphics.width
- end
- #--------------------------------------------------------------------------
- # ● 获取窗口的高度
- #--------------------------------------------------------------------------
- def window_height
- fitting_height(visible_line_number)
- end
- #--------------------------------------------------------------------------
- # ● 获取显示行数
- #--------------------------------------------------------------------------
- def visible_line_number
- return 4
- end
- #--------------------------------------------------------------------------
- # ● 获取项目数
- #--------------------------------------------------------------------------
- def item_max
- $game_party.battle_members.size
- end
-
- #--------------------------------------------------------------------------
- # ● 刷新
- #--------------------------------------------------------------------------
- def refresh
- contents.clear
- draw_all_items
- end
- #--------------------------------------------------------------------------
- # ● 绘制项目
- #--------------------------------------------------------------------------
- def draw_item(index)
- actor = $game_party.battle_members[index]
- draw_basic_area(basic_area_rect(index), actor)
- draw_gauge_area(gauge_area_rect(index), actor)
- end
- #--------------------------------------------------------------------------
- # ● 获取基本区域的矩形
- #--------------------------------------------------------------------------
- def basic_area_rect(index)
- rect = item_rect_for_text(index)
- rect.x = index * 100 + 6
- rect.y = 0
- rect.height = 96
- rect.width = 102
- rect
- end
- #--------------------------------------------------------------------------
- # ● 获取值槽区域的矩形
- #--------------------------------------------------------------------------
- def gauge_area_rect(index)
- rect = item_rect_for_text(index)
- rect.x = index * 102 + 6
- rect.y = 0
- rect.width = 102
- rect
- end
- #--------------------------------------------------------------------------
- # ● 获取值槽区域的宽度
- #--------------------------------------------------------------------------
- def gauge_area_width
- return 88
- end
- #--------------------------------------------------------------------------
- # ● 绘制基本区域
- #--------------------------------------------------------------------------
- def draw_basic_area(rect, actor)
- draw_actor_name_bs(actor, rect.x + 2, rect.y, 102)
- draw_actor_icons(actor, rect.x + 4, rect.y + 24, 96)
- end
- #--------------------------------------------------------------------------
- # ● 绘制值槽区域
- #--------------------------------------------------------------------------
- def draw_gauge_area(rect, actor)
- if $data_system.opt_display_tp
- draw_gauge_area_with_tp(rect, actor)
- else
- draw_gauge_area_without_tp(rect, actor)
- end
- end
- #--------------------------------------------------------------------------
- # ● 绘制值槽区域(包括 TP)
- #--------------------------------------------------------------------------
- def draw_gauge_area_with_tp(rect, actor)
- draw_actor_hp(actor, rect.x + 2, rect.y + 24, 88)
- draw_actor_mp(actor, rect.x + 2, rect.y + 48, 88)
- draw_actor_tp(actor, rect.x + 2, rect.y + 72, 88)
- end
- #--------------------------------------------------------------------------
- # ● 绘制值槽区域(不包括 TP)
- #--------------------------------------------------------------------------
- def draw_gauge_area_without_tp(rect, actor)
- draw_actor_hp(actor, rect.x + 0, rect.y, 134)
- draw_actor_mp(actor, rect.x + 144, rect.y, 80)
- end
- #--------------------------------------------------------------------------
- # ● 項目を描画する矩形の取得
- #--------------------------------------------------------------------------
- def item_rect(index)
- rect = Rect.new
- rect.width = 102
- rect.height = 96
- rect.x = index * 103 + 2
- rect.y = 0
- rect
- end
- end
复制代码 |
|