Version 2 of Time Warp by Wade Clarke begins here. "A self-contained, keypress-driven CYOA you can add to your Glulx or Z8 game/project as an easter egg, feature, or for any other purpose you want. A player can enter Time Warp, spend any amount of time playing it and replaying it, and then leave it (to return to the host project) without interfering with the state of the host project." Include Basic Screen Effects by Emily Short. To decide what number is the TIMEkey_pressed: let keypress be 0; while keypress is 0: let keypress be the chosen letter; decide on the keypress; To decide what text is the TIMEyesno_answer: let result be "MAYBE"; while result is "MAYBE": let keypress be the TIMEkey_pressed; if keypress is 89 or keypress is 121: now result is "YES"; otherwise if keypress is 78 or keypress is 110: now result is "NO"; decide on result; To decide what text is the TIMEyesno_answer_with_question (question - some text): say "[question][line break]"; decide on the TIMEyesno_answer; To run time warp: follow the time warp rules; unless ROCKINwarpkey is 999: say "[line break]THE END[paragraph break]"; let answer be the TIMEyesno_answer_with_question "WILL YOU PLAY AGAIN? (Y/N)"; say line break; say answer; say line break; if answer is "YES": run time warp; ROCKINwarpkey is a number variable. [GLOBAL] ROCKINtimequitter is a number variable. [GLOBAL] ROCKINtimevalid is a list of numbers that varies. [GLOBAL] This is the timewarp key rule: while 1 is 1: now ROCKINwarpkey is the TIMEkey_pressed; [say ROCKINwarpkey; [debug]] if ROCKINwarpkey is -8 or ROCKINwarpkey is 81 or ROCKINwarpkey is 113: [pressed 'q' or 'esc'] say "[line break]EXITING TIME WARP[paragraph break]"; now ROCKINwarpkey is 999; [signals not to ask if we want to play again] say variable letter spacing; stop the action; if ROCKINwarpkey is listed in ROCKINtimevalid: make no decision; [exit the key loop] make no decision; [Since we Abide by this rule, we need to exit it with a decision (or explicit lack of decision.)] This is the timewarp space key rule: while 1 is 1: now ROCKINwarpkey is the TIMEkey_pressed; [say ROCKINwarpkey; [debug]] if ROCKINwarpkey is -8 or ROCKINwarpkey is 81 or ROCKINwarpkey is 113: [pressed 'q' or 'esc'] say "[line break]EXITING TIME WARP[paragraph break]"; now ROCKINwarpkey is 999; [signals not to ask if we want to play again] say variable letter spacing; stop the action; if ROCKINwarpkey is 32: [check if space was pressed] make no decision; [if it was, exit the key loop] make no decision; The time warp rules are a rulebook. The time warp rulebook has a number called linenumber. A time warp rule (this is the start time warp rule): say "( - You can exit TIMEWARP at any time by pressing ESCAPE or Q, but you can't save your position within TIMEWARP -)[paragraph break]"; say fixed letter spacing; say " * TIME WARP *[line break]"; say " PROGRAMMED BY WADE CLARKE[line break]"; say " (C) 1987[line break]"; say " PRESS SPACE TO BEGIN[paragraph break]"; abide by the timewarp space key rule; say " YAWN!WHAT HAPPENED...OH,THAT'S RIGHT.[line break]"; [line 55] say "IT WAS CHRISTMAS EVE LAST NIGHT AND YOU[line break]"; say "STAYED UP FOR A PARTY.YOU ARE SO TIRED,[line break]"; say "YOU CAN BARELY OPEN YOUR EYES.YOU HOP[line break]"; say "OUT OF BED AND GO TO THE BATHROOM.[line break]"; say "YOU LOOK INTO YOUR MIRROR...ERRR!YOU[line break]"; say "LOOK TERRIBLE...SUDDENLY YOUR IMAGE[line break]"; say "DISAPPEARS.YOU RUB YOUR EYES.THE MIRROR[line break]"; say "IS STILL BLANK.WILL YOU (T)OUCH IT?OR[line break]"; say "(P)INCH YOURSELF TO CHECK YOU'RE NOT[line break]"; say "SEEING THINGS.[line break]"; now ROCKINtimevalid is { 80, 112, 84, 116 }; abide by the timewarp key rule; if ROCKINwarpkey is 80 or ROCKINwarpkey is 112: [P] now linenumber is 180; if ROCKINwarpkey is 84 or ROCKINwarpkey is 116: [T] now linenumber is 150; continue the action; A time warp rule (this is the warp 150 rule): if linenumber is greater than 150: continue the action; say "YOU TOUCH THE MIRROR AND SUDDENLY ARE[line break]"; say "DRAWN INTO IT BY SOME UNKNOWN FORCE!YOU[line break]"; say "SEE A BRIGHT LIGHT FLY TOWARDS YOU,AND[line break]"; say "OPEN YOUR MOUTH TO SCREAM...NOTHING[line break]"; say "COMES OUT...PRESS SPACE...[paragraph break]"; abide by the timewarp space key rule; now linenumber is 220; continue the action; A time warp rule (this is the warp 180 rule): if linenumber is greater than 180: continue the action; say "YOU PINCH YOURSELF...OUCH!THAT HURT!YOU[line break]"; say "LOOK AT THE MIRROR AGAIN.STILL NOTHING![line break]"; say "SUDDENLY A BRIGHT LIGHT FIRES OUT OF[line break]"; say "THE MIRROR AND STRIKES YOU...PRESS[line break]"; say "SPACE...[paragraph break]"; abide by the timewarp space key rule; now linenumber is 220; continue the action; A time warp rule (this is the warp 220 rule): if linenumber is greater than 220: continue the action; say "[line break]YOU AWAKEN.IT'S PITCH BLACK AND YOU[line break]"; say "CAN'T SEE A THING.AS YOU GROPE IN THE[line break]"; say "DARK,YOU FIND A LEVER.YOU PULL IT AND[line break]"; say "LIGHTS FLICKER ON.YOU'RE IN A LONG,THIN[line break]"; say "ROOM.AT THE OTHER END ARE TWO DOORS.YOU[line break]"; say "CAN'T WORK OUT WHERE YOU ARE AND PANIC[line break]"; say "SUDDENLY FILLS YOU.YOU WALK UP TO THE[line break]"; say "DOORS.ONE HAS A CIRCLE ON IT,THE OTHER,[line break]"; say "A TRIANGLE.WHICH DOOR?THE (C)IRCLE OR[line break]"; say "THE (T)RIANGLE?[line break]"; now ROCKINtimevalid is { 67, 99, 84, 116 }; abide by the timewarp key rule; if ROCKINwarpkey is 67 or ROCKINwarpkey is 99: [C] now linenumber is 300; if ROCKINwarpkey is 84 or ROCKINwarpkey is 116: [T] now linenumber is 470; continue the action; A time warp rule (this is the warp 300 rule): if linenumber is greater than 300: continue the action; say "YOU OPEN THE DOOR AND...ZAP!PRESS[line break]"; say "SPACE..."; abide by the timewarp space key rule; say "[paragraph break]YOU FIND YOURSELF ON THE SURFACE OF A[line break]"; say "STRANGE PLANET.WHO GOT YOU INTO THIS?[line break]"; say "SOMEONE OUT THERE THINKS THIS IS FUNNY.[line break]"; say "YOU'RE AMIDST SOME HUGE STONES.A CAVE[line break]"; say "IS NEARBY AND ON THE HORIZON YOU CAN[line break]"; say "SEE A SILVER OBJECT.NIGHT IS FALLING.[line break]"; say "MAYBE IT WOULD BE WISE TO SLEEP IN THE[line break]"; say "CAVE.BUT WHAT IF THERE'S SOME MONSTER[line break]"; say "DOWN THERE!MAYBE THE SILVER OBJECT IS[line break]"; say "SAFER.WILL YOU (G)O INTO THE CAVE,OR[line break]"; say "(I)NVESTIGATE THE SILVER OBJECT?[line break]"; now ROCKINtimevalid is { 71, 103, 73, 105 }; abide by the timewarp key rule; if ROCKINwarpkey is 71 or ROCKINwarpkey is 103: [G] now linenumber is 410; if ROCKINwarpkey is 73 or ROCKINwarpkey is 105: [I] now linenumber is 585; continue the action; A time warp rule (this is the warp 410 rule): if linenumber is greater than 410: continue the action; say "IT'S TOO COLD OUT HERE.YOU DECIDE TO GO[line break]"; say "DOWN INTO THE CAVE TO SLEEP AND ESCAPE[line break]"; say "THE WIND...PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]SNORE...SNORE...WHAT WAS THAT?YOU LOOK[line break]"; say "UP.THE CAVE IS EMPTY.YOU'RE IMAGINING[line break]"; say "IT!YOU HOPE...SNORE...WHAT IN THE...[line break]"; say "OUT OF THE SHADOWS LEAPS A HORRIFYING[line break]"; say "BEAR-LIKE CREATURE!TOO LATE...PITY YOU[line break]"; say "DIDN'T KNOW THAT THIS WAS HIS HOME..."; stop the action; A time warp rule (this is the warp 470 rule): if linenumber is greater than 470: continue the action; say "YOU OPEN THE TRIANGLE DOOR..ZAP!PRESS[line break]"; say "SPACE..."; abide by the timewarp space key rule; say "[paragraph break]YOU'RE STANDING INFRONT OF A HUGE,STONE[line break]"; say "PYRAMID.BEHIND YOU IS A DENSE JUNGLE.[line break]"; say "YOU CAN HEAR SOMEONE APPROACHING OUT OF[line break]"; say "THE UNDERGROWTH.YOU MUST ACT QUICKLY![line break]"; say "WILL YOU:(R)UN INTO THE PYRAMID,OR[line break]"; say "(W)AIT TO SEE WHO'S COMING?[line break]"; now ROCKINtimevalid is { 82, 114, 87, 119 }; abide by the timewarp key rule; if ROCKINwarpkey is 82 or ROCKINwarpkey is 114: [R] now linenumber is 550; if ROCKINwarpkey is 87 or ROCKINwarpkey is 119: [W] now linenumber is 740; continue the action; A time warp rule (this is the warp 550 rule): if linenumber is greater than 550: continue the action; say "YOU RUN INTO THE PYRAMID AND HEAR A[line break]"; say "SMASH AS A HUGE STONE SLAB CLAPS SHUT[line break]"; say "BEHIND YOU...PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]YOU ARE IN TOTAL DARKNESS.YOU FUMBLE[line break]"; say "ABOUT AND SUDDENLY YOUR FEET FIND THEM-[line break]"; say "SELVES TREADING ON...NOTHING...YOU[line break]"; say "PLUMMET DOWN,NEVER TO BE SEEN AGAIN."; stop the action; A time warp rule (this is the warp 585 rule): if linenumber is greater than 585: continue the action; say "YOU TREK ACROSS THE ROCKY GROUND AND[line break]"; say "EVENTUALLY REACH THE SILVER OBJECT."; say "PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]IT IS A SPACESHIP AND THE HATCH IS WIDE[line break]"; say "OPEN.NEARBY ON THE GROUND IS A SMALL[line break]"; say "BOX.SUDDENLY SOMETHING STEPS OUT OF THE[line break]"; say "SHIP...PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]A LITTLE GREEN MARTIAN COMES UP TO YOU[line break]"; say "AND SAYS [']HI!['].WELL,HE LOOKS FRIENDLY[line break]"; say "ENOUGH!WILL YOU:(S)PEAK TO HIM,OR[line break]"; say "(H)IJACK HIS SHIP AND GET AWAY?[line break]"; now ROCKINtimevalid is { 83, 115, 72, 104 }; abide by the timewarp key rule; if ROCKINwarpkey is 83 or ROCKINwarpkey is 115: [S] now linenumber is 820; if ROCKINwarpkey is 72 or ROCKINwarpkey is 104: [H] now linenumber is 675; continue the action; A time warp rule (this is the warp 675 rule): if linenumber is greater than 675: continue the action; say "YOU KNOCK THE LITTLE MARTIAN ASIDE AND[line break]"; say "LEAP INTO HIS SHIP AND THROTTLE INTO[line break]"; say "SPACE...PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break] AS YOU ARE THINKING ABOUT WHERE TO GO,[line break]"; say "AN EXPLOSION ROCKS YOUR SHIP!YOU LOOK[line break]"; say "OUT THE VIEWSCREEN AND SEE ANOTHER SHIP[line break]"; say "FIRING AT YOU.ON THE SIDE IS WRITTEN[line break]"; say "[']INTERSTELLAR POLICE['].YOU'VE GOT A[line break]"; say "LIFE-TIME AHEAD OF YOU...IN GAOL!"; stop the action; A time warp rule (this is the warp 740 rule): if linenumber is greater than 740: continue the action; say "YOU WAIT AND WATCH THE MASSIVE JUNGLE[line break]"; say "THAT LIES BEFORE YOU.EMERGING FROM THE[line break]"; say "ENTANGLEMENT COME TWO FIGURES WEARING[line break]"; say "STRANGE HELMETS.THEIR HELMETS BEAR ODD[line break]"; say "SYMBOLS AND GIVE OFF AN EVIL GLOW.[line break]"; say "ONE POINTS A DEVICE OF SOME KIND AT[line break]"; say "YOUR BACK AND SHOVES YOU TOWARD THE[line break]"; say "PYRAMID.YOU DON'T LIKE THE LOOKS OF[line break]"; say "THESE CREATURES.WILL YOU:(G)O WITH THEM[line break]"; say "OR (D)EMAND TO SEE THEIR LEADER?[line break]"; now ROCKINtimevalid is { 71, 103, 68, 100 }; abide by the timewarp key rule; if ROCKINwarpkey is 71 or ROCKINwarpkey is 103: [G] now linenumber is 980; if ROCKINwarpkey is 68 or ROCKINwarpkey is 100: [D] now linenumber is 955; continue the action; A time warp rule (this is the warp 820 rule): if linenumber is greater than 820: continue the action; say "YOU TRY TO SPEAK TO HIM AND DISCOVER HE[line break]"; say "CAN SPEAK YOUR LANGUAGE.YOU TELL HIM OF[line break]"; say "YOUR PLIGHT AND HE OFFERS TO HELP YOU.[line break]"; say "HE TAKES YOU INTO HIS SHIP AND GIVES[line break]"; say "YOU A MEAL,WHICH YOU EAT THANKFULLY.[line break]"; say "THEN HE SAYS HE CAN GIVE YOU A LIFT[line break]"; say "TO A NEARBY PLANET WHERE YOU MIGHT FIND[line break]"; say "MEANS OF GETTING BACK TO EARTH,OR YOU[line break]"; say "CAN STAY AND LIVE WITH HIM.WILL YOU:[line break]"; say "(S)TAY WITH HIM,OR (G)O THE NEAREST[line break]"; say "PLANET?[line break]"; now ROCKINtimevalid is { 83, 115, 71, 103 }; abide by the timewarp key rule; if ROCKINwarpkey is 83 or ROCKINwarpkey is 115: [S] now linenumber is 910; if ROCKINwarpkey is 71 or ROCKINwarpkey is 103: [G] now linenumber is 1155; continue the action; A time warp rule (this is the warp 910 rule): if linenumber is greater than 910: continue the action; say "YOU TAKE OFF AND EVENTUALLY LAND IN HIS[line break]"; say "COLONY.AT FIRST YOU ARE TREATED AS AN[line break]"; say "OUTSIDER,BUT AFTER AWHILE YOU ARE TAKEN[line break]"; say "FOR ONE OF HIS FAMILY.YOU DIDN'T GET[line break]"; say "BACK TO EARTH,BUT YOU HAVE A HAPPY LIFE[line break]"; say "AT YOUR NEW FRIEND'S COLONY."; stop the action; A time warp rule (this is the warp 955 rule): if linenumber is greater than 955: continue the action; say "YOU DEMAND TO SPEAK TO THEIR LEADER BUT[line break]"; say "THEY SIMPLY CHUCKLE AND PROD YOU ONWARD[line break]"; say "INTO THE PYRAMID.DARKNESS ENGULFS YOU[line break]"; say "AS YOU MOVE DEEPER INTO THE PYRAMID...[line break]"; say "PRESS SPACE...[paragraph break]"; abide by the timewarp space key rule; now linenumber is 980. A time warp rule (this is the warp 980 rule): if linenumber is greater than 980: continue the action; say "YOU MOVE THROUGH SEVERAL CURVING AND[line break]"; say "TWISTING CORRIDORS AND FINALLY EMERGE[line break]"; say "INTO A HUGE,LIT ROOM WITH A LINE OF[line break]"; say "DIFFERENT CREATURES.THE GUARDS FORCE[line break]"; say "YOU INTO THIS LINE.YOU TRY TO[line break]"; say "SPEAK TO OTHER PRISONERS AND YOU[line break]"; say "DISCOVER THAT THIS PYRAMID WAS BUILT[line break]"; say "OVER A MINE CONTAINING MINERALS OF[line break]"; say "INCREDIBLE POWER.A CRIMINAL NETWORK IS[line break]"; say "ENSLAVING CREATURES TO RETRIEVE THE[line break]"; say "MINERALS AND OBTAIN UNLIMITED POWER.YOU[line break]"; say "ARE ABOUT TO JOIN THEM.WILL YOU:[line break]"; say "(W)AIT TO SEE WHAT HAPPENS,OR (M)AKE A[line break]"; say "BREAK?[line break]"; now ROCKINtimevalid is { 87, 119, 77, 109 }; abide by the timewarp key rule; if ROCKINwarpkey is 87 or ROCKINwarpkey is 119: [W] now linenumber is 1090; if ROCKINwarpkey is 77 or ROCKINwarpkey is 109: [M] now linenumber is 1240; continue the action; A time warp rule (this is the warp 1090 rule): if linenumber is greater than 1090: continue the action; say "YOU COME TO THE FRONT OF THE LINE AND[line break]"; say "ARE HELD FAST BY A GUARD.A ROBOT TURNS[line break]"; say "TO YOU AND CLIPS A COLLAR AROUND YOUR[line break]"; say "NECK.SUDDENLY YOU LOSE ALL WILLPOWER.[line break]"; say "IT IS AN OBEDIENCE COLLAR AND YOU CAN'T[line break]"; say "ESCAPE ITS HYPNOTIC EFFECT.YOU WILL[line break]"; say "SPEND THE REST OF YOUR DAYS IN THE DARK[line break]"; say "MINES..."; stop the action; A time warp rule (this is the warp 1155 rule): if linenumber is greater than 1155: continue the action; say "YOU ASK TO BE TAKEN TO THE NEAREST[line break]"; say "PLANET.IT IS CALLED RAKMA AND IS KNOWN[line break]"; say "FOR ITS TECHNOLOGICAL ADVANCES.AFTER[line break]"; say "A SHORT TRIP,YOU LAND IN THE CITYPORT[line break]"; say "OF RAKMA.YOU THANK THE MARTIAN AND WAVE[line break]"; say "AS HE VANISHES INTO THE SKY.NOW WHAT?[line break]"; say "YOU'LL NEED SOME QUARTERS FOR WHILE YOU[line break]"; say "STAY HERE.WILL YOU:(F)IND SOMEWHERE TO[line break]"; say "EAT,OR (G)O STRAIGHT TO A HOTEL?[line break]"; now ROCKINtimevalid is { 70, 102, 71, 103 }; abide by the timewarp key rule; if ROCKINwarpkey is 70 or ROCKINwarpkey is 102: [F] now linenumber is 1350; if ROCKINwarpkey is 71 or ROCKINwarpkey is 103: [G] say "AS YOU LEAVE THE PORT AN ATTENDANT[line break]"; say "GIVES YOU A TRANSLATOR.IT TRANSLATES[line break]"; say "ALIEN SPEECH INTO YOUR LANGUAGE,SO THAT[line break]"; say "YOU CAN COMMUNICATE WITH ANY BEING IN[line break]"; say "RAKMA.PRESS SPACE...[paragraph break]"; abide by the timewarp space key rule; now linenumber is 1395; continue the action; A time warp rule (this is the warp 1240 rule): if linenumber is greater than 1240: continue the action; say "YOU BREAK OUT OF LINE,KNOCK OVER THE[line break]"; say "GUARDS AND RUN INTO A SMALL DOORWAY...[line break]"; say "AGGGG!CRUNCH...YOU'VE FALLEN INTO A[line break]"; say "MINE-SHAFT!YOU CAN HEAR GUARDS COMING[line break]"; say "ABOVE YOU...YOU'LL HAVE TO GO INTO THE[line break]"; say "MINES...WHICH WAY?(L)EFT OR (R)IGHT?[line break]"; now ROCKINtimevalid is { 76, 108, 82, 114 }; abide by the timewarp key rule; if ROCKINwarpkey is 76 or ROCKINwarpkey is 108: [L] now linenumber is 1560; if ROCKINwarpkey is 82 or ROCKINwarpkey is 114: [R] now linenumber is 1290; continue the action; A time warp rule (this is the warp 1290 rule): if linenumber is greater than 1290: continue the action; say "YOU TAKE THE RIGHT TUNNEL AND SOON FIND[line break]"; say "YOURSELF IN COMPLETE DARKNESS.YOU STOP[line break]"; say "RUNNING AND WALK,AFRAID OF BUMPING INTO[line break]"; say "SOMETHING...PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]YOU KEEP GOING.SUDDENLY THE FLOOR GIVES[line break]"; say "WAY AND YOU FIND YOURSELF FALLING...[line break]"; say "SPLASH!YOU LAND IN A DEEP RIVER...YOU[line break]"; say "STRUGGLE TO KEEP ABOVE BUT FATIGUE HITS[line break]"; say "YOU ANDS YOU SLOWLY SINK..."; stop the action; A time warp rule (this is the warp 1350 rule): if linenumber is greater than 1350: continue the action; say "AS YOU LEAVE THE PORT,AN ATTENDANT[line break]"; say "GIVES YOU A TRANSLATOR,WHICH WILL[line break]"; say "TRANSLATE ALL SPEECH INTO YOUR OWN SO[line break]"; say "YOU CAN SPEAK TO ANY TYPE OF BEING.YOU[line break]"; say "WALK THROUGH THE STREETS OF RAKMA,[line break]"; say "MARVELLING AT THE SITES AND THE MANY[line break]"; say "CREATURES FROM AROUND THE GALAXY.SOON[line break]"; say "YOU COME TO A TAVERN.INSIDE YOU GET A[line break]"; say "DRINK AND A TASTY MEAL.PRESS SPACE...[paragraph break]"; abide by the timewarp space key rule; now linenumber is 1395. A time warp rule (this is the warp 1395 rule): if linenumber is greater than 1395: continue the action; say "NEARBY YOU FIND A HOTEL.IT'S CALLED[line break]"; say "[']THE MAXX['].YOU APPROACH THE COUNTER AND[line break]"; say "ASK FOR A ROOM.[line break]"; say "[']THAT WILL BE 20 CREDITS.[']HUMMS THROUGH[line break]"; say "YOUR TRANSLATOR.YOU REALISE YOU HAVE NO[line break]"; say "MONEY!YOU SEARCH YOUR POCKETS,STALLING[line break]"; say "FOR TIME.SUDDENLY YOU FIND SOMETHING.[line break]"; say "A FIFTY CREDIT NOTE.FUNNY,WHERE DID[line break]"; say "THAT COME FROM?STRANGE...YOU PAY AND[line break]"; say "GO UP TO YOUR ROOM.PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]IT'S A COMFY ROOM AND YOU ARE SOON[line break]"; say "ASLEEP IN BED.PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]YOU AWAKEN NEXT MORNING AND SET OUT[line break]"; say "TO FIND MORE HELP TO RETURN TO EARTH.[line break]"; say "BUT WHERE?WILL YOU TRY (E)IDOL STREET[line break]"; say "OR (A)MSTAR AVENUE?"; now ROCKINtimevalid is { 69, 101, 82, 114 }; abide by the timewarp key rule; if ROCKINwarpkey is 69 or ROCKINwarpkey is 101: [E] now linenumber is 1630; if ROCKINwarpkey is 82 or ROCKINwarpkey is 114: [A] now linenumber is 1720; continue the action; A time warp rule (this is the warp 1560 rule): if linenumber is greater than 1560: continue the action; say "YOU ENTER THE LEFT CORRIDOR AND FOLLOW[line break]"; say "IT.TORCHES HANG ON THE WALLS TO LIGHT[line break]"; say "YOUR WAY.AFTER PASSING UNDER A SKULL[line break]"; say "ARCHWAY YOU COME TO A JUNCTION.PRESS[line break]"; say "SPACE..."; say "YOU CAN EITHER:(G)O UP A STAIRWAY,OR[line break]"; say "(E)NTER AN OLD,WOODEN DOOR.[line break]"; now ROCKINtimevalid is { 71, 103, 69, 101 }; abide by the timewarp key rule; if ROCKINwarpkey is 71 or ROCKINwarpkey is 103: [G] now linenumber is 1790; if ROCKINwarpkey is 69 or ROCKINwarpkey is 101: [E] now linenumber is 2180; continue the action; A time warp rule (this is the warp 1630 rule): if linenumber is greater than 1630: continue the action; say "YOU START OFF DOWN EIDOL STREET.AS YOU[line break]"; say "WALK YOU SEE AN OLD BUILDING WITH NO[line break]"; say "SIGN ON THE FRONT.IT MUST BE ABANDONED.[line break]"; say "SUDDENLY YOU STOP.YOU SENSE SOMETHING[line break]"; say "OF VALUE IN THE BUILDING,JUST A KIND OF[line break]"; say "FEELING.WILL YOU:(E)NTER THE BUILDING,[line break]"; say "OR (C)ONTINUE DOWN EIDOL?[line break]"; now ROCKINtimevalid is { 69, 101, 67, 99 }; abide by the timewarp key rule; if ROCKINwarpkey is 69 or ROCKINwarpkey is 101: [E] now linenumber is 1850; if ROCKINwarpkey is 67 or ROCKINwarpkey is 99: [C] now linenumber is 1690; continue the action; A time warp rule (this is the warp 1690 rule): if linenumber is greater than 1690: continue the action; say "YOU FORGET THE BUILDING AND WALK THE[line break]"; say "REST OF EIDOL.IT COMES TO A DEAD END SO[line break]"; say "YOU DECIDE TO CHECK OUT AMSTAR AVENUE.[line break]"; say "PRESS SPACE...[paragraph break]"; abide by the timewarp space key rule; now linenumber is 1720. A time warp rule (this is the warp 1720 rule): if linenumber is greater than 1720: continue the action; say "YOU MOVE DOWN AMSTAR AVENUE.IT'S A[line break]"; say "QUIET PLACE WITH NOT MANY SHOPS ON[line break]"; say "EITHER SIDE.AS YOU WALK,YOU NOTICE YOU[line break]"; say "ARE BEING FOLLOWED.A GANG OF SOMEKIND[line break]"; say "ARE BLOCKING YOUR PATH TO THE REAR.[line break]"; say "AND THEY ARE GETTING CLOSER EVERY[line break]"; say "MINUTE.WILL YOU:(R)UN,OR (P)LAY ALONG[line break]"; say "FOR THE MOMENT?[line break]"; now ROCKINtimevalid is { 82, 114, 80, 112 }; [R or P - either option goes to same place] abide by the timewarp key rule; now linenumber is 2155; continue the action; A time warp rule (this is the warp 1790 rule): if linenumber is greater than 1790: continue the action; say "YOU SLOWLY CLIMB THE STAIRS AND REACH[line break]"; say "THE TOP.YOU CAN HEAR THE FLOORBOARDS[line break]"; say "CREAKING BENEATH YOU.PRESS SPACE...[line break]"; abide by the timewarp space key rule; say "[paragraph break]AS YOU MOVE ALONG A LANDING THE FLOOR[line break]"; say "BOARDS COLLAPSE BENEATH YOU!YOU'RE[line break]"; say "FALLING...FALLING...CRUNCH!!!YOUR[line break]"; say "CRUMPLED BODY WILL REST IN THIS MINE[line break]"; say "FOREVER..."; stop the action; A time warp rule (this is the warp 1850 rule): if linenumber is greater than 1850: continue the action; say "YOU OPEN THE DOOR AND ENTER.IT IS VERY[line break]"; say "DUSTY IN HERE AND OLD-LOOKING MACHINES[line break]"; say "LIE EVERYWHERE.YOU MOVE THROUGH THE[line break]"; say "ROOMS OF THE SHOP,BUT SEE NOTHING OF[line break]"; say "INTEREST.YOU'RE ABOUT TO LEAVE WHEN[line break]"; say "SOMETHING CATCHES YOUR EYE.A MIRROR,AND[line break]"; say "THERE'S NO REFLECTION IN IT!IT IS[line break]"; say "ATTATCHED TO A NEWER LOOKING MACHINE[line break]"; say "WITH A DIAL ON IT.SOMETHING IN YOU[line break]"; say "DESPERATELY WANTS TO TURN THE DIAL.[line break]"; say "WILL YOU:(T)URN IT FORWARDS,OR[line break]"; say "(B)ACKWARDS?[line break]"; now ROCKINtimevalid is { 84, 116, 66, 98 }; abide by the timewarp key rule; if ROCKINwarpkey is 84 or ROCKINwarpkey is 116: [T] now linenumber is 2045; if ROCKINwarpkey is 66 or ROCKINwarpkey is 98: [B] now linenumber is 1950; continue the action; A time warp rule (this is the warp 1950 rule): if linenumber is greater than 1950: continue the action; say "YOU TURN THE DIAL AND LOOK AT THE[line break]"; say "MIRROR.SUDDENLY AN ORIENTAL TEMPLE[line break]"; say "APPEARS IN IT.BEFORE YOU KNOW IT,YOU[line break]"; say "ARE PULLED INTO THE SCENE...PRESS[line break]"; say "SPACE..."; abide by the timewarp space key rule; say "[paragraph break]YOU STAND BEFORE THE TEMPLE AND STARE[line break]"; say "IN DISBELIEF.THE TEMPLE'S ARCHITECTURE[line break]"; say "COULD ONLY BELONG TO ONE PLANET.EARTH![line break]"; say "BUT WHERE ON EARTH?AND IN WHAT AGE?[line break]"; say "FROM THE TEMPLE COME TWO MEN IN FIERCE[line break]"; say "LOOKING ARMOUR.SAMURAI.BEFORE YOU KNOW[line break]"; say "IT YOU ARE DRAGGED INTO THE TEMPLE AND[line break]"; say "THROWN IN A DARK CELL.PRISONERS WHO[line break]"; say "ARE CAUGHT HERE ARE EXECUTED...YOU ARE[line break]"; say "DESTINED TO JOIN THEM..."; stop the action; A time warp rule (this is the warp 2045 rule): if linenumber is greater than 2045: continue the action; say "YOU TURN THE DIAL AND LOOK INTO THE[line break]"; say "MIRROR.SUDDENLY A BUSH SCENE APPEARS IN[line break]"; say "IT.BEFORE YOU KNOW IT YOU ARE PULLED[line break]"; say "INTO IT...PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]YOU ARE NEAR A BUILDING IN THE MIDDLE[line break]"; say "OF A VAST BUSH-AREA.YOU LOOK INTO THE[line break]"; say "BUILDING.A SIGN ON IT SAYS RANGERS[line break]"; say "STATION.YOU ARE OVERCOME WITH JOY...[line break]"; say "YOU'RE BACK ON EARTH!!SUDDENLY THE[line break]"; say "RANGER LEAPS OUT OF HIS HUT,LEAPS INTO[line break]"; say "A JEEP AND DRIVES AWAY.IN THE DISTANCE[line break]"; say "YOU CAN HEAR AN ALARM...PRESS SPACE.."; abide by the timewarp space key rule; say "[paragraph break]YOU GO INTO THE HUT.A MAGAZINE LIES ON[line break]"; say "THE TABLE.THE DATE IS 2045.WHAT?OUTSIDE[line break]"; say "YOU HEAR A MASSIVE EXPLOSION.YOU LOOK[line break]"; say "OUT THE WINDOW.A MUSHROOM CLOUD ERRUPTS[line break]"; say "ON THE HORIZON.YOU HAVE ARRIVED JUST IN[line break]"; say "TIME TO WITNESS THE END OF THE EARTH..."; stop the action; A time warp rule (this is the warp 2155 rule): if linenumber is greater than 2155: continue the action; say "SUDDENLY YOU ARE TACKLED TO THE GROUND[line break]"; say "AND YOUR CREDITS ARE TAKEN FROM YOU...[line break]"; say "YOU STRUGGLE BUT TO NO AVAIL,AND AS YOU[line break]"; say "YELL FOR HELP YOU HEAR A GUNSHOT...AND[line break]"; say "REALISE YOU'RE THE VICTIM..."; stop the action; A time warp rule (this is the warp 2180 rule): say "THE DOOR CREAKS OPEN AND YOU ENTER A[line break]"; say "CAVE,WITH A SHIMMERING POOL IN THE[line break]"; say "CENTRE.EXHAUSTED AFTER YOUR ESCAPE,YOU[line break]"; say "COLLAPSE TO THE GROUND.YOU NEED ENERGY[line break]"; say "AND THE POOL IS ONLY A FEW INCHES AWAY[line break]"; say ",YOU TAKE A HANDFULL AND GULP IT DOWN[line break]"; say "AND YOUR EYES WIDEN AS YOU REALISE[line break]"; say "THERE WAS NO REFLECTION IN THE POOL...[line break]"; say "PRESS SPACE..."; abide by the timewarp space key rule; say "[paragraph break]WHERE ARE YOU...YOU LOOK AROUND...[line break]"; say "YOUR BATHROOM!YOU'RE BACK ON EARTH![line break]"; say "YOU LOOK AT YOUR WATCH.IT HASN'T MOVED[line break]"; say "AT ALL SINCE THE MOMENT YOU WERE PULLED[line break]"; say "INTO THE MIRROR.WAS IT A DREAM...OR WAS[line break]"; say "IT REAL?"; stop the action; Time Warp ends here. ---- DOCUMENTATION ---- Chapter: Overview Time Warp is a self-contained, keypress-driven CYOA you can add to your Glulx or Z8 game/project as an easter egg, feature, or for any other purpose you want. It's been programmed to stay entirely out of the way of the host project, meaning you should be able to plug it in and go. * A player can enter Time Warp, spend any amount of time playing it and replaying it, and then leave it (to return to the host project) without interfering with the state of the host project. An in-and-out trip to Time Warp only takes one regular Inform turn. If you don't want it to take even one turn, please make use of a time-suppressing extension like Eric Eve's Variable Time Control. * Playing Time Warp does not alter the parser command history of the host project, either. Chapter: Inform compatibility * Time Warp is a very simple piece of coding, so general compatibility should be good. * Time Warp works in Glulx and Z8 projects. * As I type this, the current Infom is version 6M62. Time Warp works in 6M62 and was first created back in version 6G60, where it also works. If you go earlier than 6G60, there are no guarantees. Chapter: The Creative Commons Licence under which you can use Time Warp, and How Do You Credit Me? I'm making Time Warp available to Inform programmers via the most accommodating Creative Commons licence that exists as I type this: Attribution 4.0 International (CC BY 4.0) Quote: "Summarily this licence allows users to distribute, remix and build upon a work, and create Derivative Works – even for commercial use – provided they credit the original creator/s (and any other nominated parties)." ( For more details on this licence, visit the following webpage where you can read its full deed: https://creativecommons.org/licenses/by/4.0/ If you want to read the even fuller legalese version, visit the following webpage: https://creativecommons.org/licenses/by/4.0/legalcode ) *** So how do you credit me for the purposes of this licence? If the player can use the VERSION command during your project and the Time Warp extension is listed when they do, consider yourself to have attributed me as much as is required. If the player can't access the VERSION command for some reason, just put the line "Time Warp by Wade Clarke" in your in-game credits... which must be somewhere. It doesn't matter if they're at the head of the project, or the middle, or the end, or viewable at will by the player. So long as this line is in your in-game credits, and players can/will read them, you've credited me. You don't have to credit me outside of the game itself (e.g. on a website, in written documentation) but you can if you want and I'll probably be chuffed. Chapter: A tech note about the microscopic chance that Time Warp could collide with some technology in your project Time Warp creates three global variables. They have the following names, deliberately chosen to avoid namespace collisions with any global variables you've created for your project: ROCKINwarpkey (which is a number variable) ROCKINtimequitter (which is a number variable) ROCKINtimevalid (which is a list of numbers that varies) Time Warp asks your project to include Emily Short's Basic Screen Effects, which your project probably includes anyway. That's all Time Warp needs. Chapter: How to insert Time Warp in your project, and how to access it when playing your project The Inform 7 "Time Warp Demo" project shows you a typical way to plug the game into your host project, and how to access it from the project. Summarily, to add Time Warp to your project, you need to: - Install this Time Warp extension to your extensions folder. - Add the line "Include version 2 of Time Warp by Wade Clarke." to your project. - Then, at the moment in your project that you want the player to enter Time Warp, use the action "run time warp". When the player exits Time Warp, code execution will resume in your project at the next line. Again, please refer to the Time Warp Demo for a specific example of how this can be done.