From a1be1d656674a7f3000ef95b69420805a81bd332 Mon Sep 17 00:00:00 2001 From: Tim Mickel Date: Tue, 14 Jun 2016 18:08:41 -0400 Subject: [PATCH] Update playground and block implementations to match scratch-blocks --- playground/index.html | 259 +++++++++++++++++++++++++------ src/blocks/scratch3_operators.js | 6 +- 2 files changed, 213 insertions(+), 52 deletions(-) diff --git a/playground/index.html b/playground/index.html index 3d10a22d0..b78a3f852 100644 --- a/playground/index.html +++ b/playground/index.html @@ -28,63 +28,224 @@
diff --git a/src/blocks/scratch3_operators.js b/src/blocks/scratch3_operators.js index eff1fe18d..94329b5a3 100644 --- a/src/blocks/scratch3_operators.js +++ b/src/blocks/scratch3_operators.js @@ -14,8 +14,8 @@ Scratch3OperatorsBlocks.prototype.getPrimitives = function() { return { 'math_number': this.number, 'text': this.text, - 'math_add': this.add, - 'logic_equals': this.equals + 'operator_add': this.add, + 'operator_equals': this.equals }; }; @@ -32,7 +32,7 @@ Scratch3OperatorsBlocks.prototype.add = function (args) { }; Scratch3OperatorsBlocks.prototype.equals = function (args) { - return args.VALUE1 == args.VALUE2; + return args.OPERAND1 == args.OPERAND2; }; module.exports = Scratch3OperatorsBlocks;