- Joined
- Jul 25, 2013
- Messages
- 254
- Reaction score
- 582
- First Language
- Portuguese
- Primarily Uses
- RMVXA
Hello people, good night / afternoon / day.
I'm trying to create a checkpoint system, but I could not identify where Game Over is called to be able to replace the code. I imagine there are two ways: when the player loses a battle and when his character dies from damage on the map. The first one I found in the following method of BattleManager:
I tried to just replace the command that calls the GameOver Scene by a line that calls a common event directly (that's how I'm going to base the system), but it did not work. The event is not only not called as, even removing the line, the GameOver Scene starts. The second mode, when player lost HP on the map, I did not even find it. Could someone explain to me how this type of code works? I tried to study this Himeworks code, but I did not understand anything and I do not want to use it because I need to learn how to create my own codes.
Thanks in advance. o/
I'm trying to create a checkpoint system, but I could not identify where Game Over is called to be able to replace the code. I imagine there are two ways: when the player loses a battle and when his character dies from damage on the map. The first one I found in the following method of BattleManager:
Code:
def self.process_defeat
$game_message.add(sprintf(Vocab::Defeat, $game_party.name))
wait_for_message
if @can_lose
revive_battle_members
replay_bgm_and_bgs
SceneManager.return
else
SceneManager.goto(Scene_Gameover)
end
battle_end(2)
return true
end
I tried to just replace the command that calls the GameOver Scene by a line that calls a common event directly (that's how I'm going to base the system), but it did not work. The event is not only not called as, even removing the line, the GameOver Scene starts. The second mode, when player lost HP on the map, I did not even find it. Could someone explain to me how this type of code works? I tried to study this Himeworks code, but I did not understand anything and I do not want to use it because I need to learn how to create my own codes.
Thanks in advance. o/

