summaryrefslogtreecommitdiff
path: root/addons/snake/snake.script
blob: 2cf07a5125f37a8ab6db8551cec8d5eb34e34588 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
# pardes --addon-test snake.so addons/snake/snake.script | diff addons/snake/snake.out -
seed 3
size 40 30
# It steps a cell each 150 ms while its pane has the keyboard (the first
# tick sets the pace).
tick 150
tick 150
# k turns it up, l right: onto the food, one longer and a point.
key k
tick 150
key l
tick 150
tick 150
# h is back on itself: refused, it goes on right; then j down.
key h
tick 150
key j
tick 150
ctl
body
# The window loses the keyboard: it stands still and asks for no ticks.
blur
settle
tick 600
# Back, it goes on, the first tick setting its pace again.
focus
tick 150
tick 150
# Its record is its state: the pane comes back from it as it was.
dump
tick 150
# Into the bottom wall: over, asking for nothing until a key starts it again.
tick 150
tick 150
settle
key x
tick 150