Skip to content

Commit 69c2078

Browse files
committed
handle ??? in jump blocks
1 parent a9fd07f commit 69c2078

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

blockly/src/turtle/blocks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -696,7 +696,7 @@ exports.install = function(blockly, blockInstallOptions) {
696696
generator.jump_by_constant = function() {
697697
// Generate JavaScript for moving forward or backward the internal number
698698
// of pixels without drawing.
699-
var value = window.parseFloat(this.getTitleValue('VALUE'));
699+
var value = window.parseFloat(this.getTitleValue('VALUE')) || 0;
700700
return 'Turtle.' + this.getTitleValue('DIR') +
701701
'(' + value + ', \'block_id_' + this.id + '\');\n';
702702
};

0 commit comments

Comments
 (0)