Fix stage checking

This commit is contained in:
Paul Kaplan 2018-05-08 17:15:54 -04:00
parent 4713f47fb7
commit 26cfbfe588

View file

@ -251,7 +251,7 @@ const parseMonitorObject = (object, runtime, targets, extensions) => {
let isSpriteLocalVariable; let isSpriteLocalVariable;
if (object.cmd === 'getVar:' || object.cmd === 'contentsOfList:') { if (object.cmd === 'getVar:' || object.cmd === 'contentsOfList:') {
// These monitors are sprite-specific if they are not targetting the stage. // These monitors are sprite-specific if they are not targetting the stage.
isSpriteLocalVariable = object.target.isStage; isSpriteLocalVariable = !target.isStage;
// Variable getters have special block IDs for the toolbox that match the variable ID. // Variable getters have special block IDs for the toolbox that match the variable ID.
block.id = getVariableId(object.param); block.id = getVariableId(object.param);
} }