Skip to content

Commit ccd746b

Browse files
committed
oops
1 parent b9a337c commit ccd746b

File tree

5 files changed

+96
-44
lines changed

5 files changed

+96
-44
lines changed

assets/progs/happtSad2.mc

Lines changed: 46 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,46 @@
1+
Page 1
2+
When press button_A Do press LED_image `
3+
1 1 . 1 1
4+
1 1 . 1 1
5+
. . . . .
6+
1 . . . 1
7+
. 1 1 1 .
8+
`
9+
LED_image `
10+
1 1 . 1 1
11+
. . . . .
12+
1 . . . 1
13+
. 1 1 1 .
14+
. . . . .
15+
`
16+
17+
18+
When press button_A Do press happy
19+
20+
When press button_B Do press LED_image `
21+
1 1 . 1 1
22+
1 1 . 1 1
23+
. . . . .
24+
. 1 1 1 .
25+
1 . . . 1
26+
`
27+
LED_image `
28+
1 1 . 1 1
29+
1 1 . 1 1
30+
. . . . .
31+
. . . . .
32+
1 1 1 1 1
33+
`
34+
35+
36+
When press button_B Do press sad
37+
38+
Page 2
39+
40+
Page 3
41+
42+
Page 4
43+
44+
Page 5
45+
46+

assets/progs/happySad.mc

Lines changed: 44 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,44 @@
1+
Page 1
2+
When press button_A Do show_image LED_image `
3+
1 1 . 1 1
4+
1 1 . 1 1
5+
. . . . .
6+
1 . . . 1
7+
. 1 1 1 .
8+
`
9+
LED_image `
10+
1 1 . 1 1
11+
. . . . .
12+
1 . . . 1
13+
. 1 1 1 .
14+
. . . . .
15+
`
16+
17+
18+
When press button_A Do play_sound happy
19+
20+
When press button_B Do show_image LED_image `
21+
1 1 . 1 1
22+
1 1 . 1 1
23+
. . . . .
24+
. 1 1 1 .
25+
1 . . . 1
26+
`
27+
LED_image `
28+
1 1 . 1 1
29+
1 1 . 1 1
30+
. . . . .
31+
. . . . .
32+
1 1 1 1 1
33+
`
34+
35+
36+
When press button_B Do play_sound sad
37+
38+
Page 2
39+
40+
Page 3
41+
42+
Page 4
43+
44+
Page 5

assets/progs/newHS.mc

Lines changed: 0 additions & 40 deletions
This file was deleted.

editor.ts

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -297,14 +297,16 @@ namespace microcode {
297297

298298
progToString(this.progdef)
299299
const pas1 = progToStringRet
300-
console.log(`PAS1\n${pas1}`)
300+
// console.log(`PAS1\n${pas1}`)
301301
parseProg(pas1)
302302
const progFromString = parseProgRet
303303
progToString(progFromString)
304304
const pas2 = progToStringRet
305-
console.log("PAS2")
306-
console.log(pas2)
305+
// console.log("PAS2")
306+
// console.log(pas2)
307307
// check the programs are the same
308+
console.log(pas2)
309+
// control.assert(pas1 == pas2, "progs not the same")
308310
}
309311
this.configureP1Keys()
310312
}

mcparser.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -61,7 +61,7 @@ namespace microcode {
6161
control.assert(rule != undefined, `No Rule definition`)
6262
const tid = getTid(tile)
6363
if (isSensor(tid)) rule.push(tile, "sensors", false)
64-
if (isFilter(tid)) rule.push(tile, "filters", false)
64+
else if (isFilter(tid)) rule.push(tile, "filters", false)
6565
else if (isModifier(tid)) rule.push(tile, "modifiers", false)
6666
else rule.push(tile, "actuators", false)
6767
}

0 commit comments

Comments
 (0)