scratchfoundation / scratch-vm

Virtual Machine used to represent, run, and maintain the state of programs for Scratch 3.0
http://scratchfoundation.github.io/scratch-vm/
BSD 3-Clause "New" or "Revised" License
1.21k stars 1.51k forks source link

Edge-triggered(?) hat blocks make the green flag always look active #1948

Open towerofnix opened 5 years ago

towerofnix commented 5 years ago

Expected Behavior

Edge-triggered (extension?) hat blocks shouldn't behave any differently from ordinary hat blocks.

Actual Behavior

Dragging out any hat block from extensions makes it so that the green flag looks active, as though the project is constantly running, even if you click the stop button. (The buttons do what they're supposed to when clicked, but the flag constantly appears active.)

Steps to Reproduce

Drag out a hat block from an extension, like "when button (_) pressed" from LEGO EV3, or "when (...) pressed in order" from Makey Makey.

I can also repro this with "when (loudness/timer) > (N)", so I think it might be a more general issue related to edge-triggered blocks (if that's the right term...I've never worked with hat blocks much).

Operating System and Browser

Firefox 65.0b11, Linux (Debian). I can repro this on scratch.mit.edu as well as llk.github.io/develop.


I think this might be what the user here is seeing: https://scratch.mit.edu/discuss/topic/337846/

thisandagain commented 5 years ago

/cc @cwillisf @kchadha @ericrosenbaum