In answer to the first problem - spawning only one star at a time.
What you need is a boolean game attribute, say its called 'released' and its initially set to false (unchecked).
Then you need a rule (on the button actor) that says when 1)the push button is touched and 2) game.released = false do : spawn one star and change the game.released attribute to true
That way only one star will be spawned for now.
When you have finished with the star either by getting it in the chest or its dead on the floor you need to change the attribute back to false so that the button will spawn again.
The image problem - you could have a set of images of the treasure chest with one, two, three, multiple stars in it. And then use the change image behavior to change the image accordingly. e.g. when the player gets one star in then delete the star actor and change the chest actor to the image with one star in it.
I hope this helps as a starter, I'm sure the other guys here will add to it.
Comments
In answer to the first problem - spawning only one star at a time.
What you need is a boolean game attribute, say its called 'released' and its initially set to false (unchecked).
Then you need a rule (on the button actor) that says when
1)the push button is touched and
2) game.released = false
do : spawn one star and change the game.released attribute to true
That way only one star will be spawned for now.
When you have finished with the star either by getting it in the chest or its dead on the floor you need to change the attribute back to false so that the button will spawn again.
The image problem - you could have a set of images of the treasure chest with one, two, three, multiple stars in it. And then use the change image behavior to change the image accordingly. e.g. when the player gets one star in then delete the star actor and change the chest actor to the image with one star in it.
I hope this helps as a starter, I'm sure the other guys here will add to it.
Good luck, Philip.