Pick random scene

letmethink

  • *
  • Posts: 2545
Could you please attach screenshots of the exact code you are using at the moment.
~Letmethink

Innes

  • *
  • Posts: 1961
Yes, please show your code; not typed into your message, but screenshots of your behaviors / events.

Without the code, I can't tell why you need to validate if the scene has been removed, because my example only picks a random scene from a list of scenes that have not yet been selected.

If you are taking a copy of the list as I suggested, then when you remove items from the list, make sure you are using the copy, not the original. This ensures that only available scenes can be picked. Then when the game restarts, you simply create a new copy to work with, from the original 'master' list of scenes.


If you need to keep a record of scenes that have been visited, then each time you remove an item from the scene list, add it to another list called something like 'scenes visited'.
Visit www.TheStencylBook.com - the only published book for learning Stencyl.