// Storyland Program File // storyland { title "The Never-Ending Adventures of Ig And Mo" author "a Million Monkeys" // LOCATIONS - Meaningful places in Storyland. location { name "kitchen" being "in the kitchen" travel "to the kitchen" } location { name "bedroom" being "in the bedroom" travel "to the bedroom" } location { name "blanket" being "under the blanket" travel "under the blanket" } location { name "lap" being "on a lap" travel "onto a lap" } // THINGS - Items that may be necessary to enable an action. thing { name "water dish" location "kitchen" } thing { name "blanket" location "bedroom" } // ACTIONS - Things that are possible for characters to do. // All belief and effect actions must have a corresponding entry // in this list. No past participles for now. // Syntax: "verb" "present tense" "past tense" action { "purr" "purring" "purred" "jump" "jumping" "jumped" "hop" "hopping" "hopped" "walk" "walking" "walked" "wander" "wandering" "wandered" "saunter" "sauntering" "sauntered" "meander" "meandering" "meandered" "burrow" "burrowing" "burrowed" "crawl" "crawling" "crawled" "hide" "hiding" "hid" "drink" "drinking" "drank" "sleep" "sleeping" "slept" "fall asleep" "falling asleep" "fell asleep" } // DESIRES - Things that can motivate characters in Storyland. // Effect and belief "reduces" or "increases" terms must appear here. desire { thirst "thirsty" tired "sleepy" cold "cold" } // EFFECTS - Conditions that actually affect a character's desires. // You can create multiple effect sets for different character types. // The effect type's desires must have already been defined above. // Actions, locations, and things can affect desires. // For example, drinking in same room as water dish reduces thirst. // "action", "thing", and "location" are cumulative requirements, // so [action "drink" thing "water dish" reduces thirst] will reduce // a character's thirst by some random amount only if they are currently // doing "drink" and they are next to "water dish". Thus, their // thirst will not be reduced if they are next to "water dish" but // doing something else. An effect of [thing "heater" reduces cold] // would reduce cold regardless of their action, so long as they were // next to a heater. effect { type "cat" action "drink" thing "water dish" reduces thirst action "sleep" reduces tired action "fall asleep" reduces tired location "blanket" reduces cold location "blanket" increases thirst location "lap" reduces cold } // BELIEFS - These cause characters to run around and do stuff. // You can create multiple belief sets for different character types. // Characters believe that taking these actions will satisfy certain // desires, but it is really the character's effect list that does that. // You might make the character believe that walking to the kitchen // will alleviate thirst, but in truth you only want to get them closer // to the water dish, // Syntax: // (what character can do to try to satisfy desire) // [] (taking action moves character to this location) // [] (requires character be at this location) // [] (requires this thing be present) // (character only believes this to be true) belief { type "cat" action "jump" to "lap" from bedroom reduces cold action "hop" to "lap" from bedroom reduces cold action "walk" to "kitchen" reduces thirst action "saunter" to "kitchen" reduces thirst action "meander" to "kitchen" reduces thirst action "wander" to "kitchen" reduces thirst action "drink" thing "water dish" reduces thirst action "walk" to "bedroom" reduces tired action "walk" to "bedroom" reduces cold action "wander" to "bedroom" reduces tired action "wander" to "bedroom" reduces cold action "saunter" to "bedroom" reduces tired action "saunter" to "bedroom" reduces cold action "meander" to "bedroom" reduces tired action "meander" to "bedroom" reduces cold action "burrow" to "blanket" thing "blanket" reduces tired action "burrow" to "blanket" thing "blanket" reduces cold action "crawl" to "blanket" thing "blanket" reduces tired action "crawl" to "blanket" thing "blanket" reduces cold action "hide" to "blanket" thing "blanket" reduces tired action "hide" to "blanket" thing "blanket" reduces cold action "sleep" from "blanket" reduces tired action "fall asleep" from "blanket" reduces tired action "sleep" from "lap" reduces tired action "fall asleep" from "lap" reduces tired action "purr" from "lap" reduces thirst action "purr" from "lap" reduces cold } // CHARACTERS - Autonomous creatures that live in Storyland. character { name "Ig" is "is a black cat" gender "male" effect "cat" belief "cat" } character { name "Mo" is "is a black and white cat" gender "male" effect "cat" belief "cat" } }