X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=src%2Fsnowed-in.inf;h=7c28a9dd8595fbf4c2224b39193c5c5c4bd33154;hb=HEAD;hp=501fc75806baf40a0064e1aa7afa308e81b8e8d0;hpb=38ce6f9d5da00d32271f182648d3f0f2d710085e;p=snowed-in.git diff --git a/src/snowed-in.inf b/src/snowed-in.inf index 501fc75..7c28a9d 100644 --- a/src/snowed-in.inf +++ b/src/snowed-in.inf @@ -18,6 +18,7 @@ Array UUID_ARRAY string "UUID://DE9FA2E5-4EC7-4166-9218-E56EFA1DF40F//"; #Ifdef UUID_ARRAY; #Endif; Global lantern_fuel_left = 20; +Global flashlight_battery_power_left = 50; Global body_temperature = 20; Global cabin_has_electricity = 1; Global forest_location = 1; @@ -42,8 +43,10 @@ Constant Headline If not, contact the place you got it from.^^"; Include "parser"; Include "verblib"; -Release 3; -Serial "220610"; +Release 4; +Serial "221129"; + +Include "src/hotel.inf"; Object mainroom "Main Room" with description @@ -56,7 +59,9 @@ Object mainroom "Main Room" kitchenette can be found to the west. There's a doorway in the south wall leading outside.", n_to bedroom, - s_to frontdoor, + s_to + "The weight of the snow against the door is such that it + won't budge.", e_to office, w_to kitchenette, has light; @@ -86,6 +91,12 @@ Object frontdoor "front door" mainroom else return mainroom; ], + before [; + Open: + print_ret + "The weight of the snow against the door is such that + it won't budge."; + ], has scenery door openable; Object bearclaw "bear claw" mainroom @@ -100,9 +111,17 @@ Object sofa "sofa" mainroom with description "The sofa is in poor shape. The upholstery is ripped and there are several holes in it.", + before_implicit [; + Take: + if (action_to_be == ##Eat) + return 2; + ], before [; Take, Pull, Push, PushDir, Turn: print_ret (The) self, " is too heavy for that."; + Open: + TearSub(); + return true; ], has scenery supporter enterable; @@ -112,6 +131,11 @@ Object coffeetable "coffee table" mainroom "The old coffee table looks as if it's had quite a bit of use. There are burn marks covering it and the paint is worn off in most places.", + before_implicit [; + Take: + if (action_to_be == ##Eat) + return 2; + ], before [; Take, Pull, Push, PushDir, Turn: print_ret (The) self, " is too heavy for that."; @@ -170,8 +194,11 @@ Object television "flat-screen TV" mainroom "The flat-screen TV looks fairly modern but it's been broken in a fight and the screen is dangling out.", before [; - Take, Pull, Push, PushDir, Turn: - print_ret (The) self, " is firmly mounted to the wall."; + Take, Pull, Push, PushDir, Turn, Remove: + print_ret + "The damaged electronics throw some sparks, + and you get a mild shock. Perhaps it's best left + where it is."; SwitchOn: if (television hasnt visited) { score = score + 1; @@ -263,7 +290,8 @@ Object office "Office" is a wreck. Holes are in the walls and the window is broken, letting in the cold air from outside. Chunks of drywall and insulation cover the floor. The desk has a - bullet hole through the middle.", + bullet hole through the middle. The main room is to the + west.", before [; Go: if (noun == e_obj) { @@ -271,10 +299,10 @@ Object office "Office" print_ret "You can't fit through the window while wearing the snow shoes."; - } - if (eastofcabin hasnt visited) { - score = score + 1; - give office visited; + if (eastofcabin hasnt visited) { + score = score + 1; + give office visited; + } } ], w_to mainroom, @@ -412,7 +440,8 @@ Object kitchenette "Kitchenette" hard to tell what's a pipe and what's a faucet. A refrigerator, standing open and empty. The door has been ripped off. There's no indication as to where it - went. There's no food anywhere in here.", + went. There's no food anywhere in here. The main room is + to the east.", e_to mainroom, has light; @@ -447,8 +476,8 @@ Object bedroom "Bedroom" with description "This bedroom is small and cramped, and looks like a major fight happened as the exterior wall has bullet - holes. The bed is lying on the floor, torn to shreds. It - has no sheets, just a bare mattress.", + holes. There's a bare mattress, torn to shreds. The main + room is to the south.", s_to mainroom, has light; @@ -494,9 +523,10 @@ Object snowsuit "snowsuit" suitcase } ], daemon [; - if (location ~= mainroom && location ~= office && location ~= - kitchenette && location ~= bedroom && location ~= thedark && - snowsuit hasnt worn) { + if (location == northofcabin || location == southofcabin || + location == westofcabin || location == truckspot || location + == backpacklocation || location == forest && snowsuit hasnt + worn) { body_temperature = --body_temperature; } if (location == mainroom || location == office || location == @@ -576,9 +606,10 @@ Object snowshoes "snowshoes" bedroom knees."; ], daemon [; - if (location ~= mainroom && location ~= office && location ~= - kitchenette && location ~= bedroom && location ~= thedark && - location ~= eastofcabin && snowshoes hasnt worn) { + if (location == northofcabin || location == southofcabin || + location == westofcabin || location == truckspot || location + == backpacklocation || location == forest && snowshoes hasnt + worn) { deadflag = 3; } ], @@ -689,7 +720,7 @@ Object flashlight "flashlight" backpack } give flashlight light; SwitchOff: - give lantern ~light; + give flashlight ~light; ], has switchable; @@ -841,12 +872,12 @@ Object flashlight "flashlight" backpack yourself at a console. The hallucination quickly fades."; 15: - deadflag = 2; - print_ret + print "You see something in the distance but can't make it out. You walk toward it to find out that it's the hotel. You collapse in the lobby as the hotel staff - rush over to you."; + rush over to you.^"; + PlayerTo(lobby1); } } ]; @@ -1049,16 +1080,28 @@ Object westofcabin "West Of Cabin" return false; ]; +Object cabin "cabin" mainroom + with name 'cabin', + found_in mainroom bedroom office kitchenette southofcabin eastofcabin + northofcabin westofcabin, + before [; + Enter, Exit: + print_ret + "You'll have to say which compass direction to go + in."; + ], + has scenery; + Object snowmobile "snowmobile" thedark with name 'snowmobile', daemon [; snowmobile_location = random(14); if (location == forest && forest_location == snowmobile_location) { - deadflag = 2; - print_ret + print "A snowmobile approaches. The person says they - saw your light and came to rescue you."; + saw your light and came to rescue you.^"; + PlayerTo(lobby1); } return true; ], @@ -1186,6 +1229,10 @@ Object grue "grue" thedark return true; ]; +[ TearSub; + print_ret "Doing that would achieve little."; +]; + Include "grammar"; Verb 'About' @@ -1206,17 +1253,47 @@ Verb 'Hint' Verb 'xyzzy' * -> Xyzzy; +Verb 'tear' + * noun -> Tear; + +Extend 'tear' + * 'up' / 'open' noun -> Tear; + +Verb 'rip' + * noun -> Tear; + +Extend 'rip' + * 'up' / 'open' noun -> Tear; + Verb 'crawl' - * 'through' / 'out' / 'via' noun -> Go; + * 'through' / 'out' / 'via' noun -> Enter; Verb 'escape' - * 'through' / 'out' / 'via' noun -> Go; + * 'through' / 'out' / 'via' noun -> Enter; Extend 'jump' - * 'through' / 'out' / 'via' noun -> Go; + * 'through' / 'out' / 'via' noun -> Enter; Extend 'climb' - * 'through' / 'out' / 'via' noun -> Go; + * 'through' / 'out' / 'via' noun -> Climb; Extend 'go' - * 'through' / 'out' / 'via' noun -> Go; \ No newline at end of file + * 'through' / 'out' / 'via' noun -> Enter; + +Extend 'go' first + * 'out' / 'outside' -> VagueGo; + +Extend 'go' first + * 'out' / 'outside' / 'outside' 'of' noun -> VagueGo; + +Extend 'go' first + * 'in' / 'into' / 'inside' -> VagueGo; + +Extend 'go' first + * 'in' / 'into' / 'inside' / 'inside' 'of' noun -> VagueGo; + +Extend 'exit' first + * noun -> VagueGo; + +Extend 'leave' first + * noun -> VagueGo; \ No newline at end of file