A little help with my shop system not saving correctly

Get help using Construct 2

Post » Thu Dec 31, 2015 8:01 pm

https://www.mediafire.com/?b2e79a20z71yvwq <---- link to project
E to open inventory

When I try to open the upgrade menu then go back to the main game it resets the upgrade menu. I want it to keep everything in the upgrade menu the same. End goal is after you buy something you can come back and buy the upgraded thing. NOTE in my project there is a shop layout... in this post I am talking about the UPGRADES layout.
B
5
S
1
Posts: 86
Reputation: 571

Post » Thu Dec 31, 2015 11:51 pm

I think it's because of how you're saving and loading the game from different slots in your system. The save game function saves and loads the entire game (everything including variables), so loading is wiping any changes you've done. Buying something in the upgrade layout, changing a global variable, and then loading an older save to exit the upgrades, will effectively set the global variable back to what it was in the first place.

An easier way out could be to keep the upgrade menu inside the game layout (perhaps as a global layer) that you turn on and off when you want to buy stuff. Setting timescale to 0 will pause any monster action going on in the background.
B
8
S
2
Posts: 28
Reputation: 546

Post » Fri Jan 01, 2016 12:43 pm

Or just use local storage.
Visual Novel 'Engine' in 100 Events
if you ever have to choose between buying Construct 2 on scirra.com or on Steam, read this: Review
B
22
S
9
G
1
Posts: 787
Reputation: 3,786


Return to How do I....?

Who is online

Users browsing this forum: ijust8, imhotep22, tetuan, Yahoo [Bot] and 1 guest