Resetting Stars after Gameover
NilsVeidis
Member Posts: 12
I'm having a problem where if, let's say, I collect 1 of the 3 stars in the level but fall out of the scene, when I come back from game.gameover being true the 1 star that I collected is no longer there (didn't reset the stars).
My rules in Gameover:
Attribute game.gameover is set to true
RULE: When touch is pressed
game.gameover is set to false
Change Attribute game.MainGoalCount to game.Original Star Count
Note there is 1 "MainGoal" in the game/in each level. In attributes MainGoalCount is set to 0.0 (index)
Note there are 3 Stars in the game/in each level. In attributes the Original Star Count is set to 0.0 (index)
The does not have to reset when game.gameover is true for is you get the MainGoal game.LevelComplete is set to true. The only problem are the stars, which are more like collectables and are not necessary.
All help is appreciated! Thanks!
My rules in Gameover:
Attribute game.gameover is set to true
RULE: When touch is pressed
game.gameover is set to false
Change Attribute game.MainGoalCount to game.Original Star Count
Note there is 1 "MainGoal" in the game/in each level. In attributes MainGoalCount is set to 0.0 (index)
Note there are 3 Stars in the game/in each level. In attributes the Original Star Count is set to 0.0 (index)
The does not have to reset when game.gameover is true for is you get the MainGoal game.LevelComplete is set to true. The only problem are the stars, which are more like collectables and are not necessary.
All help is appreciated! Thanks!
Best Answer
-
-Timo- Posts: 2,313you have to make a fake star and set his opacity to 0 so you cant see him.
in this fake star you have to put the rule spawn actor in it so you spawn the real star.
when you collect this star and replay it the star should come back ^^
I hope this helped
good luck
-Timo-
PS. if this is not the solution or you dont understand you can PM me
Answers
Last paragraph should say.
"The MainGoal/MainGoalCountT does not have to reset when game.gameover is true for is you get the MainGoal game.LevelComplete is set to true. The only problem are the stars, which are more like collectables and are not necessary."