! STEALING CANDY FROM A BABY ! Version 1 ! By Artur Seitllari !--------------------------------------------------------------------------- !objects: Kitchen, BAthroom, Bedroom, Living_room, Hall_way !--------------------------------------------------------------------------- Constant Story "STEALING CANDY FROM A BABY"; Constant Headline "^An Interactive Tutorial^by Artur Seitllari^"; Constant DEBUG; Include "parser"; Include "verblib"; Include "grammar"; !Global swap; Global ointb = 0; Global ointw = 0; Class Candy has; Class Room has light; Class Furniture with before [; Pull,Push: print_ret"You'll hurt your bad back doing that"; ], has static scenery; !===========================BEDROOM============================================= !---------------------------------------------------------------------------------- !object name: bedroom !object class type: room !Location: starting point !contents: bed, ni_drawer, closet, window, wall, floor !main objects: bed, nightstand drawer, wall, floor, window, bathroom !possible movement: W-living room, E-closet, N-kitchen, S-bathroom !odd functions: opening story done with room test, if-exit room test for clothes !------------------------------------------------------------------------------- Room bedroom "BEDROOM" with description "Scattered are empty wrappers on your bed and empty open boxes of your favorite candy. It looks like you massacred the rest of the candy to recover from a break up. There is a nightstand drawer with your wallet, a closet to the east, an open door north leading to the kitchen, and an open door west leading to the living room, an open door south leading to your bathroom and a window overlooking out to the street.^", s_to bathroom, e_to closet, !---------------------goes otside without clothes--------------------- n_to [; if (clothes hasnt worn) print_ret "The people from the street have a good view of your kitchen and your butt if naked!"; else PlayerTo(kitchen); ! return false; ], w_to [; if (clothes hasnt worn) print_ret "The people from the street have a good view of your kitchen and your butt if naked!"; else PlayerTo(living_room); ! return false; ]; [ initialise; location = bedroom; print "^^You're laying semi-naked in your bed thinking of your ex-girlfriend who left you last night. The one thing that makes you feel better is your favorite candy yet you realize there is none. All of the sudden you crave more candy. YOU WANT CANDY.....^^"; ]; !----------------------------------bedroom objects--------------------------------- !Objects: bed, ni_drawer, window, wall, floor ! ! wrappers: need one to simulate a mock full candy ! bed: bed ! clothes: need to go outside ! wall, floor: wall, floor ! nightstand: holds wallet !---------------------------------------------------------------------------------- !---------------------------------------------------------------------------------- !name: bed !type: furniture !place: bedroom !has: container open static !---------------------------------------------------------------------------------- Furniture -> bed "bed" with name 'bed' , description "The place where you shared nice memories with your girly. The crave for your favorite candy grows bigger.", has container open static; !--------------------------------------------------------- !name: ni_drawer !type: object !init: nightstand drawer !purpose: looks !has: wallet !--------------------------------------------------------- Object ni_drawer "drawer" bed with name 'drawer' 'nightstand', description "The drawer to the nightstand!", has enterable container openable; !--------------------------------------------------------- !name: wallet !type: object !init: ni_drawer !purpose: looks !has: container clothing !-------------------------------------------------------------- Object wallet "wallet" ni_drawer with name 'wallet', description "Its your wallet.", before [;Take: move wallet to player; remove wallet; Open: "I hate to break this to you but your wallet is ....wait....wait... let it sink in a bit..................EEEEEEEEMPTY!!", ointw = 1; ], has enterable container openable; !------------------------------------------------------------------ !name: window !type: furniture !place: bedroom !purpose: looks !has: nothing !------------------------------------------------------------------- Furniture -> window "bedroom window" with name 'window', initial "Rays from the bright sun are reflecting off of it into your bedroom.", description "You are not about to jump. Not a good idea.", before [; climb: "Try another way!"; ], has; !------------------------------------------------------------------ !name: wall/floor !type: furniture !place: bedroom !purpose: looks !has: nothing !------------------------------------------------------------------- Furniture -> bedwall "bedroom wall" with name 'wall', description "A nice assembled collage with pictures with you and your ex-girly is plaseterd into your wall. You're reminded of her once again. Very SAD...", before [; Take, remove: print_ret " Thats not something you can remove."; ], has; Furniture -> bedfloor "bedroom floor" with name 'carpet' 'floor', description "More wrappers....", before [; Take: print_ret "The rug is firmly attached to the floor."; Enter: print_ret "The rug is firmly attached to the floor."; ], has; !------------------------------------------------------------------------------- !OBJECT name: wrapper !Object class type: furniture !Location: bedroom !Possible movement: mock candy !------------------------------------------------------------------------------- Object wrapper "wrapper" bed with name 'wrapper', description "An empty wrapper.", before [; Open:"It's empty!"; Take: move wrapper to player; remove wrapper; print "Ahhhh yes.^You've got the smarts.^You can build a new item with a good combination of items.^ A new item will be born."; ], has; !------------------------------------------------------------------------------- !===============================CLOSET=========================================== !------------------------------------------------------------------------------- !object name: closet !object class type: room !Location: east of bedroom !contents: clothes !visiable: clothes !main objects: clothes !possible movement: west back to bedroom !------------------------------------------------------------------------------- Room closet "CLOSET" with name 'closet', description "The motherload of clothes! You're not the neatest nor the cleanest person aournd.", !--------incase user types something other than exit closet------------------- before [; Exit, Go: if (player in closet && ( noun == n_obj || noun == closet) ) print_ret "Hmm, where?", PlayerTo(bedroom); close:"There is no door to close. Duh!"; ], w_to bedroom, has enterable container openable; !--------------------------------------------------------- !Object name: clothes !type: object !place: bedroom floor !has: clothing !--------------------------------------------------------- Object clothes "stack of clothes" closet with name 'clothes' 'belt' 'pants' 'shirt', description "You're wearing your favorite outfit. You're ready to move on.", before [; Drop: "OOPPS pull up your pants!"; ], after [;wear: "You look good."; ], has clothing; !===========================BATHROOM============================================= !--------------------------------------------------------------------------------- !Object name: bathroom !Object class type: room !Location: south of bedroom !Main objects: toilet, sink, bath, mirror, scissors !------------------------------------------------------------------------------- Room bathroom "BATHROOM" with name 'bathroom', description "YOU REAK....!^You're in the lavatory. The toilet looks like its been used by someone who had a lot of Chinese. You can see yourself in the mirror cabinet and you wonder why the acne hasn't gone away even at 25.", n_to bedroom; !----------------------------------bath objects--------------------------------- !------------------------------------------------------------------------------- !Object name: toilet !object class type: furniture !Location: bathroom !Movement: none !------------------------------------------------------------------------------- Furniture -> toilet "your toilet" with name 'toilet' 'bowl', description "You releive your self here.", before [; Open: "Its already open!"; Close: "You touched that thing? Gross!"; ], has static supporter container open lockable; !------------------------------------------------------------------------------- !Object name: m_cabinet !object class type: furniture !Location: bathroom !Movement: none !----------------------------------------------------------------------------------- Furniture -> m_cabinet "cabinet" with name 'shiny' 'medicine' 'cabinet', description "Great, you're looking at yourself. Haven't you done that all your life? You keep your cutting utilities, your drugs, and your adhesive products in your cabinet", found_in bathroom, has enterable container openable; !------------------------------------------------------------------------------- !Object name: scissors !object class type: furniture !Location: bathroom !Movement: with player !------------------------------------------------------------------------------- Object scissors "pair of scissors" m_cabinet with name 'scissors' 'pair' 'of', description "Start running with them in your hands.", before [; Take: move scissors to player; remove scissors; print "Ahhhh yes.^You've got the smarts.^You can build a new item with a good combination of items.^ A new item will be born."; ], has; !------------------------------------------------------------------------------- !OBJECT name: tape !object class type: furniture !Location: bathroom !possible movement: nope !------------------------------------------------------------------------------- Object tape "roll of tape" m_cabinet with name 'tape', description "Tape.", before [; Take: move tape to player; remove tape; print "Ahhhh yes.^You've got the smarts.^You can build a new item with a good combination of items.^ A new item will be born."; ], has; !-------------------------------------------------------------------------------- Furniture -> bathwall "wall" with name "wall" "floor" "tile" "celling", description "Good job! You found the wall. DUH!", found_in bathroom; !-------------------------------------------------------------------------------- !===========================KITCHEN============================================= !------------------------------------------------------------------------------- !Object name: kitchen !Object class type: room !Location: west of bedroom !Main objects cabinets, empty boxe !possible movement: backto-bedroom !------------------------------------------------------------------------------- Room kitchen "KITCHEN" with description "This is the kitchen. You cook your food here. Well...somtimes. Just for looks. The ***DRY*** food is in the cabinets. There's also a fridge, a stove,and above the stove there is a microwave.", s_to bedroom; !----------------------------------kitchen objects--------------------------------- !Objects: stove, microwave, exit, cabinets, fridge !Class objects: ! cabinets: empty boxes of your favorite candy are located here !------------------------------------------------------------------------------ !------------------------------------------------------------------ !Object name: fridge !type: furniture !place: kitchen !has: nothing !------------------------------------------------------------------- Furniture -> fridge "fridge" with name 'fridge', description " A large cold box", before [; Take, remove: "Too heavy Superman!"; Climb: "Too high Spiderman!"; Open: " There is not much here. Beer, a bottle of ketchup, a bottle of mustard and pickles. Not much of a shopper are ya."; ], has ; !------------------------------------------------------------------ !Object name: microwave !type: furniture !place: kitchen !------------------------------------------------------------------- Furniture -> microwave "microwave" with name 'microwave', description "Microwaves food! This means it cooks some things. It warms others.", before [; Take, remove: "Too heavy Superman"; Climb: "On the microwave? Who raised you?"; Open: "Its empty!"; ], has ; !------------------------------------------------------------------ !Object name: stove !type: furniture !place: kitchen !------------------------------------------------------------------- Furniture -> stove "stove" with name 'oven' 'stove' 'electric', description " You're not much of a cook. You can tell from the rust thats built up on the iron rings of the burners.", before [; Take, remove: " Too heavy Superman!"; Climb: "Down boy!"; Open: "It's empty!"; ], has ; !------------------------------------------------------------------ !Object name: cabinets !type: furniture !place: kitchen !------------------------------------------------------------------- Furniture -> k_cabinets "kitchen cabinets" with name 'cabinets' 'cabinet', description "The cabinet holds boxes of your favorite candy! Thats about how useful they get.", before [; move box to k_cabinets; take: "NO! Just that simple. I'm not insulting you this time."; climb: "You can see inside. Why would you want to climb."; open: "Sweet! Your emergency box of candy!"; ], has enterable open container; !------------------------------------------------------------------------ Object box "box" with name 'box', description "Its your emergency box of candy!", before [; Open: "I hate to break this to you but your emergency box is ....wait....wait...let it sink in a bit ..................EEEEEEEEMPTY!!", ointb = 1; Take: move box to player; remove box; ], has openable container; !------------------------------------------------------------------ !Object name: wall !type: furniture !init: kitchen !------------------------------------------------------------------- Furniture -> kitwall "kitchen wall" with name 'wall', description "Very dirty! You can see the grease stains with a telescope. Tells a lot about your cleaning habits.", before [; Take, remove: " Stop trying to be Superman!"; Climb: "Did get bit by a spider altering your DNA therefore turning you into Spiderman? I DON'T THINK SO!"; ], has light; !------------------------------------------------------------------ !Object name: floor !type: furniture !init: kitchen !------------------------------------------------------------------- Furniture -> floor "kitchen floor" with name 'floor', description "Like your walls VERY DIRTY!", before [; Take, remove: "NO!"; ], has light; !------------------------------------------------------------------------------------ !===========================LIVING ROOM============================================= !------------------------------------------------------------------------------- !Object name: living room !Object class type: room !Location: west of bedroom !visiable: TV, couch !Movement: backto-bedroom !------------------------------------------------------------------------------- Room living_room "LIVING ROOM" with name 'live' 'room', description "Most of your time is spent in the living room. You like to live simple, wihtout any fancy furniture of fancy gadgets. A couch and a TV is all you need.^You hear some voices coming from the corridor. Only the words humming the name of your favorite candy come out to you. To the west is there is the open door to corridor.", w_to[; if (ointb == 0 || ointw == 0) print_ret "Your favorite candy might be smiling at you. Plus money can buy a lot of things."; else PlayerTo(corridor); ], e_to bedroom; !----------------------------------living room objects--------------------------------- ! Objects: TV,couch ! Class objects: ! TV: TV is on making very noise !------------------------------------------------------------------------------------- !------------------------------------------------------------------ !Object name: couch !type: furniture !place: living room !has: light !------------------------------------------------------------------- Furniture -> couch "couch" with name 'couch', description "Your king throne.", before [; Take, remove: "Too heavy Superman!"; Climb: "That accomplishes nothing!"; ], has ; !------------------------------------------------------------------ !Object name: TV !type: furniture !place: living room !------------------------------------------------------------------- Furniture -> TV "TV" with name 'TV', description "Just your avarage TV. An amazing piece of appliance given that you you spend more time watching it and playing video games, than doing anything else.", before [; Take, remove: "Too heavy Superman!"; ], has ; !--------------------------------------------------------------------------------------- !================================CORRIDOR============================================= !------------------------------------------------------------------------------- !Object name: CORRIDOR !Object class type: room !Location: west of living room !visiable: baby !Movement: backto-living room !------------------------------------------------------------------------------- Room corridor "CORRIDOR" with description "There is someone talking to your neighbor. Beside it there is a baby holding a candy like object but you're not sure.", rtrue, e_to living_room; !---------------------------------Baby object--------------------------------- !Object name: Baby !object class type: object/creature !Location: hallway !contents: candy !Movement: none !------------------------------------------------------------------------------- object baby "baby" with name 'baby' 'child', description "The baby seems happy with his candy in his hands. His face is filled with joy and happiness.", before[; Swap:; ], life [; ask, answer, tell, order: "You'll distract the mother."; Kiss: "The baby will start crying."; Attack: "No touchie!"; ], found_in corridor, has animate male; !--------------------------------candy objects---------------------------------------- !----------------------------------------------------------------------------- !Object name: mock_candy !object class type: object !Location: corridor !contents: candy !Movement: in player !------------------------------------------------------------------------------- Candy -> mock_candy "mock candy" with name 'mock candy', description "You have a stealth mock candy.", has; !----------------------------------------------------------------------------- !Object name: real_candy !object class type: object !Location: corridor !contents: candy !Movement: in player after swap !------------------------------------------------------------------------------- Object real_candy "real candy" baby with name 'real candy', description "HHHHHMMMMMMMMMMM, SOOOOOOOO GOOOOOOOOOD!", before[;Eat: print"HHHHHMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMMM GOOOOOOOOOOOOO^ You have your candy and now you're finally releived."; ], has; !================================Other Verbs============================================== Verb 'play''mess' * 'with'/'in' noun -> play * noun -> play; [PlaySub; if(location == bathroom && noun == toilet) print "You're not the cleanest person. Thats nasty.";]; Verb 'swap' * noun -> swap; [SwapSub; if(location == corridor && mock_candy in player) { move mock_candy to baby; move real_candy to player; } print"You have succeded in taking the candy.^ YOU CAN FINALLY ENJOY WHAT YOU'VE CRAVED THIS WHOLE TIME.";]; Verb 'build' * noun -> build; [buildsub; if(scissors in player && tape in player && wrapper in player) { move mock_candy to player; remove scissors; remove tape; remove wrapper; print "OK. YOU HAVE A MOCK CANDY! WHATS NEXT?^A FIVE STORY BULDING OUT OF TAPE?"; } else print"You don't have a good enough combination of items. ^Build a new item with them to create something you might have a use for."; ];