How do I save game without saving layout ?

Get help using Construct 2

Post » Tue May 27, 2014 3:28 pm

Hi.

It's possible to save game state and when is loaded don't go to the layout where game has been saved ?

Thanks
B
11
S
3
Posts: 39
Reputation: 814

Post » Tue May 27, 2014 4:57 pm

I dont think so using the built in save option. When you save it is essentially a snapshot so when you load it back thats what you get.
B
47
S
16
G
9
Posts: 1,097
Reputation: 11,180

Post » Tue May 27, 2014 7:40 pm

You can save just an information using WebStorage. This way, you can do what you want.
B
5
Posts: 10
Reputation: 249

Post » Tue May 27, 2014 7:55 pm

What about:

System -> On Load Complete ---> Go to layout "whereEver"
B
12
S
2
G
1
Posts: 26
Reputation: 835

Post » Wed May 28, 2014 8:37 am

X1 Game Studio wrote:You can save just an information using WebStorage. This way, you can do what you want.


I think i need to do this, the only problem is that i have a lot of arrays to save.

Bonesey wrote:What about:

System -> On Load Complete ---> Go to layout "whereEver"


I tried this and don't work.

Thanks for the opinions
B
11
S
3
Posts: 39
Reputation: 814

Post » Wed May 28, 2014 8:50 am

Another doubt, i need to save game automatically when user closes window or close application. How i do this ?
B
11
S
3
Posts: 39
Reputation: 814

Post » Wed May 28, 2014 2:46 pm

Personally, after my "load game" is complete (so.. on load complete) ... depending on some variables, i call the layout "menu" or "stage", so that works for me.... so far ;)
B
7
S
1
Posts: 25
Reputation: 475

Post » Wed May 28, 2014 3:12 pm

luxvideo wrote:Personally, after my "load game" is complete (so.. on load complete) ... depending on some variables, i call the layout "menu" or "stage", so that works for me.... so far ;)


Can you change my example to help me?
I save my game on layout 2, but when i start the game i need to load and stay in layout 1.

saveExample.capx
You do not have the required permissions to view the files attached to this post.
B
11
S
3
Posts: 39
Reputation: 814

Post » Wed May 28, 2014 7:08 pm

Maybe use a global value to keep track of the game you supposedly loaded, but only load it once you're ready to go from your desired layout the the actual layout that was saved? Basically, trick the player into thinking the game was loaded, but really its not until you select that specific latyout or whatever...
or a hybrid of what I just said...like, have the save option save both the full layout, but also whatever basic info you need in webstorage...then the load feature first just loads the specific data you needed for the first layout, then loads the actual saved layout when the player goes there....make sense?

cheers,
Mike at BrashMonkey
B
49
S
9
G
4
Posts: 425
Reputation: 7,037

Post » Thu May 29, 2014 6:28 pm

let me check into it and get back to you with an alternative :)

cheers!
B
7
S
1
Posts: 25
Reputation: 475

Next

Return to How do I....?

Who is online

Users browsing this forum: AekiroStudio, Linetaru and 8 guests