Reversing the sign on Motor A reported position.

This commit is contained in:
Evelyn Eastmond 2019-04-23 19:05:12 -04:00
parent b80b05ead7
commit adb4c0482c

View file

@ -1888,7 +1888,11 @@ class Scratch3BoostBlocks {
return false;
}
if (portID && this._peripheral.motor(portID)) {
return MathUtil.wrapClamp(this._peripheral.motor(portID).position, 0, 360);
let val = MathUtil.wrapClamp(this._peripheral.motor(portID).position, 0, 360);
if (portID === BoostPort.A) {
val *= -1;
}
return val;
}
return 0;
}