ROOM ID 617 NOCYBORGS HIDDEN NAME "hole seventeen" PICT "hole17.jpg" ARTIST "lion hisself" DOOR ID 88 DONTMOVEHERE SHOWFRAME OUTLINE 3,2 510,2 510,276 3,276 LOC 256,139 SCRIPT ON SELECT { ;spot 88 ; values for "teed" 0= initial, 1= place ball on tee, 2= line up putt, 3= putt delay 4 = putting ; 5= end putt 6 = in the hole 7= next putt 8= prevent double-click ; globes GLOBAL globes EXEC ; ; wait for spot 88 alarms to die down then hit shot ; { setputt EXEC 3 teed = 30 89 SETALARM } teed 2 == IF ; next putt ; { 8 teed = 40 88 SETALARM } teed 7 == IF } ;____________________________________________________________________________________________________________________ ON ALARM { globes GLOBAL globes EXEC ; { lineup EXEC } 1 teed == 2 teed == OR 8 teed == OR IF ; ; tee shot and onward until hole ; { impact EXEC findevent EXEC paintball EXEC paintflite EXEC bounce EXEC 40 88 SETALARM } teed 4 == IF ; next putt ; { 7 teed = setputt EXEC paintball EXEC } teed 5 == IF } ;___________________________________________________________________________ ON ENTER { globes GLOBAL globes EXEC ; { ; inputs deltaX, deltaY, currentX, currentY ; outputs Xx Xy Xy Yyshort, xhit, yhit, verb ; ; [ [ 78 ] [ 53 102 1 ] [ 78 ] [ 169 224 1 ] [ 390 ] [ 100 172 1 ][ 402 ] [ 131 142 -1 ] [ 435 ] [ 131 142 -1 ] [ 92 ] [ 193 199 0 ] [ 447 ] [ 53 224 -1 ] ] Xarray = ; [ [ 56 ] [ 72 452 1 ] [ 100 ] [ 72 390 -1 ] [ 196 ] [ 89 95 0 ] [ 131 ] [ 402 435 -1 ] [ 142 ] [ 402 435 1 ][ 173 ] [ 72 390 1 ] [ 220 ] [ 72 452 -1 ] ] Yarray = ; ; for each X calc where hit Xarray LENGTH len = len -- 0 xhit = 2 oldyside = currentX oldXpos = 0 Xaction = ;-6001 oldXpos = { 6001 oldXpos = } deltaX 0 < IF 0 Xhshort = 0 Yhshort = 6002 Xxshort = 6003 Yxshort = 6004 curXside = 0 verb = 0 tvar = { len -- Xarray len GET 0 GET currentX - Xdelta = { print exec " ouch" say exit } Xdelta 1000 > Xdelta -1000 < OR IF deltaY Xdelta * deltaX / Ydelta = currentY Ydelta + Ypos = ; left Xarray 1 len + GET 0 GET tvar0 = ; right Xarray 1 len + GET 1 GET tvar1 = Xarray 1 len + GET 2 GET tvar3 = { Xarray 1 len + GET 3 GET tvar3 = } tvar3 1 > IF ; determine vertical collisions { currentX Xdelta + Xpos = ; if cup { { 1 Xhit = Xpos Xhshort = Ypos Yhshort = Xpos oldXpos = 3 verb = ; set action if any and pack it { tvar Xaction = 1000 Xaction *= } Xarray 1 len + GET 2 GET tvar = tvar 1 > IF ; } ; if wall ; at wall to start putt { { 5 verb = } Xpos currentX == IF 1 Xhit = Xpos Xxshort = Ypos Yxshort = Xpos oldXpos = tvar3 curXside = ; set action if any and pack it { tvar Xaction = 1000 Xaction += } Xarray 1 len + GET 2 GET tvar = tvar 1 > IF { 8000 Xxshort = } 1 tvar3 == deltaX 0 >= AND 1 xhit <> AND -1 tvar3 == deltaX 0 < AND 1 xhit <> AND OR IF { 8001 Yxshort = print EXEC } Ypos currentY < 1 oldYside == AND Ypos currentY > 0 oldYside == AND Ypos currentY == AND OR IF } 0 tvar3 == IFELSE } ; putt left deltaX 0 < Xpos currentX <= AND 0 xhit == AND tvar3 0 >= AND tvar0 = deltaX 0 < Xpos currentX <= AND Xpos oldXpos > AND 1 xhit == AND tvar3 0 >= AND tvar1 = tvar0 tvar1 OR tvar0 = ; putt right deltaX 0 > Xpos currentX >= AND 0 xhit == AND tvar3 0 <= AND tvar1 = deltaX 0 > Xpos currentX >= AND Xpos oldXpos < AND 1 xhit == AND tvar3 0 <= AND tvar2 = tvar1 tvar2 OR tvar1 = tvar0 tvar1 OR IF ; if not a gate } Ypos tvar0 >= Ypos tvar1 <= AND IF len -- } { -1 len <> } WHILE { 1 xhit = } 0 xhit == 3 verb == AND IF ;____________________________________________________________________________________________________________________ ; for each Y calc where hit Yarray LENGTH len = len -- 0 yhit = 2 oldXside = currentY oldYpos = 0 Yaction = 7002 Xyshort = 7003 Yyshort = 7004 curYside = { len -- Yarray len GET 0 GET currentY - Ydelta = deltaX Ydelta * deltaY / Xdelta = Xdelta currentX Xdelta + Xpos = ; get top Yarray 1 len + GET 0 GET tvar0 = ; get bottom Yarray 1 len + GET 1 GET tvar1 = Yarray 1 len + GET 2 GET tvar3 = { Yarray 1 len + GET 3 GET tvar3 = } tvar3 1 > IF ; determine horizontal collisions { currentY Ydelta + Ypos = ; if cup { { 1 Yhit = Xpos Xhshort = Ypos Yhshort = Ypos oldYpos = 3 verb = ; set action if any and pack it { tvar Yaction = 1000 Yaction *= } Yarray 1 len + GET 2 GET tvar = tvar 1 > IF ; } ; if wall { ; hit both, an outside corner { { 2 verb = } ; at wall to start putt { 6 verb = } 5 verb == IFELSE } Ypos currentY == IF 1 Yhit = Xpos Xyshort = Ypos Yyshort = Ypos oldYpos = tvar3 curYside = ; set action if any and pack it { tvar Yaction = 1000 Yaction += } Yarray 1 len + GET 2 GET tvar = tvar 1 > IF { 9000 Yyshort = } 1 tvar3 == deltaY 0 >= AND 1 yhit <> AND -1 tvar3 == deltaY 0 < AND 1 yhit <> AND OR IF { 9001 Xyshort = print EXEC } Xpos currentX < 1 oldXside == AND Xpos currentX > 0 oldXside == AND Xpos currentX == AND OR IF } tvar3 0 == IFELSE } ; putt up deltaY 0 < Ypos currentY <= AND 0 yhit == AND tvar3 0 >= AND tvar0 = deltaY 0 < Ypos currentY <= AND Ypos oldYpos > AND 1 yhit == AND tvar3 0 >= AND tvar1 = tvar0 tvar1 OR tvar0 = ; putt down deltaY 0 > Ypos currentY >= AND 0 yhit == AND tvar3 0 <= AND tvar1 = deltaY 0 > Ypos currentY >= AND Ypos oldYpos < AND 1 yhit == AND tvar3 0 <= AND tvar2 = tvar1 tvar2 OR tvar1 = tvar0 tvar1 OR IF ; if not a gate } Xpos tvar0 >= Xpos tvar1 <= AND IF len -- } { -1 len <> } WHILE { 1 yhit = } 0 yhit == 3 verb == AND IF } impact DEF } ENDSCRIPT ENDDOOR DOOR ID 3 NAME "next hole" DONTMOVEHERE DEST 618 OUTLINE 407,348 464,348 464,363 407,363 LOC 435,355 SCRIPT ON ENTER { globes GLOBAL globes EXEC ; ; position avs ; { tvar0 tvar1 SETPOS } 0 tvar0 <> 0 tvar1 <> AND IF inits EXEC { " You've already played this hole..." STATUSMSG } playd ROOMID >= IF { " pssst...no skipping holes....." STATUSMSG } playd ROOMID 1 - < IF } ON LEAVE { globes GLOBAL globes EXEC ; POSX tvar0 = POSY tvar1 = { PAINTCLEAR } NBRROOMUSERS 1 == IF } ENDSCRIPT ENDDOOR DOOR ID 4 NAME " " DONTMOVEHERE OUTLINE 408,312 463,312 463,332 408,332 LOC 435,322 SCRIPT ON ENTER { globes GLOBAL globes EXEC ; symbol defs caps GLOBAL smalls GLOBAL syms1 GLOBAL syms2 GLOBAL syms3 GLOBAL name GLOBAL tvar2 GLOBAL ; { { 0 -6 pento 2 -2 lineto 3 0 lineto 1 1 lineto 0 8 lineto -1 -2 pento -1 1 lineto -3 0 lineto -1 -1 lineto 0 -2 lineto 2 -1 lineto 2 0 lineto 2 -1 lineto 3 5 pento } "lena" tvar2 GREPSTR IF { 0 -12 lineto 0 6 pento 2 -2 lineto 2 0 lineto 2 2 lineto 0 4 lineto -2 2 lineto -2 0 lineto -2 -2 lineto 9 2 pento } "lenb" tvar2 GREPSTR IF { 5 -7 pento -1 -1 lineto -2 0 lineto -2 2 lineto 0 4 lineto 2 2 lineto 2 0 lineto 2 -2 lineto 2 2 pento } "lenc" tvar2 GREPSTR IF { 6 -2 pento -2 2 lineto -2 0 lineto -2 -2 lineto 0 -4 lineto 2 -2 lineto 2 0 lineto 2 2 lineto 0 -5 pento 0 12 lineto 3 -1 pento } "lend" tvar2 GREPSTR IF { 6 -2 pento -2 2 lineto -2 0 lineto -2 -2 lineto 0 -4 lineto 2 -2 lineto 2 0 lineto 2 2 lineto 0 2 lineto -6 0 lineto 9 4 pento } "lene" tvar2 GREPSTR IF { 1 0 pento 0 -10 lineto 2 -1 lineto 1 0 lineto -4 3 pento 4 0 lineto 2 8 pento } "lenf" tvar2 GREPSTR IF { 5 -7 pento -1 -1 lineto -2 0 lineto -2 2 lineto 0 4 lineto 2 2 lineto 2 0 lineto 2 -2 lineto 0 -6 pento 0 9 lineto -2 2 lineto -3 0 lineto -2 -2 lineto 10 -1 pento } "leng" tvar2 GREPSTR IF { 0 -12 lineto 0 4 pento 1 1 lineto 2 -1 lineto 3 1 lineto -1 0 pento 0 8 lineto 3 -1 pento } "lenh" tvar2 GREPSTR IF { 0 -9 lineto 0 -2 pento 0 -1 lineto 3 12 pento } "leni" tvar2 GREPSTR IF { 2 -11 pento 0 1 lineto 0 2 pento 0 10 lineto -1 1 lineto -2 0 lineto 6 -3 pento } "lenj" tvar2 GREPSTR IF { 0 -12 lineto 0 10 pento 7 -7 lineto -5 4 pento 5 6 lineto 2 -1 pento } "lenk" tvar2 GREPSTR IF { 0 -11 pento 0 11 lineto 3 0 pento } "lenl" tvar2 GREPSTR IF { 0 -8 lineto 1 1 lineto 2 -1 lineto 3 1 lineto -1 0 pento 0 8 lineto 1 -8 pento 2 -1 lineto 3 1 lineto -1 0 pento 0 8 lineto 3 -1 pento} "lenm" tvar2 GREPSTR IF { 0 -8 lineto 1 1 lineto 2 -1 lineto 3 1 lineto -1 0 pento 0 7 lineto 3 0 pento } "lenn" tvar2 GREPSTR IF { 0 -8 lineto 1 1 lineto 2 -1 lineto 3 1 lineto -1 0 pento 0 8 lineto -3 -11 pento 3 0 lineto 3 10 pento } "len–" tvar2 GREPSTR IF { 5 -7 pento -1 -1 lineto -2 0 lineto -2 2 lineto 0 4 lineto 2 2 lineto 2 0 lineto 2 -2 lineto 0 -4 pento 0 5 lineto 3 1 pento } "leno" tvar2 GREPSTR "len¿" tvar2 GREPSTR OR IF { 0 3 pento 0 -12 lineto 1 2 pento 1 -1 lineto 2 0 lineto 2 2 lineto 0 4 lineto -2 2 lineto;ex -2 0 lineto -2 -2 lineto 9 2 pento } "lenp" tvar2 GREPSTR IF { 6 4 pento 0 -12 lineto 0 6 pento -2 2 lineto -2 0 lineto -2 -2 lineto 0 -4 lineto 2 -2 lineto 2 0 lineto 2 2 lineto 3 6 pento } "lenq" tvar2 GREPSTR IF { 0 -8 lineto 1 1 lineto 2 -1 lineto 1 1 lineto 2 7 pento } "lenr" tvar2 GREPSTR IF;an { 0 -1 pento 1 1 lineto 3 0 lineto 1 -2 lineto 0 -1 lineto -1 -1 lineto -3 0 lineto -1 -1 lineto 0 -2 lineto 1 -1 lineto 3 0 lineto 2 2 lineto 2 6 pento } "lens" tvar2 GREPSTR IF { 3 0 pento -2 0 lineto 0 -11 lineto -1 3 pento 4 0 lineto 2 8 pento } "lent" tvar2 GREPSTR IF { 0 -8 pento 0 7 lineto 2 1 lineto 1 0 lineto 1 -2 lineto 1 -6 pento 0 9 lineto 3 -1 pento } "lenu" tvar2 GREPSTR IF { 0 -8 pento 3 8 lineto 3 -9 lineto 3 9 pento } "lenv" tvar2 GREPSTR IF { 0 -8 pento 3 8 lineto 3 -8 lineto 3 8 lineto 3 -9 lineto 3 9 pento } "lenw" tvar2 GREPSTR IF { 7 -9 lineto -7 1 pento 7 9 lineto 2 -1 pento } "lenx" tvar2 GREPSTR IF ;dr { 0 -8 pento 3 8 lineto 3 -9 lineto -3 10 pento 0 1 lineto -1 1 lineto -2 0 lineto 9 -3 pento } "leny" tvar2 GREPSTR "lenØ" tvar2 GREPSTR OR IF ;a { 0 -8 pento 6 0 lineto -6 8 lineto 7 0 lineto 2 0 pento } "lenz" tvar2 GREPSTR IF } smalls DEF } } ENDSCRIPT ENDDOOR DOOR ID 89 NAME "tee" DONTMOVEHERE OUTLINE 100,59 127,59 127,97 100,97 LOC 113,78 SCRIPT ON SELECT ; spot 89 { globes GLOBAL globes EXEC ; ; tee up/paint ball for first putt ; inputs teed, stroke ; outputs currentX, currentY ; { MOUSEPOS currentY = currentX = PAINTUNDO paintball EXEC 1 teed = 40 88 setalarm } 0 teed == 0 stroke == AND IF ; ; hit shot ; { setputt EXEC 3 teed = 30 89 SETALARM } teed 2 == IF ; next putt { 8 teed = 40 88 setalarm } 7 teed == IF } ;___________________________________________________________________________ ON ALARM { globes GLOBAL globes EXEC ; wait for spot 88 alarms to die down then hit shot { setputt EXEC 4 teed = 30 88 SETALARM } 3 teed == IF ; next putt { 2 teed = 40 88 setalarm } 7 teed == IF } ENDSCRIPT ENDDOOR ENDROOM