Closed boryanagoncharenko closed 20 hours ago
I think option 2 is better, after all skulpt lives in JavScript and I think we could show the alert during the execution of the program, and let it continue, or finish it like we do when someone presses the stopit
button.
Describe the bug The if-pressed command allows variables on the left-hand-side. A variable could be assigned any value including a multi-char value. At the same time the if-pressed logic only allows a single key to be pressed and has no support for combinations of key presses. So, in this case there is no way for the if-pressed statement to be correct.
Paste the Hedy code & level In level 9, execute the following snippet. Note that whatever you type, the output
great
will never get printed.Possible solutions
x = 20 + 1
, the the if-pressed would succeed on pressing the key2
. This solution could be confusing though.