About to bang head on keyboard
This has been my two day absolute headache!! Last two days of development spent on trying to figure this out.
I need to reset AND change a scene, and apparently it is not feasible in the physical dimension that I occupy lol. I need TO LEAVE the gameplay screen to go to the highscore scene, but I also NEED TO RESET the gameplay scene so it is fresh for when you try again.
I could reset the whole game, but seriously this has to be easier than I am making it. I've tried boolean values, reset gameplay attributes (i.e. making the retry button change a value, had an actor in the gameplay scene that reset scene when reset gameplay scene integer >0)
GS community if I ever needed you its now!!!
I need to reset AND change a scene, and apparently it is not feasible in the physical dimension that I occupy lol. I need TO LEAVE the gameplay screen to go to the highscore scene, but I also NEED TO RESET the gameplay scene so it is fresh for when you try again.
I could reset the whole game, but seriously this has to be easier than I am making it. I've tried boolean values, reset gameplay attributes (i.e. making the retry button change a value, had an actor in the gameplay scene that reset scene when reset gameplay scene integer >0)
GS community if I ever needed you its now!!!
Comments
For example:
Change lives to 3
Change shields to 10
Change enemieskilled to 0
Change score to 0
etc etc
Then, on your highscore screen, in your 'retry' actor, simply have:
If touched
Go to gameplay screen.
This will go fresh to your gameplay screen and pick up the variable changes in your RESTART actor.
Hope that helps!
QS
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
So you could definitely have it off-screen.
At the start of the level, those attribute changes will fire off immediately. You're then free to have them change as you see fit (as in, get hit, lose 1 life etc).
Cheers,
QS
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
Im getting excited. You have no idea the tricks I have been trying. I didnt know changing attributes happens once, so your logic makes sense. I will always remember my first roadblock in gave development, bc this was it!
Heres to hoping this works....ill let you know in 5
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
weirdest thing is.....when I press "retry" the first time...my game over is still there and then it takes me back to highscore. But when I press it again...it works perfectly like it should the first time.
Also, are you using 'pause' to go to different scenes at all?
QS
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
Yes, I have a pause button that when pressed goes to a pause screen.
I dont know why my game over is showing up, since it should only pop out if the misses=3. I made a display text actor to see if my misses werent resetting right but they are. Its almost more agonizing being so close now!
By the way, thanks for the help!
You might shift those rules that reset stuff to the 'retry' button - change the rule to:
If button is touched
reset stuff
Timer - after .1 seconds
Change scene to gameplay scene.
That might work, though it makes no sense to me why you're having trouble with it the original way I said!
Good luck!
QS
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
I hope it works!
QS
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
Quantumsheep......you are definitely going under my credits!!!
(I hope they're not heavy!)
QS
Dr. Sam Beckett never returned home...
Twitter: https://twitter.com/Quantum_Sheep
Web: https://quantumsheep.itch.io
Quantumsheep:
Thank him next time you hit "retry" and strive for a better round!