;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; World Objects ;;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;; Use a "obj:" prefix for all symbols so they are easily identified. ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;; Odd objects that behave a little differently than most objects ;; A heroin-stuffed tackle dummy, well-loved. (define obj:stumpy (make :nick '(stumpy) :name "Stumpy the Tackle Dummy" :location loc:elevator :description (echos "A cylindrical tackle dummy, approximately 5ft x 2ft." "Obviously stumpy has seen many hours of play in his time." "He has a small tear in his side. A small amount of white" "powder has sifted out of the tear and has collected on the" "floor in a small mound."))) ;; Key to the closets (define obj:key (make :nick '(key) :name "key" :location obj:stumpy :size 3 :description "A small brass-colored key.")) ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;; Objects (define obj:candlestick (make :nick '(candlestick) :name "Candlestick" :location (random-elt *location*) :size 7 :description (echos "A long, thick, mean-looking candlestick. This ain't" "nothing from Yankee Candles(tm). The base of the" "candlestick is blunt and heavy, delicately engraved" "with bizarre carvings. Clearly, this was crafted by" "some deranged candlestick maker, decades ago.") :effect (echos "The skull has been broken, as if struck with a" "heavy blunt object with great force. Around the" "periphery of the wound are traces of candle wax."))) (define obj:revolver (make :nick '(revolver) :name "Revolver" :location (random-elt *location*) :size 7 :description (echos "Light gleams off the barrel of this deadly weapon." "You can almost smell a whiff of gunpowder wafting" "from the gun. The handle is blunt and heavy," "delicately engraved with bizarre carvings. Clearly," "this was crafted by some deranged gunsmith, decades" "ago.") :effect "There are six bullet holes in the torso.")) (define obj:knife (make :nick '(knife) :name "Knife" :location loc:lounge :size 7 :description (echos "A massive, serrated blade. Twisted edges of metal" "seem to sheer off in random directions, pointing" "sharp, bloody death at the unfortunate subject of" "this gruesome tool. The base of the knife if pure oak" "delicately engraved with bizarre carvings. Clearly," "this was crafted by some deranged knifesmith, decades" "ago.") :effect "There are several large stab wounds in the torso.")) (define obj:rope (make :nick '(rope) :name "Noose" :location (random-elt *location*) :size 7 :description (echos "The noose is constructed from heavy rope. The knots are" "thick and complex, with sharp bits of twine sticking out" "every which way. The rope twists into bizarre patterns." "Clearly, this noose was tied by some deranged noose-tier," "decades ago.") :effect (echos "The victim apparently died from strangulation. There are" "bruises around the neck, along with traces of fiber. The" "victim's eyes are all bugged out, his tongue is hanging out" "of the side of his mouth, and his face is blue."))) (define obj:leadpipe (make :nick '(pipe) :name "Lead Pipe" :location (random-elt *location*) :size 7 :description (echos "A heavy, blunt lead pipe. You could kill someone with" "this, or at least relieve them of most of their skull." "the base of the pipe is delicately engraved with bizarre" "carvings. Clearly, this was crafted by some deranged" "pipemaker, decades ago.") :effect (echos "The skull has been crushed with a blunt cylindrical object," "apparently wielded with great force. There are traces of" "lead around the wound."))) (define obj:wrench (make :nick '(wrench) :name "Wrench" :location (random-elt *location*) :size 7 :description (echos "A rusty wrench. This malicious, evil-looking wrench must" "have tightened many an innocent bolt in its time. It would" "certainly be no fun to killed by _this_ item. The wrench" "has an unusual handle, which is delicately engraved with" "bizarre carvings. Clearly,this was crafted by some deranged" "mechanic, decades ago.") :effect (echos "The skull has been crushed with a blunt object apparently" "wielded with great force. There are traces of grease around" "the wound."))) (define obj:cat5 (make :nick '(cat5) :name "Category 5 Ethernet Cable" :location (random-elt *location*) :size 7 :description (echos "You see some Cat-5 ethernet cable. The shielding is strong" "and highly resistent to magnetic interference. There's a" "dangerous-looking RJ-45 plug at one end, which is delicately" "engraved with bizarre carvings. Clearly, this was crafted" "by some deranged geek, decades ago.") :effect (echos "The victim has apparently died of strangulation. There are" "thin bruises on the neck as if made by a wire or cable. His" "eyes are all bugged out, his tongue is hanging from the side" "of his mouth, and his face is blue."))) (define obj:ppd (make :nick '(ppd pen) :name "Pen of Point Deduction" :location (random-elt *location*) :size 2 :description (echos "Forged in the flames of Hell itself, the Pen of Point" "Deduction is used to strip points from foolish students who" "dare not to state their Inductive Hypothesis. Ink as red as" "the blood of the damned flows through this unholy artifact." "The handle itself is made from white plastic, which is" "delicately engraved with bizarre carvings. Clearly, this" "was crafted by some deranged TA, decades ago."))) (define obj:coke (make :nick '(machine) :name "Coke Machine" :location loc:vending :size 300 :description (echos "The choices of this coke machine abound. There's Coca-cola," "Fresca, Root Beer, and a few other unhealthy looking things." "You feel lucky that problem set four still offers the" "refreshing taste of Coca-cola... at least the course staff" "hasn't succumbed to the evil ways of Pepsi. Then you think" "this is a game, it's supposed to be Pepsi. Then you think" "of those annoying Pepsi commercials and once again you are" "happy that this is indeed a Coke machine and not Pepsi."))) (define obj:manual (make :nick '(manual) :name "A Scheme Manual" :location loc:csuglab :size 5 :description (echos "It's the Swindle manual. Brandon must have forgotten this" "book here when he was writing the game. It looks like there" "are a few things scribbled inside."))) ;; A pink elephant, inspired from the world of AA. (define obj:elephant (make :nick '(elephant) :name "A Pink Elephant" :location loc:upson320 :size 5 :description "A stuffed pink elephant. You can whap people with it.")) ;; Telephone in the CSUG lab (define obj:telephone (make :nick '(phone) :name "Telephone" :location loc:csuglab :size 8 :description (echos "A simple wall-mounted telephone which has seen better" "days. The phone cord is bent all over, and scratch marks" "seem to indicate that this phone has been used as a football" "quite a few times."))) ;; Chinese food (define obj:chinesefood (make :nick '(food) :name "Chinese Food" :location loc:csuglab :size 5 :description (echos "Stuffed in the brown bag are white boxes that smell like" "chinese food. On the outside of the bag is written," "\"Here's some extra soup for you Honey\". However, on" "taking a closer whiff, you realize that it actually smells" "like REAL chinese food instead of the crap that they call" "chinese food out here in the middle of nowhere. In the" "bottom of the bag is a fortune cookie."))) ;; Fortune cookie containing code to closet door locks (define obj:cookie (make :nick '(cookie) :name "Fortune Cookie" :location loc:csuglab :size 2 :description "An ordinary fortune cookie.")) ;; Fortune in the fortune cookie with code to closet door locks (define obj:fortune (make :nick '(fortune) :name "Fortune" :location loc:csuglab :size 1 :description (echos "A fortune from a fortune cookie, which reads:" "\"Many doors will open for you. Lucky numbers: 1 2 4 5\"") :visible #f)) (define obj:keycard (make :nick '(id) :name "Cornell ID" :location loc:upson320 :size 3 :description (echos "This is Bradley Fondu's Cornell ID. It looks like it's been" "to a dining hall because there's a tear forming down the" "middle, probably from being shoved through a cash" "register."))) (add-command obj:elephant 'items (list :or '(whap) (list 'whap symbol?)) "whap [] Whap someone with a pink elephant" (lambda (plyr inp) (let* ((length (length inp)) (target (and (= length 2) (nick-find (second inp) (contents (location plyr)))))) (cond ((= length 1) "You must whap someone.") ((eq? plyr target) (echos "You take your elephant by the snout and swing" "around, whapping yourself soundly in the head!")) ((animate? target) (tell target (echos (name plyr) "takes" (get-possessive plyr) "elephant by the snout and swings" "around, whapping you soundly in" "the head.")) (place-message (location plyr) (list plyr target) #f (echos-ns (name plyr) " takes " (get-possessive plyr) " pink elephant by the head and" " swings around, whapping " (name target) " soundly in the head.")) (echos "You take your elephant by the snout and swing" "around, whapping" (name target) "in the head.")) (target "You look really funny whapping that...") (else (echos "There is no one named" (second inp) "in the vicinity."))))))