No floating point allowed
let y = 0
let plane = 0
let x = 0
let increment = 0
basic.forever(() => {
})
input.onButtonPressed(Button.A, () => {
basic.clearScreen()
plane = Math.random(5)
led.plot(plane, 4)
increment = plane * 25
})
input.onButtonPressed(Button.B, () => {
x = 0
y = 0
for (let i = 0; i < 5; i++) {
led.plot(plane, y)
basic.pause(100)
led.unplot(plane, y)
y = y + 1
}
})
No comments:
Post a Comment