diff options
author | Tor Andersson <tor@ccxvii.net> | 2023-03-20 01:15:58 +0100 |
---|---|---|
committer | Tor Andersson <tor@ccxvii.net> | 2023-05-03 18:48:16 +0200 |
commit | b89eba8253caccd027c861b5cfa68b29dceb6639 (patch) | |
tree | 42c778fb230d4b3095c7f3ded36d9bc9eb90bd11 /tools | |
parent | ad863219484ad675d138e0863880bf798060b493 (diff) | |
download | andean-abyss-b89eba8253caccd027c861b5cfa68b29dceb6639.tar.gz |
Fix optional instructions. Poppies.
Diffstat (limited to 'tools')
-rw-r--r-- | tools/gencode.py | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/tools/gencode.py b/tools/gencode.py index c78ce11..c02f24d 100644 --- a/tools/gencode.py +++ b/tools/gencode.py @@ -46,16 +46,10 @@ for event in range(2,146): for line in code[event]: if line.startswith('space'): line = line.split(' ', 2) - print('\t[ vm_space, ' + line[1] + ', (s)=>' + line[2] + ' ],') - elif line.startswith('each space'): - line = line.split(' ', 2) - print('\t[ vm_space, 0, (s)=>' + line[2] + ' ],') + print('\t[ vm_'+line[0]+', ' + line[1] + ', (s)=>' + line[2] + ' ],') elif line.startswith('piece'): line = line.split(' ', 2) - print('\t[ vm_piece, ' + line[1] + ', (p,s)=>' + line[2] + ' ],') - elif line.startswith('each piece'): - line = line.split(' ', 2) - print('\t[ vm_piece, 0, (p,s)=>' + line[2] + ' ],') + print('\t[ vm_'+line[0]+', ' + line[1] + ', (p,s)=>' + line[2] + ' ],') elif line.startswith('while'): line = line.split(' ', 1) print('\t[ vm_while, ()=>' + line[1] + ' ],') |