Skip to content

Commit 7051b87

Browse files
authored
Merge pull request #289 from Tacodiva/compiler-sensing-sizeof-fix
Fix incorrect type in sensing () of () block
2 parents 37c6fbe + bc9a3d0 commit 7051b87

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/compiler/irgen.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -530,17 +530,17 @@ class ScriptTreeGenerator {
530530
} else {
531531
switch (property) {
532532
case 'x position':
533-
return new IntermediateInput(InputOpcode.SENSING_OF_POS_X, InputType.NUMBER_REAL, {object});
533+
return new IntermediateInput(InputOpcode.SENSING_OF_POS_X, InputType.NUMBER, {object});
534534
case 'y position':
535-
return new IntermediateInput(InputOpcode.SENSING_OF_POS_Y, InputType.NUMBER_REAL, {object});
535+
return new IntermediateInput(InputOpcode.SENSING_OF_POS_Y, InputType.NUMBER, {object});
536536
case 'direction':
537537
return new IntermediateInput(InputOpcode.SENSING_OF_DIRECTION, InputType.NUMBER_REAL, {object});
538538
case 'costume #':
539539
return new IntermediateInput(InputOpcode.SENSING_OF_COSTUME_NUMBER, InputType.NUMBER_POS_REAL, {object});
540540
case 'costume name':
541541
return new IntermediateInput(InputOpcode.SENSING_OF_COSTUME_NAME, InputType.STRING, {object});
542542
case 'size':
543-
return new IntermediateInput(InputOpcode.SENSING_OF_SIZE, InputType.NUMBER_POS_REAL, {object});
543+
return new IntermediateInput(InputOpcode.SENSING_OF_SIZE, InputType.NUMBER_POS, {object});
544544
}
545545
}
546546

0 commit comments

Comments
 (0)