pxt-ev3/sim/state/light.ts
2017-12-18 13:04:17 -08:00

19 lines
389 B
TypeScript

namespace pxsim {
export class EV3LightState {
lightPattern: number;
constructor() {
this.lightPattern = 0;
}
}
}
namespace pxsim.output {
export function setLights(pattern: number) {
const lightState = ev3board().getBrickNode().lightState;
lightState.lightPattern = pattern;
runtime.queueDisplayUpdate();
}
}