minor PR feedback

This commit is contained in:
Sam El-Husseini 2017-12-19 14:57:28 -08:00
parent ef5fa9ae82
commit 1ab7ae6cfa

View File

@ -14,7 +14,9 @@ namespace pxsim.output {
export function setLights(pattern: number) { export function setLights(pattern: number) {
const brickState = ev3board().getBrickNode(); const brickState = ev3board().getBrickNode();
const lightState = brickState.lightState; const lightState = brickState.lightState;
if (lightState.lightPattern != pattern) {
lightState.lightPattern = pattern; lightState.lightPattern = pattern;
brickState.setChangedState(); brickState.setChangedState();
} }
}
} }