Envision, Create, Share

Welcome to HBGames, a leading amateur game development forum and Discord server. All are welcome, and amongst our ranks you will find experts in their field from all aspects of video game design and development.

[Resolved] RTAB'S Mysteries - Why when timer is 00:00 Battle closes?

Status
Not open for further replies.
Well like i wrote in title... i'm making a event combo system for skills in battle, but when timer runs to 00:00 the battle closes.
Can i avoid this?
How can i fix it?
 
There are many different ways to do this;
  1. Alias Game_System's "Update" method (stops the timer from updating in battle)
    Code:
    class Game_System
      alias game_system_update update
      def update
        # Unless in battle
        unless $game_temp.in_battle
          game_system_update
        end
      end
    end
    I'd recommend the above method since alias are more compatable.
    or
  2. In Scene_Battle 1's "Update" method remove
    Code:
    $game_system.update
    which stops timer from updating or
    Code:
        # If timer has reached 0
        if $game_system.timer_working and $game_system.timer == 0
          # Abort battle
          $game_temp.battle_abort = true
        end
    which stops it from exiting the battle even when it reaches zero.
Additionally, if you stop the timer from updating, you should probably hide the timer using
Code:
class Sprite_Timer < Sprite
  alias sprite_timer_update update
  def update
    sprite_timer_update
    if $game_temp.in_battle
      # Hide the timer
      self.visible = false
    end
  end
end
 
Wohhoo this sounds reasonable!
Why the hell did they put something that closed battle when timer was at 00:00 i wonder????????
Now i'll try to fix... i suppose i have to change that lines in RTAB lines and not in standard battle system lines... i'll try just now.

EDIT: OHHHH YESSS!!!!! THANK YOUUUUU FINALLY I'LL MANAGE TO CREATE THIS DAMN COMBO SYSTEM!!!!! GREAT!!!!!! AND IT WAS SO SIMPLE, IT'SO SO RIDICOLOUS IT'S LIKE THAT IF YOU HAVE PROBLEM THERE IS VARIABLE $problem = true TO SET TO FALSE HAHA!!!
I'M HILARIOUS MAN! THAAAAAAANKS!
 
Status
Not open for further replies.

Thank you for viewing

HBGames is a leading amateur video game development forum and Discord server open to all ability levels. Feel free to have a nosey around!

Discord

Join our growing and active Discord server to discuss all aspects of game making in a relaxed environment. Join Us

Content

  • Our Games
  • Games in Development
  • Emoji by Twemoji.
    Top