Challenge Mode Add-on?

Dymdez

Newbie-in-Chief
Veteran
Joined
Feb 4, 2014
Messages
752
Reaction score
154
First Language
English
Primarily Uses
Hello RpgMaker addicts,

would it be possible to add a "Challenge Mode" to my game where basically if the player dies at all, their save file is deleted and they have to start over, a sort of "hardcore" mode?
 

Shaz

Veteran
Veteran
Joined
Mar 2, 2012
Messages
40,098
Reaction score
13,704
First Language
English
Primarily Uses
RMMV
I've moved this thread to RGSS3 Script Requests. Please be sure to post your threads in the correct forum next time. Thank you.


Did you search? I'm sure that's been asked before.


fwiw - the first time that happened to me, I'd delete the game.
 

ShadowLurk

Tanoshii~
Veteran
Joined
Feb 14, 2014
Messages
226
Reaction score
53
Primarily Uses
would it be possible to add a "Challenge Mode" to my game where basically if the player dies at all, their save file is deleted and they have to start over, a sort of "hardcore" mode?
You want to make a roguelike?

Anyway, I was sure that I've seen a script that do exactly this. Not sure where, but it is there.
 

Dymdez

Newbie-in-Chief
Veteran
Joined
Feb 4, 2014
Messages
752
Reaction score
154
First Language
English
Primarily Uses
You want to make a roguelike?

Anyway, I was sure that I've seen a script that do exactly this. Not sure where, but it is there.
What is a roguelike?

@Shaz, it's worth nothing to me :)
 

kerbonklin

Hiatus King
Veteran
Joined
Jan 6, 2013
Messages
1,726
Reaction score
275
First Language
English
Primarily Uses
RMMV
Rougelike meaning every play-through is a new experience (usually randomized levels and stuff) from the beginning, and if you die you have to start all over. Trying to get as far as possible, or beating the game.

It's a genre.
 
Last edited by a moderator:

ShadowLurk

Tanoshii~
Veteran
Joined
Feb 14, 2014
Messages
226
Reaction score
53
Primarily Uses
Try this.

$challenge_mode = falseclass Scene_Gameover < Scene_Base    alias :start_permadeath :start  def start    start_permadeath    DataManager.delete_save_file(last_savefile_index) if $challenge_mode  end  endTo make sure the game delete the save on game over, call script:

Code:
$challenge_mode = true
 

Dymdez

Newbie-in-Chief
Veteran
Joined
Feb 4, 2014
Messages
752
Reaction score
154
First Language
English
Primarily Uses
thank you so much
 

Tsukihime

Veteran
Veteran
Joined
Jun 30, 2012
Messages
8,564
Reaction score
3,846
First Language
English
If they have an existing save and they start a new game, you may end up deleting that save even if they didn't load it.
 

Engr. Adiktuzmiko

Chemical Engineer, Game Developer, Using BlinkBoy'
Veteran
Joined
May 15, 2012
Messages
14,682
Reaction score
3,003
First Language
Tagalog
Primarily Uses
RMVXA
yeah, you'd need to make sure that a new game clears the last_save_file thing (assuming the game doesn't do that by default)
 

Dymdez

Newbie-in-Chief
Veteran
Joined
Feb 4, 2014
Messages
752
Reaction score
154
First Language
English
Primarily Uses
oh boy, well, while we figure out the kinks, I would like to describe the idea a bit more.

basically, I want a hardcore mode for my game (purely optional and separate from the rest of the game) and i dont want the hardcore mode saves to interfere with the other game saves -- is this still possible esp considering the 2 posts above?
 

Engr. Adiktuzmiko

Chemical Engineer, Game Developer, Using BlinkBoy'
Veteran
Joined
May 15, 2012
Messages
14,682
Reaction score
3,003
First Language
Tagalog
Primarily Uses
RMVXA
of course...


you can also opt to just use a switch for the hardcore mode so that it is saved into the save file... that way, the non-hardcore mode save-files won't have the hardcore = true... but you still need to make sure that the last_save_file is cleared when starting a new game since if I load a hardcore mode, quit then start a new hardcore mode then die without saving and loading, the old save file will be the one to be removed...
 

ShadowLurk

Tanoshii~
Veteran
Joined
Feb 14, 2014
Messages
226
Reaction score
53
Primarily Uses
I'll just embed the variable with Game_Party. And add something that moves the index away when starting a new game.

Code:
class Game_Party < Game_Unit    attr_accessor :challenge_mode  endmodule DataManager    class <<self; alias :setup_new_game_permadeath :setup_new_game; end  def self.setup_new_game    setup_new_game_permadeath    @last_savefile_index = -1  end  endclass Scene_Gameover < Scene_Base    alias :start_permadeath :start  def start    start_permadeath    DataManager.delete_save_file(last_savefile_index) if $game_party.challenge_mode  end  end
The script call now is
Code:
$game_party.challenge_mode = true
 
Last edited by a moderator:

Dymdez

Newbie-in-Chief
Veteran
Joined
Feb 4, 2014
Messages
752
Reaction score
154
First Language
English
Primarily Uses
All praise ShadowLurk.

He may lurk in the shadows, but when he comes out, he delivers the goods!
 

ShadowLurk

Tanoshii~
Veteran
Joined
Feb 14, 2014
Messages
226
Reaction score
53
Primarily Uses
Well, there is one error there.

Code:
DataManager.delete_save_file(last_savefile_index) if $game_party.challenge_mode
change it to
Code:
DataManager.delete_save_file(DataManager.last_savefile_index) if $game_party.challenge_mode
 

Dymdez

Newbie-in-Chief
Veteran
Joined
Feb 4, 2014
Messages
752
Reaction score
154
First Language
English
Primarily Uses
Thanks again, I will when I get home!
 

Users Who Are Viewing This Thread (Users: 0, Guests: 1)

Latest Threads

Latest Posts

Latest Profile Posts

People3_5 and People3_8 added!

so hopefully tomorrow i get to go home from the hospital i've been here for 5 days already and it's driving me mad. I miss my family like crazy but at least I get to use my own toiletries and my own clothes. My mom is coming to visit soon i can't wait to see her cause i miss her the most. :kaojoy:
Couple hours of work. Might use in my game as a secret find or something. Not sure. Fancy though no? :D
Holy stink, where have I been? Well, I started my temporary job this week. So less time to spend on game design... :(
Cartoonier cloud cover that better fits the art style, as well as (slightly) improved blending/fading... fading clouds when there are larger patterns is still somewhat abrupt for some reason.

Forum statistics

Threads
105,868
Messages
1,017,081
Members
137,582
Latest member
Spartacraft
Top