Adding new game modes after first completion

A place to discuss things that aren't specific to any one creator or game.
Forum rules
Ren'Py specific questions should be posted in the Ren'Py Questions and Annoucements forum, not here.
Post Reply
Message
Author
User avatar
thirstyoctopus
Regular
Posts: 72
Joined: Mon Aug 27, 2018 12:04 pm
Projects: Romance Visual Novel story
Organization: Thirsty Octopus
Contact:

Adding new game modes after first completion

#1 Post by thirstyoctopus »

I apologise if this has been asked before but it's difficult to search for exactly what I want and get the right results.

Currently my VN is in production, but I would like to offer the player an opportunity to replay the game but with the characters dressed in different outfits. However, I am unsure as to how to determine if the game has already been completed - so I don't know how to show the new mode link on the start menu (i.e. under what conditions). My guess would be some kind of variable that monitors game progress and once at 100% it would then be classed as "complete"?

I guess, in pseudo code, I mean something like this:

Code: Select all

if game complete:

show menu item "Outfit mode"
This is my first Ren'py game so apologies if this is a really simple thing and I'm just being dumb (!)

Thanks in advance

User avatar
Zelan
Lemma-Class Veteran
Posts: 2436
Joined: Tue Mar 01, 2016 7:23 pm
Completed: The Dark
Projects: Cosplay Couple
Tumblr: evns
itch: Zelan
Discord: ltnkitsuragi#7082
Contact:

Re: Adding new game modes after first completion

#2 Post by Zelan »

I also know next to nothing about coding, but I feel like the easiest thing would just be to have some kind of code that classifies the game as "complete" once you reach the end of the route.

If by "complete" you just mean one route has to be finished, I would just put something like "Complete = True" at the end of each one. (Possibly True/False is not what should be used for this, but I hope this gets across the general idea.)

If by "complete" you mean that every route/ending is completed once, you'll need something different. For this I would code it so that the FIRST time a route/ending is completed, the "complete counter" goes up by one. Once it reaches a certain point the outfit mode is unlocked.

You'll definitely need to find someone else who actually knows their way around Ren'Py for help on the specific code that you need to accomplish this, but I hope what I said above was clear and helpful!

User avatar
thirstyoctopus
Regular
Posts: 72
Joined: Mon Aug 27, 2018 12:04 pm
Projects: Romance Visual Novel story
Organization: Thirsty Octopus
Contact:

Re: Adding new game modes after first completion

#3 Post by thirstyoctopus »

Yes, I thought about that, but would a variable instantiated within the game still be recognisable in the menu and after completion of one route? I wonder if there is some kind of persistent variable which is saved somewhere outside of the 'walls' of the game itself and can be referenced literally anywhere, including in the menu / config etc.

User avatar
parttimestorier
Veteran
Posts: 429
Joined: Thu Feb 09, 2017 10:29 pm
Completed: No Other Medicine, Well Met By Moonlight, RE:BURN, The Light at the End of the Ocean, Take A Hike!, Wizard School Woes
Projects: Seeds of Dreams
itch: janetitor
Location: Canada
Contact:

Re: Adding new game modes after first completion

#4 Post by parttimestorier »

thirstyoctopus wrote: Thu Oct 11, 2018 10:24 am I wonder if there is some kind of persistent variable which is saved somewhere outside of the 'walls' of the game itself and can be referenced literally anywhere, including in the menu / config etc.
There is! Here's the documentation on persistent variables. Just set one of those to true at the end of your game, and you should be able to set whatever else you want to unlock only once it's true.
ImageImageImage

User avatar
thirstyoctopus
Regular
Posts: 72
Joined: Mon Aug 27, 2018 12:04 pm
Projects: Romance Visual Novel story
Organization: Thirsty Octopus
Contact:

Re: Adding new game modes after first completion

#5 Post by thirstyoctopus »

parttimestorier wrote: Thu Oct 11, 2018 10:52 am
thirstyoctopus wrote: Thu Oct 11, 2018 10:24 am I wonder if there is some kind of persistent variable which is saved somewhere outside of the 'walls' of the game itself and can be referenced literally anywhere, including in the menu / config etc.
There is! Here's the documentation on persistent variables. Just set one of those to true at the end of your game, and you should be able to set whatever else you want to unlock only once it's true.
Aha, perfect thank you so much!

User avatar
KouhaiChan
Regular
Posts: 30
Joined: Thu Feb 22, 2018 2:33 am
Projects: He Heard Me
Deviantart: KouhaiChan1
Soundcloud: KouhaiChan
Contact:

Re: Adding new game modes after first completion

#6 Post by KouhaiChan »

gonna bookmark this real quick lol

Post Reply

Who is online

Users browsing this forum: No registered users