112 lines
2.6 KiB
Plaintext
Executable file
112 lines
2.6 KiB
Plaintext
Executable file
( L E V 0 0 0 0 5 )
|
|
|
|
objects: O
|
|
|
|
lazy 60 over 19 9 timedswitch ts
|
|
|
|
16 7 defrexx Rexx
|
|
9 3 defrexx Rexx2
|
|
|
|
13 6 door d1
|
|
10 9 door d2
|
|
5 6 door d3 >lazy!
|
|
10 2 door d4
|
|
LEV_END 5 12 exitdoor dx
|
|
|
|
lazy dup 11 3 computer c1
|
|
' c1 7 11 computer c2 >lazy!
|
|
lazy dup 7 5 computer c3
|
|
' c3 2 11 computer c4 >lazy!
|
|
|
|
' d2 10 10 scanner s1
|
|
' dx 4 12 scanner sx
|
|
|
|
' d4 7 1 switch b1
|
|
' d1 19 3 switch b2
|
|
|
|
:noname 0 MAXTILE for i tileflags + b@ RUBBLE & if i b, then next ;
|
|
array rubbletiles execute
|
|
here rubbletiles - 1 - const MAXRUBBLE
|
|
|
|
: randomrubble rand MAXRUBBLE % rubbletiles + b@ ;
|
|
|
|
: rexx-pos ( -- x y ) Rexx entity>pos world>tile ;
|
|
: rexx-dest ( -- x y ) rexx-pos Rexx entity.dir @ dir>pos +pos ;
|
|
|
|
: can-drop-rubble? ( -- b )
|
|
rexx-pos tile b@ CARPET =
|
|
rexx-dest tile b@ CARPET = and ;
|
|
|
|
: not-picking-up? ( -- b ) rexx-dest RUBBLE mapflag? not ;
|
|
|
|
: touch ( x y -- b )
|
|
drop 13 <= isrexx? and posessed-rexx @ Rexx = and if
|
|
3 glitchlevel !
|
|
rexx say" PaRiTy ErrRor!!"
|
|
0 glitchlevel !
|
|
1
|
|
else
|
|
not-picking-up? can-drop-rubble? and isrexx? and if
|
|
randomrubble rexx-pos tile b! invalidate-map
|
|
then 0
|
|
then ;
|
|
|
|
var first-rexx-touch
|
|
Rexx :noname
|
|
dup EVTOUCH = isneut? and first-rexx-touch @ not and if
|
|
1 first-rexx-touch !
|
|
rexx say" bOSssS..."
|
|
rexx say" i doN'T fEEl so\gooOO00dddDdDd..."
|
|
then chain-listener ;
|
|
|
|
var first-rexx2-touch
|
|
Rexx2 :noname
|
|
dup EVTOUCH = isneut? and first-rexx2-touch @ not and if
|
|
1 first-rexx2-touch !
|
|
neut say" REXX UNIT\PERFORM FULL DIAGNOSTIC SCAN"
|
|
rexx say" I'm in tip-top shape, boss!"
|
|
neut say" ACTIVATING RELIEF SUBROUTINE"
|
|
then chain-listener ;
|
|
|
|
: mr ( dir -- ) Rexx entity.dir ! Rexx move-entity ;
|
|
|
|
d2 :noname
|
|
dup entering-door?
|
|
isjaye? and
|
|
gord-follow? not and
|
|
Rexx entity>pos drop 0 > and
|
|
if
|
|
move-player
|
|
W mr
|
|
1 glitchlevel !
|
|
rexx say" daaAiisSyyy, daAAIIsYY..." hide-footer
|
|
2 glitchlevel !
|
|
W mr
|
|
W mr
|
|
rexx say" gIVe mE YOur AnSwerR\doOO0OO0o0oooOO..." hide-footer
|
|
N mr
|
|
N mr
|
|
4 glitchlevel !
|
|
1 quaking !
|
|
rexx say" uh oh" hide-footer
|
|
Rexx entity>pos world>tile -1 -1 +pos
|
|
dup 3 + for dup over 3 + i >rot for i over ( x y )
|
|
tile randomrubble swap b! invalidate-map 1 sleep
|
|
next drop next drop
|
|
-100 -100 Rexx entity.pos!
|
|
0 glitchlevel !
|
|
5 sleep
|
|
0 quaking !
|
|
drop EVNOP
|
|
then chain-listener ;
|
|
|
|
:noname O
|
|
|
|
' touch ' touch-override redefine
|
|
|
|
18 4 tile>world Jaye entity.pos!
|
|
19 5 tile>world Neut entity.pos!
|
|
with-gord
|
|
|
|
; ' onload redefine
|