How to create a checkpoint....
sebmacfly
Member Posts: 1,018
Hi there!
I'm wondering about to how to make a checkpoint...
For exemple, if i lost a live, i would like to restart the scene on the last checkpoint, without losting my items already taked (like coins or keys)
Thanks
I'm wondering about to how to make a checkpoint...
For exemple, if i lost a live, i would like to restart the scene on the last checkpoint, without losting my items already taked (like coins or keys)
Thanks
Comments
Save your points, coins whatever in keys and load them after respawn.
humm.... how i can save the last coordinates and tell the screen and camera to start from that point?
tell him, when overlaps with actor1 change attribute game.checkpointX to self.position.X (or you can add the coordinates manually so they are always constant)
Then you have the coordinate for the checkpoint.
tell the actor (or whatever you want to reset): when gamereset is true spawn actor at game.checkpointX
I don't know what you want to do and what triggers what, but generally you should make yourself comfortable with self and game attributes and if-else commands, otherwise you can't do jack in GS.
Everything is based on those things, so you will use them very VERY often :-)
With my example you can get the picture.