I was coding an art prompt generator that will randomly generate 31 art prompts, and none of them would be the same.
My code was basically:
When GENERATE is tapped
Set (Self: Prompt) to random 1 to 60
When (Self: Prompt) = 1
Check Once If (Text 3: Prompt) doesn’t equal 1
Check Once If (Text 2: Prompt) doesn’t equal 1
Set Text to “Aquamarine”
(Also by the way, there were 12 of those Check Once If Else’s in the code, all inside each other, with the Set Text in the middle of them, but that would make this post super long, so yeah.)
The Set Text inside all the Check Once If Else’s never happened in the project, even though I basically rigged the first rule so the value (Self: Prompt) would be set to 1 instead of a random number.
I did recreate the bug to make sure it wasn’t my code:
I used 2 objects in the recreation, with similar code to the prompt generator, but one object had 7 Check Once If Else’s, the other, 6. The second one’s (with 6 Check Once If Else’s) code worked, but the first one (with 7 Check Once If Else’s) didn’t.