I really don’t understand how you make a switch. I have browsed similar questions and tried a multitude of things with no success. There are no tutorials online either. I have tried making a switch for days, almost a week now.
From what I understand you need an extra variable to prevent both evens from being true.
What I am trying to do here is:
Curser on “resource icon” ? [YES]
Button released? [YES]
Trigger the action for this event once ----> Action: clicked on the resource icon = 1
If the variable “onResource”/meaning; The Resource scene = 0
Which it starts at, so [YES] we are currently not on the Resource scene.
Then —> onResource = 1
clickedResource = 0
Change the scene to the Resource scene.
When the player is on the Resource scene and clicks on the resource icon, the game should detect that and direct the player back to the main scene.
If the variable onResource = 1
Which we are
If clickedResource = 0
Then —> we go back to the main scene
and tell the computer that we are not on the Resource scene
aka onResource = 0
Does anyone know how to make a switch, please help me.