From b8bbe80c4f447796e1754c8574d21d5e43f0e8ae Mon Sep 17 00:00:00 2001 From: Kevin Andersen Date: Tue, 9 Apr 2019 16:20:21 -0400 Subject: [PATCH] get position from this._peripheral.motor() --- src/extensions/scratch3_boost/index.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/extensions/scratch3_boost/index.js b/src/extensions/scratch3_boost/index.js index a519f8a05..e8b6859a7 100644 --- a/src/extensions/scratch3_boost/index.js +++ b/src/extensions/scratch3_boost/index.js @@ -1808,8 +1808,8 @@ class Scratch3BoostBlocks { log.warn('Asked for a motor position that doesnt exist!'); return false; } - if (portID && this.motor(portID)) { - return MathUtil.wrapClamp(this.motor(portID).position, 0, 360); + if (portID && this._peripheral.motor(portID)) { + return MathUtil.wrapClamp(this._peripheral.motor(portID).position, 0, 360); } return 0; }