aboutsummaryrefslogtreecommitdiffstats
path: root/tests/oracle/steps.pure
blob: 3c09dbbd29551a572e4cc184bf5c7722a3afe22f (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
# The workbench has no else; the aup else-if chain is written as exclusive ifs.
state level = 0
state band = 0
input up = ArrowUp
input down = ArrowDown
text shown(0, 0, band, "band")
on up.down {
  level = level + 1
}
on down.down {
  level = level - 1
}
on frame {
  if level > 2 {
    band = 2
  }
  if level <= 2 && level > 0 {
    band = 1
  }
  if level <= 0 {
    band = 0
  }
}