Second Chance Option

Hello,


Does anybody know how or have any experience with making a second chance option for my game? What I mean by that is when the player dies, a screen pops up saying something like "Watch a video to continue." Then they watch that video which brings them back to the game with their same score. Please let me know if you have any familiarity with that.


Thanks,


Julian

Can you explain what your problem is ?


When the player dies, you are free to save all its parameters, launch the video and then continue the game, isn't it ?

Oh ok. I was not sure it was that simple.


What would the code be to implament this?


Is there any tutorial out there that would help me? I have looked for a while and am yet to find one.

?

Please explain where you have problem. Not just asking for code to copy (anyway, without knowing the context of your game, that's very difficult).


Can you first show how a player is defined (the Player class definition).


Then, what do you do when he/she dies ?


3rd, cause for death : life count to zero ? Other ?

A player is defined by a var statement.


When he/she dies, a code sends the user to another .swift file (GameOverScene.)


The cause for death is a life count to zero correct.

?

Please, answer questions more properly. If you don't want to show anything, it is better to stop here and not ask help in this forum.


A player is defined by a var statement.

of course.

The question was : what is the date type for a player ?


When he/she dies, a code sends the user to another .swift file (GameOverScene.)


of course !

But how ? Do you delete the instance ?

Please show the code ?


The cause for death is a life count to zero

So to revive, you would have to credit life count again.

Ok, I understand. How do I make the video go back to their score when they died after they watched the video? Thats what im confused about.

?

Second Chance Option
 
 
Q