Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- let ZAR = 0
- input.onGesture(Gesture.Shake, () => {
- ZAR = Math.random(6) + 1
- if (ZAR == 1) {
- basic.showLeds(`
- . . . . .
- . . . . .
- . . # . .
- . . . . .
- . . . . .
- `)
- } else if (ZAR == 2) {
- basic.showLeds(`
- . . . . .
- . . . . .
- . # . # .
- . . . . .
- . . . . .
- `)
- } else if (ZAR == 3) {
- basic.showLeds(`
- . . . . .
- . . . # .
- . . # . .
- . # . . .
- . . . . .
- `)
- } else if (ZAR == 4) {
- basic.showLeds(`
- . . . . .
- . # . # .
- . . . . .
- . # . # .
- . . . . .
- `)
- } else if (ZAR == 5) {
- basic.showLeds(`
- . . . . .
- . # . # .
- . . # . .
- . # . # .
- . . . . .
- `)
- } else {
- basic.showLeds(`
- # . # . #
- . . . . .
- . . . . .
- . . . . .
- # . # . #
- `)
- }
- })
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement