Das in ein neues Script unter dem Original kopieren. TURNS_MAX bestimmt, wie viele Runden angezeigt werden. Code: class Window_CombatLog < Window_Selectable TURNS_MAX = 10 #-------------------------------------------------------------------------- # initialize #-------------------------------------------------------------------------- def initialize @data = [] @turn_data = Array.new(TURNS_MAX) { [] } super(0, 0, Graphics.width, Graphics.height-120) deactivate hide end #-------------------------------------------------------------------------- # add_line #-------------------------------------------------------------------------- def add_line(text) return if text == "-" && current_turn.last == "-" current_turn.push(text) end #-------------------------------------------------------------------------- # item_max #-------------------------------------------------------------------------- def item_max @turn_data.inject(0) { |sum, i| sum += i.size } end def data @turn_data.inject(:+) end #-------------------------------------------------------------------------- # draw_item #-------------------------------------------------------------------------- def draw_item(index) text = data[index] return if text.nil? rect = item_rect_for_text(index) if text == "-" draw_horz_line(rect.y) else draw_text_ex(rect.x, rect.y, text) end end def start_turn @turn_data.rotate! current_turn.clear end def current_turn @turn_data.last end end class Scene_Battle < Scene_Base #-------------------------------------------------------------------------- # alias method: turn_start #-------------------------------------------------------------------------- alias scene_battle_turn_start_cld turn_start def turn_start scene_battle_turn_start_cld @combatlog_window.start_turn @combatlog_window.add_line("-") text = sprintf(YEA::COMBAT_LOG::TEXT_TURN_NUMBER, $game_troop.turn_count) @combatlog_window.add_line(text) @combatlog_window.add_line("-") end end Mangels installiertem Maker wie immer ungetestet :3
class Window_CombatLog < Window_Selectable TURNS_MAX = 10 #-------------------------------------------------------------------------- # initialize #-------------------------------------------------------------------------- def initialize @data = [] @turn_data = Array.new(TURNS_MAX) { [] } super(0, 0, Graphics.width, Graphics.height-120) deactivate hide end #-------------------------------------------------------------------------- # add_line #-------------------------------------------------------------------------- def add_line(text) return if text == "-" && current_turn.last == "-" current_turn.push(text) end #-------------------------------------------------------------------------- # item_max #-------------------------------------------------------------------------- def item_max @turn_data.inject(0) { |sum, i| sum += i.size } end def data @turn_data.inject(:+) end #-------------------------------------------------------------------------- # draw_item #-------------------------------------------------------------------------- def draw_item(index) text = data[index] return if text.nil? rect = item_rect_for_text(index) if text == "-" draw_horz_line(rect.y) else draw_text_ex(rect.x, rect.y, text) end end def start_turn @turn_data.rotate! current_turn.clear end def current_turn @turn_data.last end end class Scene_Battle < Scene_Base #-------------------------------------------------------------------------- # alias method: turn_start #-------------------------------------------------------------------------- alias scene_battle_turn_start_cld turn_start def turn_start scene_battle_turn_start_cld @combatlog_window.start_turn @combatlog_window.add_line("-") text = sprintf(YEA::COMBAT_LOG::TEXT_TURN_NUMBER, $game_troop.turn_count) @combatlog_window.add_line(text) @combatlog_window.add_line("-") end end
--"Banjo, you're a BEAR... and I will teach you... THESE MOVES!"
Foren-Regeln