mirror of https://github.com/dirtbags/moth.git
23 lines
652 B
Plaintext
23 lines
652 B
Plaintext
|
get-turret 6 + set-turret!
|
||
|
0 0 set-speed!
|
||
|
|
||
|
1 sensor? { get-turret 60 - set-turret! } if
|
||
|
2 sensor? { get-turret 60 + set-turret! } if
|
||
|
0 sensor? {
|
||
|
fire-ready? { 0 0 set-speed! fire! } if
|
||
|
fire-ready? ! set-led!
|
||
|
} if
|
||
|
|
||
|
6 sensor? {
|
||
|
0 set-turret! ( stay on target, stay on target... )
|
||
|
3 sensor? { -40 -40 set-speed! } if ( back dat tank up )
|
||
|
4 sensor? { 25 50 set-speed! } if ( hook )
|
||
|
5 sensor? { 50 25 set-speed! } if ( slice )
|
||
|
} {
|
||
|
3 sensor? { -100 -100 set-speed! } if ( back dat tank up )
|
||
|
4 sensor? { 50 100 set-speed! } if ( hook )
|
||
|
5 sensor? { 100 50 set-speed! } if ( slice )
|
||
|
} ifelse
|
||
|
|
||
|
|