diff --git a/Directionality.i7x b/Directionality.i7x index 184e78a..5845d57 100644 --- a/Directionality.i7x +++ b/Directionality.i7x @@ -1,74 +1,87 @@ -Version 1/150126 of Directionality by Fictitious Frode begins here. +Version 2/170401 of Directionality by Fictitious Frode begins here. "Provides automated listing of all exits from a room." -A room can be known or unknown. A room is usually unknown. +Include Epistemology by Eric Eve. -Carry out looking (This is the Direction Listing rule): - Let known-exits be {""}; - Now known-exits is {}; - Let unknown-exits be {""}; - Now unknown-exits is {}; - repeat with direction running through directions: +Carry out looking (This is the direction listing rule): + Let known-exits be a list of text; + Let unknown-exits be a list of text; + Repeat with direction running through directions: Let destination be the room-or-door direction from location; + If destination is a door and destination is undescribed, next; [This should cover the Standard Rules' implementation of hidden doors] If destination is a door: Let throughfare be destination; Let destination be the other side of destination from location; - If destination is visited or destination is known, add "[Destination] is [direction] (through [throughfare])" to known-exits; + If destination is visited or destination is known, add "[Destination] [are] [direction] (through [throughfare])" to known-exits; Else: - If destination is visited or destination is known, add "[Destination] is [direction]" to known-exits; - If destination is unknown and destination is unvisited, add "[direction]" to unknown-exits; + If destination is visited or destination is known, add "[Destination] [are] [direction]" to known-exits; + If destination is not known and destination is unvisited, add "[direction]" to unknown-exits; If number of entries in known-exits is 0: If number of entries in unknown-exits is 0, say "There are no clear exits from here."; - else say "There are exits [unknown-exits]."; - else: + Else say "There are exits [unknown-exits]."; + Else: If number of entries in unknown-exits is 0, say "[Known-exits]."; - else say "[Known-exits]. There are also exits [unknown-exits]."; + Else say "[Known-exits]. There are also exits [unknown-exits]."; Directionality ends here. ---- DOCUMENTATION ---- -Chapter - Using this Extension +Chapter 1 - Using this Extension -The main functionality will come by just importing the extension in an Inform 7 project: +The main purpose for this extensions is for testing and development work, when room connections change and updating room descriptions can be easily forgotten. + +To use this framework, you need to download and install it (which you probably have if you're reading this) and include it in your story: +*: Include Directionality by Fictitious Frode. -After printing the room description, Inform will now print a line listing all the exits from the current location. If the player has knowledge of the destination by visiting it, the name will also be listed. Note that this does not check that the player knows that this exits leads to the destination. +After printing the room description, Inform will now print a line listing all the exits from the current location. +If the player has knowledge of the destination by visiting it, the name will also be listed. +Note that this does not check that the player knows that this exits leads to the destination. -The main purpose for this extensions is for testing and development work, when room connections change and updating room descriptions can be easily forgotten. +Section 1.1 - Exploration -Section - Known Rooms - -For games where the player is "exploring" an area that is know to the character, it's possible to set rooms as known, in order to have them show up in the destination listing. +For games where the player is "exploring" an area that is known to the character, it's possible to set rooms as familiar, in order to have them show up in the destination listing. +Eric Eve's Epistemology extension is used to provide this support. The Library is north of the Hallway. - The Hallway is known. + The Hallway is familiar. + +When determining wether an exit is known or unknown, it's not the exit that's being evaluated but the destination. +This has some implications for rooms that are accessible from multiple directions, and shortcuts. +Secret doors are handled according to the Standard Rules; a door that is not described is not listed. -Chapter - Technical Notes +Section 1.2 - Version History -When determining wether an exit is known or unknown, it's not the exit that's being evaluated but the destination. This has some implications for rooms that are accessible from multiple directions, and shortcuts. +2015-01-26 (Release 1) -Secret/hidden connections are not handled, but is a point for future updates. + Initial functionality. + +2017-04-01 (Release 2) -Section - Version History + Incorporated Eric Eve's Epistemology instead of the custom 'known/unknown' property. + Support for hidden doors, as implemented in the Standard Rules (using undescribed to imply the player is unaware they exist) + Minor documentation changes. -Section - Contact Info +Section 1.3 - Contact Info -The author of the framework can be reached in the following ways: +The author of this extension can be reached in the following ways: - * Mail: fictitious.frode@gmail.com - * Blog: https://informedaif.wordpress.com/ is a blog dedicated to writing AIF with Inform 7, and is the official host of the framework. It contains both dicussions around AIF and tutorials on both Inform in general and this framework in particular. - * Reddit: https://www.reddit.com/r/AIFCentral/ is the subreddit for the AIF community, and the author checks this regularly. + Mail: fictitious.frode@gmail.com + Blog: https://informedaif.wordpress.com/ is a blog dedicated to writing AIF with Inform 7, and is the official host of the extension. It contains both dicussions around AIF and tutorials on both Inform in general and this extension in particular. + Reddit: https://www.reddit.com/r/AIFCentral/ is the subreddit for the AIF community, and the author checks this regularly. + GitHub: https://github.com/FictitiousFrode/AIF Contains the latest version of the extension, possibly including functionality that hasn't been released yet. -Feedback of all varieties is welcome, but constructive criticism and discussion is the most appreciated, along with reports of bugs and other issues. For support I would appreciate using public communication, so that other may learn from the request as well. +Feedback of all varieties is welcome, but constructive criticism and discussion is the most appreciated, along with reports of bugs and other issues. +For support I would appreciate using public communication, so that other may learn from the request as well. Example: * Directions to known and unknown rooms. Library is a room. "This is a library." Closet is inside from Library. "A small closet." - Closet is known. + Closet is familiar. Hallway is south of Library. "A long hallway." Bathroom is a room. "A public bathroom." A bathroom door is a door. A bathroom door is north of library and south of bathroom. diff --git a/Erotic Storytelling.i7x b/Erotic Storytelling.i7x index e1a9953..a76d593 100644 --- a/Erotic Storytelling.i7x +++ b/Erotic Storytelling.i7x @@ -1,4 +1,4 @@ -Version 2/170302 of Erotic Storytelling by Fictitious Frode begins here. +Version 2/170401 of Erotic Storytelling by Fictitious Frode begins here. "An extension focused on writing Adult Interactive Fiction (AIF) in Inform. The main features are a layered clothing with body parts and erotic actions with system for obtaining consent on actions involving others characters. Also includes an optional customizable ready-to-use Discrete-Arousal-based Consent and Stimulation systems, semi-automatic improved description generation, and templates for NPC agency and optional story contents." @@ -3326,10 +3326,11 @@ The cover locations of some breasts is usually {the upper torso area}. Understand "tit", "tits", "breast", "boob", "boobs", "tittie", "titties" and "juggs" as some breasts. Some breasts is usually touchable. Some breasts is usually rubbable. Some breasts is usually tickleable. Some breasts is usually lickable. Some breasts is usually biteable. Some breasts is usually pinchable. -A midriff is a kind of body part. -The cover locations of a midriff is usually {the lower torso area}. -Understand "stomach", "tummy" as midriff. -A midriff is usually touchable. A midriff is usually rubbable. A midriff is usually tickleable. A midriff is usually lickable. +An abdomen is a kind of body part. +The indefinite article is usually "an". +The cover locations of an abdomen is usually {the lower torso area}. +Understand "stomach", "tummy", "belly", "midriff" as abdomen. +An abdomen is usually touchable. An abdomen is usually rubbable. An abdomen is usually tickleable. An abdomen is usually lickable. A waist is a kind of body part. The cover locations of a waist is usually {the lower torso area, the lower back area}. @@ -4379,6 +4380,7 @@ For example, a player may not know whether a person is wearing a bra, but the pl While you're free to create your own body parts as you please, this extension comes with a variety of ready-made template parts you can use. Below is an overview of the body part templates, with the most pertinent properties controlling which actions are possible (see section 2.1) and the default decency (as implied by their cover locations): + Abdomen (Immodest): touchable, rubbable, lickable, tickleable Ass (Indecent): touchable, rubbable, spankable, pinchable, lickable, orificial. Ankles (Immodest): plural; Arms (Casual): plural; touchable, rubbable @@ -4392,7 +4394,6 @@ Below is an overview of the body part templates, with the most pertinent propert Hands (Formal): plural; touchable, rubbable Head (Formal): Legs (Casual): plural; touchable, rubbable - Midriff (Immodest): touchable, rubbable, lickable, tickleable Mouth (Formal): Neck (Casual): lickable, biteable Penis (Indecent): touchable, rubbable, pinchable, lickable, biteable, penetrating. @@ -4498,11 +4499,11 @@ Section 1.7 - Version History * DACS is functional but untested. * Some out-of-world actions are not yet implemented. -Release 2 (In Development) - - * Bug fixes on mini dress (courtesy of allisonedwards) - * Clothing layer fix (courtesy of allisonedwards) +2017-04-01: Beta-2 (Release 2) + * Midriff renamed to abdomen + * Bug fixes on mini dress and clothing layer (courtesy of allisonedwards via GitHub) + * Updated documentation and examples Section 1.8 - Contact Info @@ -4560,11 +4561,11 @@ The adjectives, along with which templates they are set for, are: Lickable: Ass, Breasts Orificial: Ass, Vagina Penetrating: Penis - Pinchable: Ass, Breasts, Chest, Feet, Midriff, Neck, Penis, Vagina - Rubbable: Arms, Ass, Backside, Breasts, Chest, Feet, Hands, Legs, Midriff, Penis, Shoulders, Thighs, Vagina + Pinchable: Ass, Breasts, Chest, Feet, Abdomen, Neck, Penis, Vagina + Rubbable: Arms, Ass, Backside, Breasts, Chest, Feet, Hands, Legs, Abdomen, Penis, Shoulders, Thighs, Vagina Spankable: Ass, Backside - Tickleable: Breasts, Chest, Feet, Midriff - Touchable: Arms, Ass, Breasts, Chest, Feet, Hands, Legs, Midriff, Penis, Thighs, Vagina + Tickleable: Breasts, Chest, Feet, Abdomen + Touchable: Arms, Ass, Breasts, Chest, Feet, Hands, Legs, Abdomen, Penis, Thighs, Vagina To control what behavior is proper in a given location we introduce Decency as a new kind of value, which is explained in more detail in section 3.2. By default decency has the four possible values indecent, immodest, casual and formal, as well as the undefined decency to serve as an unset/null-value. @@ -4756,10 +4757,10 @@ In order to manipulate a garment in this way, these revealed cover areas have to The following templates are rippable and will reveal: - pair of Panties: crotch - pair of Pantyhose: crotch + Panties: crotch + Pantyhose: crotch Shirt: shoulder, upper/lower torso - pair of Stockings: thigh + Stockings: thigh Undershirt: upper torso The following templates are shiftable in a given way and will reveal: @@ -4768,14 +4769,14 @@ The following templates are shiftable in a given way and will reveal: Dress (Unbutton): shoulder, upper/lower torso Jacket (Unbutton): upper/lower torso Minidress (Raise): crotch, thigh - pair of Panties (Move): crotch + Panties (Move): crotch Shirt (Unbutton): shoulder, upper/lower torso - pair of Shorts (Unzip): Crotch + Shorts (Unzip): Crotch Skirt (Raise): crotch, thigh Suit (Unzip): crotch Sweater (Raise): upper/lower torso Swimsuit (move): upper torso - pair of Trousers (Unzip): Crotch + Trousers (Unzip): Crotch Section 3.4 - Customization @@ -4952,7 +4953,7 @@ When writing responses for actions with multiple actors to check for simultaneou Else: Say "The normal response for the action should go here."; -Chapter 5 - NPCs +Chapter 5 - Improving Non-Player Characters Let's be blunt: Non-Player Characters are hard to get right in Interactive Fiction. The common approach (as described at SibylMoon *) is to limit the player's interaction with NPCs to as little as you can get away with. @@ -5040,7 +5041,7 @@ Note that any attempts to ask Beatrice to do something will not work as we haven Test me with "kiss Beatrice / lick Beatrice / fuck Beatrice / z / kiss Beatrice / lick Beatrice / fuck Beatrice / Beatrice, rub cock". -Section 5.2 - Agency +Section 5.2 - Character Agency One of the most important ways to distinguish characters is to give them the agency to act on their own. While characters in traditional AIF is mainly stationary, it's easy to use Inform's every turn rules to make them act on their own. @@ -5073,17 +5074,19 @@ These rules are therefore only processed if the player can see that person when Example D shows how agency can be implemented, and the tutorial contains a section on how multiple sex partners may be implemented. -Section 5.3 - Conversation +Section 5.3 - Conversations Conversations are usually an important part of character-driven IF, but it's also one of the hardest parts to get right. -Because the player is free to converse about anything that strikes their fancy, a good conversation system must both understand what topic the player is referring to and have a response for it. -Most of the time we also need to keep track of which topics are available, depending on many factors such the knowledge of both the player and the characters. - +As the player is free to converse about anything that strikes their fancy, a good conversation system must both understand what topic the player is referring to and have a proper response for it. Inform 7 provides various extensions, available in the built-in extension library, to handle conversation. -Instead of locking the extension to a particular conversation model, the separate Simple Conversations extension can is provided for optional use. -Regardless of how the author choose to approach conversation, great care and thought should go into the implementation. +Regardless of how the author choose to approach conversations, great care and thought should go into the implementation. Inform's included 'Recipe Book' covers the topic of conversation in quite detail, starting from chapter 7.6. +Most of the time we also need to keep track of which topics are available, depending on many factors such the knowledge of both the player and the characters. +This extension doesn't lock the author to a particular conversation model, instead providing the separate Simple Conversations extension as an option. +The aim of Simple Conversations is to provide a model that is simple to use for both player and author, while still retaining robustness and flexibility. +For further details see the documentation of the extension itself. + Section 5.4 - Discrete Arousal-based Consent and Stimulation *: @@ -5103,6 +5106,37 @@ Section 5.4 - Discrete Arousal-based Consent and Stimulation Test me with "kiss Beatrice / lick Beatrice / fuck Beatrice / z / kiss Beatrice / lick Beatrice / fuck Beatrice". [TODO: Add more actions do move up the arousal levels] +Section 5.5 - Optional Posture Integration + +Another method for adding immersion and detail to your story is to allow for various postures. +The bundled extension Postures provides some of the most common postures along with basic functionality for changing and checking for postures. + +In order for postures to be a positive addition to your story it's necessary to integrate them with the relevant actions and descriptions. +Body part descriptions can be tailored to hide or highlight details depending on posture, while the description generation rules can be used to highlight the current posture. + +*: + A status description generation rule for a person (called P) (this is the posture status rule): + If P is enclosed by a supporter (called location): + Say "[P] [are] [describe posturing of current posture of P] on [location]."; + Else if P is enclosed by a container (called location): + Say "[P] [are] [describe posturing of current posture of P] in [location]."; + Else: + Say "[P] [are] [describe posturing of current posture of P] nearby."; + +AS each story might have it's own very different requirements on how postures should affect the actions in this extension, no attempt is made to make rules that cover all eventualities. +Instead you can use the sample code below to tailor posture limitations to your own story. + + Before doing something to a body part (called part): + If part is enclosed by a person (called part-owner) and part-owner is enclosed by something (called owner-location): + Let blocked be false; + If part-owner is posturing prone or part: + If part is an abdomen or part is some breasts or part is a chest or part is a penis or part is a vagina, now blocked is true; + If part-owner is posturing supine or part-owner is posturing sitting: + If part is a backside or part is an ass, now blocked is true; + If blocked is true: + Say "[We] [cannot] do that to [part] when [owner-location] is in the way." + Stop the action; + Chapter 6 - Support Functions [TODO: Introduction to support functions] @@ -5744,8 +5778,8 @@ We can then use these traits to selectively create body parts: every man should As we don't implement all the templates, we can add some synonyms (through the 'understand' phrase) to cover their absence. A head is a part of every person. Understand "face", "mouth", "eye/eyes" and "hair" as head. - Some legs is a part of every person. Understand "feet" and "thighs" as pair of legs. - Some hands is a part of every person. Understand "arms" as pair of hands. + Some legs is a part of every person. Understand "feet" and "thighs" as legs. + Some hands is a part of every person. Understand "arms" as hands. An ass is a part of every person. A vagina is a part of every woman. @@ -5757,18 +5791,18 @@ These parts are now available for the player to examine, but for now they don't When we use the "part of every" construct the parts will be named after the person they are attached to, except the player's parts which are called yours. The description of your head is "As one would expect, your head has the usual fixtures: two eyes and ears, a mouth and tussled black hair." - The description of your pair of legs is "Good to have for walking." - The description of your pair of hands is "Strong and firm from lifting heavy crates." + The description of your legs is "Good to have for walking." + The description of your hands is "Strong and firm from lifting heavy crates." The description of your ass is "Nice and taut." The covered description of your penis is "You're packing some junk in your trousers." The uncovered description of your penis is "Isn't it nice?" The description of Carrie's head is "Carrie has long blonde hair, lucious red lips and deep blue eyes." - The description of Carrie's pair of legs is "Her legs are long and slim." - The description of Carrie's pair of hands is "As a machine operator, her delicate hands are unsullied by hard labor." + The description of Carrie's legs is "Her legs are long and slim." + The description of Carrie's hands is "As a machine operator, her delicate hands are unsullied by hard labor." The description of Carrie's ass is "Her backside is nice and firm." - The covered description of Carrie's pair of breasts is "Her breasts might be small, but they do fill out her clothes nicely." - The uncovered description of Carrie's pair of breasts is "Carrie's showing off her maginificent breasts." + The covered description of Carrie's breasts is "Her breasts might be small, but they do fill out her clothes nicely." + The uncovered description of Carrie's breasts is "Carrie's showing off her maginificent breasts." The covered description of Carrie's vagina is "You can only dream of what it looks like." The uncovered description of Carrie's vagina is "Her vagina is nice and smooth." @@ -5804,9 +5838,7 @@ We allow Carrie to take off clothes to iillustrate how this works in practice. Say "Carrie dutifully obeys."; Give consent; - Test me with "x bob / x cover-all / up / x Denise / x pantsuit / in / x Carrie / x dress / x bra / Carrie, take of dress / x Carrie" - - + Test me with "x bob / x cover-all / up / x Denise / x pantsuit / in / x Carrie / x dress / x bra / Carrie, take of dress / x Carrie". Example: ** DACS @@ -5814,9 +5846,88 @@ Defining rules for consent is a very important part of writing a successful AIF For authors that don't have the interest in writing their own rules, the Discrete Arousal-based Consent and Stimulation System can be used to provide consent based on the current stimulation of the related actors. This examples shows how this can be set up as well as tailored to fit specific needs. -Example: *** Intelligent Agency +Example: *** A-maze-ing Temple - Showcasing character agency and path-finding + +The agency rules are an easy but powerful tool to make characters act on their own. +For this example we'll show how a native guide can help the player navigate a not-too-difficult maze. +First we have to set the stage. + + *: "A-maze-ing Temple" + + Include Erotic Storytelling by Fictitious Frode. + Include Simple Conversations by Fictitious Frode. + Use unabbreviated object names. + + When play begins, say "After a long trek alongside your trusty native guide, you finally hack through the final vines to arrive at an opening in the dense jungle." + + Jungle Clearing is a room. "The dense jungle opens up in a circular clearing, centered around a [small mound]. You can make out an entrance in the mound leading inside and down." + A small mound is a door. It is inside from Jungle Clearing. + Instead of going down in Jungle Clearing, try going down. + + Harry is a man in Jungle Clearing. The player is Harry. + Your adventuring clothes is an outfit worn by Harry. + The description is "These is your trusty khaki adventuring outfit; tan trousers and long-sleeved shirt with heavy boots." + + A native guide is a woman in Jungle Clearing. + An skimpy attire is an outfit worn by native guide. The description is "Her clothing offers considerably less protection than yours, consisting of sandals, a short skirt and a loose-fitting blouse." + A flaming torch is carried by the native guide. It is lit. + +With the stage set we can focus on the guide's agency, which we'll make planned instead of urgent so the doesn't guide run away in the middle of an interaction. +In order to make it more adaptable we store the guide's target destination as a variable instead of hard-coding it. + + The native guide has a room called target location. + + Planned agency for native guide: + If native guide can see Harry: + Let the way be the best route from the location of native guide to the target location of native guide, using doors; + If the way is a direction: + If the player can see native guide, say "'Follow me mister Harry!'"; + Try the native guide going the way; + Else: + If target location of native guide is not the location of native guide: + Let the way be the best route from the location of native guide to Harry, using doors; + If the way is a direction: + Try the native guide going the way; + If the native guide can see the player, say "'There you are mister Harry! I thought I'd lost you."; + +We also need a small maze to be guided through, and to make things interesting we randomize the location of the treasure chamber. + Entrance Chamber is inside from small mound. "This small chamber lies just inside the [small mound]. A beam of light comes through the opening to the south, illuminating a corridor leading north." + Instead of going south in Entrance Chamber, try going outside. + Instead of going up in Entrance Chamber, try going outside. + + Dark Intersection is north of Entrance Chamber. It is dark. "The underground corridor from the entrance to the south splits into two branches going east and west." + + Treasure Chamber is a room. "Sadly this chamber doesn't live up to it's name. Broken caskets and chests lie scattered around the room." + Every turn, if Harry is in Treasure Chamber, end the story finally saying "It might not have contained the treasures you were looking for, but you did find a nice girl." + + Endless Pit is a room. "Just as you feel the corridor walls around you open up, the floor before you also give way to nothingness." + Every turn, if Harry is in Endless Pit, end the story saying "You stumble over the edge, hurtling down through the darkness before making a messy spot at the bottom." + + When play begins: + If a random chance of 1 in 2 succeeds: + Change east exit of Dark Intersection to Endless Pit; + Change west exit of Dark Intersection to Treasure Chamber; + Else: + Change west exit of Dark Intersection to Endless Pit; + Change east exit of Dark Intersection to Treasure Chamber; + +Even though the agency code is in place, our guide won't do anything before she's agency-enabled. +While it's possible to have this enabled from the start, it's often best to have it triggered by the player's actions. +For our purpose, asking the guide about treasure seems like a reasonable trigger. + + Some treasure is a subject. Understand "gold", "gems" and "secrets" as treasure. + The dialogue of the native guide is the Table of Guide's Dialogue. + + Table of Guide's Dialogue + subject (a thing) availability (a truth state) cue (a text) turn stamp (a number) dialogue (some text) + treasure true "treasure" -- "'Yes mister Harry, I know where the treasure is hidden. Follow me and try to keep up!'" + + After talking to native guide about treasure for the first time: + Now the target location of native guide is Treasure Chamber; + Now the native guide is agency-enabled; + Test me with "talk to guide about treasure / z / enter mound / n". Example: *** A Furry Tale - How to create custom body parts. diff --git a/Posturing.i7x b/Posturing.i7x new file mode 100644 index 0000000..3779ab6 --- /dev/null +++ b/Posturing.i7x @@ -0,0 +1,728 @@ +Version 2/170401 of Posturing by Fictitious Frode begins here. + +Volume 0 - New Verbs + +[These are the new verbs the extension uses; We put this in it's own volume in case anyone needs to rewrite it for compatibility:] + +To stand is a verb. +To sit is a verb. +To kneel is a verb. +To bend is a verb. +To lie is a verb. +To drop is a verb. +To turn is a verb. + +Volume 1 - Posturing + +Book 1.1 - Concepts + +Part 1.1.1 - Postures + +Chapter 1.1.1a - Kind of Value + +A posture is a kind of value. The postures are defined by the Table of Postures. +The specification of posture is "A posture is the position or bearing of a person. It can as an example be used to distinguish between sitting, standing or lying down." + +Table of Postures +Posture describe posture (text) assume posture (text) +standing "standing" "[stand] up" +sitting "sitting" "[sit] down" +kneeling "kneeling" "[kneel]" +bending "bending" "[bend]" +prone "laying prone" "[lie] prone" +supine "supine" "[lie] supine" + +To say describe posture of (P - a posture): + Repeat with N running from 1 to the number of rows in the Table of Postures: + Choose row N in the Table of Postures; + If P is the Posture entry, say the describe posture entry; + +To say assume posture of (P - a posture): + Repeat with N running from 1 to the number of rows in the Table of Postures: + Choose row N in the Table of Postures; + If P is the Posture entry, say the assume posture entry; + +Chapter 1.1.1b - Property Integrations + +A person has a posture called the current posture. +A supporter has a list of postures called compatible postures. The compatible postures of a supporter is usually {standing}. +A container has a list of postures called compatible postures. The compatible postures of a container is usually {standing}. +A supporter has a number called the occupant limit. The occupant limit of a supporter is usually 1. +A container has a number called the occupant limit. The occupant limit of a container is usually 1. + +Chapter 1.1.1c - Checking for Posture + +[Checks if a given individual is in a given posture] +To decide whether (individual - a person) is posing (position - a posture): + If the current posture of the individual is the position, decide yes; + Else decide No; + +[Checks if a given individual is in a given posture for a given location] +To decide whether (individual - a person) is posing (position - a posture) on (location - an object): + If the current posture of the individual is the position and the individual is enclosed by the location, decide yes; + Else decide no; + +[Checks if *any* person is in a given posture for a given location] +To decide whether someone is posing (position - a posture) on (location - an object): + If the location is enterable: + Repeat with individual running through the list of persons enclosed by the location: + If the current posture of the individual is the position, decide yes; + Decide no; + +[Determines if a location allows a posture] +To decide whether (location - an object) allows (position - a posture) posture: + If location provides the property compatible postures: + If position is listed in the compatible postures of location, decide yes; + Decide no; + +[Negation:] +To decide whether (location - an object) blocks (position - a posture) posture: + If location provides the property compatible postures: + If position is listed in the compatible postures of location, decide no; + Decide yes; + +[Determines if a location is filled to it's occupant limit] +To decide whether (location - an object) has vacancy: + If location provides the property occupant limit: + If the number of people enclosed by location is not less than the occupant limit of location, decide no; + Decide yes; + +Book 1.2 - New Actions + +[As most of the logic for assuming a posture is shared between the postures, we use the posturing action to apply the logic and actions for each posture to redirect.] + +Part 1.2.1 - Posturing + +[Status: Complete +This actions is responsible for changing the posture of an actor. This includes checking that it's actually a change, and that the location of the actor can support the posture.] + +Posturing is an action applying to one posture. +The specification of the posturing action is "Posturing is the action that alters the posture of an actor. It ensures that the location of the actor can support the new posture, and that the new posture is a change from the current. There are several other actions that redirect to this one." + +Chapter 1.2.1a - Check + +Check an actor posturing (this is the changing posture rule): + Let P be the posture understood; + If the current posture of the actor is P: + If the actor is the player: + Say "[We] [are] already [describe posture of P]." (A); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [are] already [describe posture of P]." (B); + Stop the action; + +Check an actor posturing (this is the verify posture rule): + Let P be the posture understood; + If the holder of the actor is not a room: + If the holder of the actor allows P posture, continue the action; + If the holder of the actor is a container: + If the actor is the player: + Say "[We] [can't] [assume posture of P] in [the holder of the actor]." (A); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [can't] [assume posture of P] in [the holder of the actor]." (B); + Else: + If the actor is the player: + Say "[We] [can't] [assume posture of P] on [the holder of the actor]." (C); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [can't] [assume posture of P] on [the holder of the actor]." (D); + Stop the action; + +Chapter 1.2.1b - Carry Out + +Carry out an actor posturing (this is the assume posture rule): + Now the current posture of the actor is the posture understood; + +Chapter 1.2.1c - Report + +Report an actor posturing (this is the report posturing rule): + Let P be the current posture of the actor; + If the holder of the actor is a room: + If the actor is the player: + Say "[We] [assume posture of P]." (A); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [assume posture of P]." (B); + Else if the holder of the actor is a container: + If the actor is the player: + Say "[We] [assume posture of P] in [the holder of the actor]." (C); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [assume posture of P] in [the holder of the actor]." (D); + Else: + If the actor is the player: + Say "[We] [assume posture of P] on [the holder of the actor]." (E); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [assume posture of P] on [the holder of the actor]." (F); + +Part 1.2.2 - Stand In/On + +[Status: Complete +We need two actions: one for changing to the posture and one for assuming the posture on/in something. +Standing can also serve as a redirect to exiting/getting off.] + +Standing is an action applying to nothing. +Standing on is an action applying to one thing. + +Chapter 1.2.2a - Understanding + +Understand the command "stand" as something new. +Understand "stand" as standing. +Understand "stand on [a supporter]" as standing on. +Understand "stand in [a container]" as standing on. +Understand "stand on/in/-- [something]" as standing on. + +Chapter 1.2.2b - Carry Out + +[Redirect to assuming the standing posture] +Carry out an actor standing (this is the implicit standing redirect rule): + If the holder of the actor is a supporter (called location) and location blocks standing posture: + Say "(getting off [the location])[command clarification break]"; + Try the actor getting off location instead; + If the holder of the actor is a container (called location) and location blocks standing posture: + Say "(exiting [the location])[command clarification break]"; + Try the actor exiting instead; + Try the actor posturing standing; + +[Try to enter the noun, then redirect to assume the standing posture] +Carry out an actor standing on (this is the explicit standing redirect rule): + If the holder of the actor is not the noun, silently try the actor entering the noun; + If the holder of the actor is the noun: + Unless the current posture of the actor is standing, try the actor posturing standing; + Else follow the report posturing rules; + +Part 1.2.3 - Sit In/On/At + +[Status: Complete +We need two actions: one for changing to the posture and one for assuming the posture on/in something.] + +Sitting is an action applying to nothing. +Sitting on is an action applying to one thing. + +Chapter 1.2.3a - Understanding + +Understand the command "sit" as something new. +Understand "sit" as sitting. +Understand "sit on [a supporter]" as sitting on. +Understand "sit in [a container]" as sitting on. +Understand "sit on/in/at/-- [something]" as sitting on. + +Chapter 1.2.3b - Carry Out + +[Redirect to assuming the sitting posture] +Carry out an actor sitting (this is the implicit sitting redirect rule): + Try the actor posturing sitting; + +[Try to enter the noun, then redirect to assume the sitting posture] +Carry out an actor sitting on (this is the explicit sitting redirect rule): + If the holder of the actor is not the noun, silently try the actor entering the noun; + If the holder of the actor is the noun: + Unless the current posture of the actor is sitting, try the actor posturing sitting; + Else follow the report posturing rules; + +Part 1.2.4 - Kneel Over/On/In + +[Status: Complete +We need two actions: one for changing to the posture and one for assuming the posture on/in something.] + +Kneeling is an action applying to nothing. +Kneeling on is an action applying to one thing. + +Chapter 1.2.4a - Understanding + +Understand "kneel" as kneeling. +Understand "kneel on/over [a supporter]" as kneeling on. +Understand "kneel in [a container]" as kneeling on. +Understand "kneel on/in/over/-- [something]" as kneeling on. + +Chapter 1.2.4b - Carry Out + +[Redirect to assuming the kneeling posture] +Carry out an actor kneeling (this is the implicit kneeling redirect rule): + Try the actor posturing kneeling; + +[Try to enter the noun, then redirect to assume the kneeling posture] +Carry out an actor kneeling on (this is the explicit kneeling redirect rule): + If the holder of the actor is not the noun, silently try the actor entering the noun; + If the holder of the actor is the noun: + Unless the current posture of the actor is kneeling, try the actor posturing kneeling; + Else follow the report posturing rules; + +Part 1.2.5 - Bend Over/On/In + +[Status: Complete +We need two actions: one for changing to the posture and one for assuming the posture on/in something.] + +Bending is an action applying to nothing. +Bending on is an action applying to one thing. + +Chapter 1.2.5a - Understanding + +Understand "bend" as bending. +Understand "bend on/over [a supporter]" as bending on. +Understand "bend in [a container]" as bending on. +Understand "bend on/in/over/-- [something]" as bending on. + +Chapter 1.2.5b - Carry Out + +[Redirect to assuming the bending posture] +Carry out an actor bending (this is the implicit bending redirect rule): + Try the actor posturing bending; + +[Try to enter the noun, then redirect to assume the bending posture] +Carry out an actor bending on (this is the explicit bending redirect rule): + If the holder of the actor is not the noun, silently try the actor entering the noun; + If the holder of the actor is the noun: + Unless the current posture of the actor is bending, try the actor posturing bending; + Else follow the report posturing rules; + +Part 1.2.6 - Lie Down On/In (Supine) + +[Status: Complete +We need two actions: one for changing to the posture and one for assuming the posture on/in something.] + +Lying down is an action applying to nothing. +Lying down on is an action applying to one thing. + +Chapter 1.2.6a - Understanding + +Understand the command "lie" as something new. +Understand "lie down/--" as lying down. +Understand "lay down/--" as lying down. +Understand "lie down/-- on [a supporter]" as lying down on. +Understand "lay down/-- on [a supporter]" as lying down on. +Understand "lie down/-- in [a container]" as lying down on. +Understand "lay down/-- in [a container]" as lying down on. +Understand "lie down/-- on/in/-- [something]" as lying down on. +Understand "lay down/-- on/in/-- [something]" as lying down on. + +Chapter 1.2.6b - Carry Out + +[Redirect to assuming the supine posture] +Carry out an actor lying down (this is the implicit lying down redirect rule): + Try the actor posturing supine; + +[Try to enter the noun, then redirect to assume the supine posture] +Carry out an actor lying down on (this is the explicit lying down redirect rule): + If the holder of the actor is not the noun, silently try the actor entering the noun; + If the holder of the actor is the noun: + Unless the current posture of the actor is supine, try the actor posturing supine; + Else follow the report posturing rules; + +Part 1.2.7 - Drop Down On/In (Prone) + +[Status: Complete +We need two actions: one for changing to the posture and one for assuming the posture on/in something.] + +Dropping down is an action applying to nothing. +Dropping down on is an action applying to one thing. + +Chapter 1.2.7a - Understanding + +Understand "drop down" as dropping down. +Understand "drop down on [a supporter]" as dropping down on. +Understand "drop down in [a container]" as dropping down on. +Understand "drop down on/in/-- [something]" as dropping down on. + +Chapter 1.2.7b - Carry Out + +[Redirect to assuming the prone posture] +Carry out an actor dropping down (this is the implicit dropping down redirect rule): + Try the actor posturing prone; + +[Try to enter the noun, then redirect to assume the prone posture] +Carry out an actor dropping down on (this is the explicit dropping down redirect rule): + If the holder of the actor is not the noun, silently try the actor entering the noun; + If the holder of the actor is the noun: + Unless the current posture of the actor is prone, try the actor posturing prone; + Else follow the report posturing rules; + +Part 1.2.8 - Turn Around + +[Status: Complete +Turning around tries to change between the two lying down postures.] + +Turning around is an action applying to nothing. + +Chapter 1.2.8a - Understanding + +Understand "turn around/--" as turning around. + +Chapter 1.2.8b - Check + +[Ensure that the actor is actually lying down] +Check an actor turning around (this is the must lie down to turn around rule): + Unless the current posture of the actor is supine or the current posture of the actor is prone: + If the actor is the player: + Say "[We] [have] to be lying down to turn around." (A); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [have] to be lying down to turn around." (B); + Stop the action; + +Chapter 1.2.8c - Carry Out + +[Redirect to assuming the prone or supine posture] +Carry out an actor turning around (this is the turning around redirect rule): + If the current posture of the actor is supine, silently try the actor posturing prone; + Else silently try the actor posturing supine; + +Chapter 1.2.8c - Report + +Report an actor turning around (this is the report turning around rule): + Let P be the current posture of the actor; + If the holder of the actor is a room: + If the actor is the player: + Say "[We] [turn] around and are now [assume posture of P]." (A); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [turn] around and are now [assume posture of P]." (B); + Else if the holder of the actor is a container: + If the actor is the player: + Say "[We] [turn] around and are now [assume posture of P] in [the holder of the actor]." (C); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [turn] around and are now [assume posture of P] in [the holder of the actor]." (D); + Else: + If the actor is the player: + Say "[We] [turn] around and are now [assume posture of P] on [the holder of the actor]." (E); + Else if the player can see the actor and the action is not silent: + Say "[The actor] [turn] around and are now [assume posture of P] on [the holder of the actor]." (F); + +Book 1.3 - Action Integration + +Part 1.3.1 - Default Postures + +[Status: Complete +After entering/exiting something, make the actor conform to the default posture of the new location if needed.] + +Carry out an actor exiting (this is the default posture rule): + Let location be the holder of the actor; + Let P be standing; + If location provides the property compatible postures: + If the compatible postures of location is not empty, let P be entry 1 of the compatible postures of the location; + Now the current posture of the actor is P; + +The default posture rule is listed after the standard exiting rule in the carry out exiting rulebook. +The default posture rule is listed after the standard getting off rule in the carry out getting off rulebook. +The default posture rule is listed after the standard entering rule in the carry out entering rulebook. + +Part 1.3.2 - Occupancy Check + +[Status: Complete +Before entering/exiting something, make sure there is room for the actor.] + +Check an actor entering (this is the entering occupancy control rule): + Unless the noun has vacancy: + If the actor is the player: + Say "There [are] no room for [us] on [the noun]." (A); + Else if the player can see the actor and the action is not silent: + Say "There [regarding the actor][are] no room for [the actor] on [the noun]." (B); + Stop the action; + +Check an actor exiting (this is the exiting occupancy control rule): + Let the former exterior be the not-counting-parts holder of the container exited from; + Unless the former exterior has vacancy: + If the actor is the player: + Say "There [are] no room for [us] on [the noun]." (A); + Else if the player can see the actor and the action is not silent: + Say "There [regarding the actor][are] no room for [the actor] on [the noun]." (B); + Stop the action; + +Check an actor getting off (this is the getting off occupancy control rule): + Let the former exterior be the not-counting-parts holder of the noun; + Unless the former exterior has vacancy: + If the actor is the player: + Say "There [are] no room for [us] on [the noun]." (A); + Else if the player can see the actor and the action is not silent: + Say "There [regarding the actor][are] no room for [the actor] on [the noun]." (B); + Stop the action; + +Part 1.3.3 - Travelling Posture + +[Status: Complete +Before going somewhere, make sure the actor is standing. +TODO: This could be expanded to allow movement in other postures.] + +The control traveling posture rule is listed after the stand up before going rule in the check going rulebook. +Check an actor going somewhere (this is the control traveling posture rule): + Unless the current posture of the actor is standing: + If the actor is the player: + Say "(first standing up)[command clarification break]" (A); + Else if the player can see the actor and the action is not silent: + Say "([the actor] first standing up)[command clarification break]" (B); + Silently try the actor posturing standing; + If the current posture of the actor is not standing, stop the action. + +Part 1.3.4 - Describing Postures + +[TODO +Rule for writing a paragraph about someone (called target): + say "[The target] is [describe posture of current posture of target] here." + + Rule for writing a paragraph about someone (called target) on a supporter (called location): + Say "[The target] is [describe posture of current posture of target] on [the location]." + +Rule for writing a paragraph about someone (called target) in a container (called location): + say "[The target] is [describe posture of current posture of target] in [the location]." + + +Rule for writing a paragraph about someone (called target): + say "[The target] is [posture] [if the holder of the target is the location]nearby[otherwise][in-on the holder of the target][end if]." + +Rule for writing a paragraph about something which encloses an unmentioned person (called target): + carry out the writing a paragraph about activity with the target instead. +] + +Book 1.4 - Templates + +Part 1.4.1 - Furniture Catalog + +Chapter 1.4.1a - Chair + +A chair is a kind of supporter. A chair is usually enterable. +The occupant limit of a chair is usually 1. The compatible postures of a chair is usually {sitting, bending}. +The specification of a chair is "Chairs are made for sitting on, but also support bending (over). It usually has room for one person." + +Chapter 1.4.1b - Table + +A table is a kind of supporter. A table is usually enterable. +The occupant limit of a table is usually 2. The compatible postures of a table is usually {supine, prone, sitting, bending}. +The specification of a table is "Tables are made for laying (supine) on, but also support laying prone, sitting on and bending over. It usually has room for two persons." + +Chapter 1.4.1c - Desk + +A desk is a kind of supporter. A desk is usually enterable. +The occupant limit of a desk is usually 1. The compatible postures of a desk is usually {sitting, bending, supine, prone}. +The specification of a desk is "Desks are made for sitting on/at, but also support laying prone/supine and bending over. It usually has room for one person." + +Chapter 1.4.1d - Sofa + +A sofa is a kind of supporter. A sofa is usually enterable. +The occupant limit of a sofa is usually 3. The compatible postures of a sofa is usually {sitting, bending, supine, prone}. +The specification of a sofa is "Sofas are made for sittin on, but also support laying prone/supine and bending over. It usually has room for three persons." +Understand "couch" as sofa. + +Chapter 1.4.1e - Bed + +A bed is a kind of supporter. A bed is usually enterable. +The occupant limit of a bed is usually 3. The compatible postures of a bed is usually {supine, prone, sitting, kneeling}. +The specification of a bed is "Beds are made for laying (supine) on, but also support laying prone, sitting and kneeling on. It usually has room for three persons." + +Chapter 1.4.1f - Cabinet + +A cabinet is a kind of container. A cabinet is usually enterable. A cabinet is usually openable. +The occupant limit of a cabinet is usually 2. The compatible postures of a cabinet is usually {standing, sitting, kneeling}. +The specification of a cabinet is "Cabinets are usually large enough for two people to stand in, but also support sitting and kneeling." + +Posturing ends here. + +---- DOCUMENTATION ---- + +Chapter 1 - Using this Extension + +To use this extension, you need to download and install it (which you probably have if you're reading this) and include it in your story: + +*: + Include Posturing by Fictitious Frode. + +By including this extension you will allow the player (and other actors) to assume postures. +The included postures are 'standing' (default), 'sitting', 'bending', 'kneeling, 'prone' (laying face-down) and 'supine' (laying face-up). +Also included are the relevant actions to change into these postures, as well as 'turning around' to change between the two laying down postures. +It's also possible for actors to posture on and in certain things. +While the first version of this extension used a special kind of supporter to represent this furniture, this version allows posturing on anything that is enterable and has the 'compatible postures' property. + +Section 1.1 - Documentation Overview + +The documentation will cover the following subjects: + + Chapter 1: A short overview of the extension. + Chapter 2: Techniques and guidelines on how to use postures. + Chapter 3: A technical reference for everything added or changed with this extension. + +The following examples are included: + + A: Garden Lounge - + B: Customization: Crawling - How to create new postures + +Section 1.2 - Version History + +2015-01-26: AIF Framework Extension (Release 1) + + Inflexible posture model based on furniture + +2017-04-01: Beta-2 (Release 2) + + Complete re-coding, keeping the same postures but using centralized control with posture-specific redirects. + Moved from kind-based furniture to property-based checks for greater flexibility. + +Section 1.3 - Contact Info + +The author of this extension can be reached in the following ways: + + Mail: fictitious.frode@gmail.com + Blog: https://informedaif.wordpress.com/ is a blog dedicated to writing AIF with Inform 7, and is the official host of the extension. It contains both dicussions around AIF and tutorials on both Inform in general and this extension in particular. + Reddit: https://www.reddit.com/r/AIFCentral/ is the subreddit for the AIF community, and the author checks this regularly. + GitHub: https://github.com/FictitiousFrode/AIF Contains the latest version of the extension, possibly including functionality that hasn't been released yet. + +Feedback of all varieties is welcome, but constructive criticism and discussion is the most appreciated, along with reports of bugs and other issues. +For support I would appreciate using public communication, so that other may learn from the request as well. + +Section 1.4 - Acknowledgments + +This extension probably wouldn't have been remade if it wasn't for Mister Flibble's Photoshoot which showed the power of properly implemented postures. +The deck chair from the examples is based on his creation. + +Example 394 - Slouching provided much of the inspiration for this implementation. +The relation-based approch is replaced with lists, and everything is implemented in a more robust and customizable fashion. + +Chapter 2 - Posturing + +Postures provide an option for further depth in how actors are placed in the world model. +This brings both new opportunity for immersion, but also requires the author to consider more options. +This chapter will cover how postures can be used in a story, and how to create your own custom postures and furniture. + +Section 2.1 - Postures and Actions + +The extension comes with the most common postures defined, including actions for changing to these postures. +Changes to a persons posture is generally performed by the posturing action, except for some cases related to entering and exiting locations. +The following is a list of the postures made available by this extension, and the commands the player can use to reach them: + + Standing: stand (on/in something) + Sitting: sit (on/in/at something) + Kneeling: kneel (on/in/over something) + Bending: bend (on/in/over something) + Supine: lie/lay (down) (on/in something), or turn (around) when already prone. + Prone: drop down (on/in something), or turn (around) when already supine. + +Postures aren't limited to just being in a room however. +Through Inform's standard rules supporters and containers can be entered, and now also has a property stating which postures are supported on them. +By using the compatible postures (a list of postures), any enterable object in Inform's world model can now control which postures they allow. +The first entry in the list is assumed to be the preferred posture, which is taken when a person enters without a valid posture. +In order to control how many people there is room for, the property occupant limit is also available. +For convenience, the following ready-to-use furniture templates are provided: + + Chair (supporter): sitting and bending for 1 person + Table (supporter): supine, prone, sitting and bending for 2 persons + Desk (supporter): sitting, bending, supine and prone for 1 person + Sofa (supporter): sitting, bending, supine and prone for 3 persons + Bed (supporter): supine, prone, sitting and kneeling for 3 persons + Cabinet (openable container): standing, sitting and kneeling for 2 persons + +Section 2.2 - Integrating Postures + +For postures to have full effect it's important they are integrated with the other actions that are relevant for the story. +This can be as simple as descriptions taking the posture into account, or more comprehensive where certain postures prevent actions from taking place. +An example of the latter is something that is out of reach unless the player is standing on something. + +While most of this integration is left up to the author to decide on, some of the standard actions are integrated: + + Entering: The entering occupancy control rule ensures that the occupancy limit is observed, and the default posture rule makes an actor conform to the default posture of what is entered. + Exiting: The exiting occupancy control rule ensures that the occupancy limit is observed, and the default posture rule makes an actor conform to the default posture of what is exited. + Getting off: The getting off occupancy control rule ensures that the occupancy limit is observed, and the default posture rule makes an actor conform to the default posture of what is exited. + Going: The control traveling posture rule ensures that an actor can only go somewhere while standing. + +Section 2.3 - Customization + +Creating custom furniture to pose on is very simple, especially when it's to function like a supporter or container. +Example A shows how to create a deck chair as a custom furniture, which is as easy setting the compatible postures and occupant limit properties to what is desired. +In order to create new furniture that is not a supporter or container, your new piece will have to provide the compatible postures or occupant limit properties depending on what functionality you want to enable. + +Adding support for new postures can be achieved in a similar fashion. +The postures are defined by the Table of Postures, which features the columns posture, describe posture (text) and assume posture (text). +Adding a new posture is as easy as extending this table with a new row, giving a name to the posture as well as some text describing how the postures looks and is assumed. +In order for players to make use of the new posture we also need some actions that redirect to the posturing action, and you might have to alter some furniture to accomodate the new posture. +Example B shows how to create a crawling posture. + +Chapter 3 - Technical Reference + +Contained in this chapter is a technical description of all the new and altered mechanics for the extension, divided by type. +It's intended as a companion to the other chapters, although an experienced author could glean much of the previous information from this chapter alone. + +Section 3.1 - New Kind of Value: Posture + +The postures are defined in the Table of Postures, which is reproduced below. +The text values describe posture and assume posture are used to describe the value of the posture, the first for when a person is in the posture and the other for when a person assumes the posture. +Postures are used for people, as the current posture, and for containers and supporters as a list called compatible postures. +For changing the posture of a person in a controlled manner, the posturing action should be used. + + Table of Postures + Posture describe posture (text) assume posture (text) + standing "standing" "[stand] up" + sitting "sitting" "[sit] down" + kneeling "kneeling" "[kneel]" + bending "bending" "[bend]" + prone "laying prone" "[lie] prone" + supine "supine" "[lie] supine" + +Section 3.2 - Phrases + +The following phrases can be used to describe a posture in a text substitution: + + say DESCRIBE POSTURE OF (posture): Uses the describe posture entry in the Table of Postures to describe someone in the posture. + say ASSUME POSTURE OF (posture): Uses the assume posture entry in the Table of Postures to describe someone assuming the posture. + +The following phrases can be used to check for postures: + + whether (person) IS POSING (posture): Checks if the current posture of the person is the specified posture. + whether (person) IS POSING (posture) ON (object): Checks if the current posture of the person is the specified posture and that the person is enclosed by the given object. + whether SOMEONE IS POSING (posture) ON (object): Checks each person enclosed by the object to see if any of them are in the given posture. + whether (object) ALLOWS (posture) POSTURE: Checks if the compatible postures of the given object contains the specified posture. If the compatible postures property isn't available, it's assumed to be allowed. + whether (object) BLOCKS (posture) POSTURE: Checks if the compatible postures of the given object does not contain the specified posture. If the compatible postures property isn't available, it's assumed to not be blocked. + whether (object) HAS VACANCY: Checks if the number of people enclosed by the object is less than the occupant limit. If the object doesn't provide the occupant limit, it's assumed to have vacancy. + +Example: * Garden Lounge - Relaxing in various postures + +Getting started with postures is as easy as using the furniture templates. + + *: "Garden Lounge" + + Include Posturing by Fictitious Frode. + Garden Patio is a room. + + A hammock is a bed in Garden Patio. + A stone bench is a sofa in Garden Patio. + +We can also easily create new furniture according to our own needs. + + A deck chair is an enterable supporter in Garden Patio. The compatible postures are {supine, prone, sitting}. + +These will work for both the player and other actors. + + Clarice is a woman in Garden Patio. + A persuasion rule: persuasion succeeds. + + Test me with "sit on bench / clarice, sit on bench / stand / lie on chair / clarice, enter chair / look" + +Example: ** Crawling - Creating new postures + +Adding a new posture is rather simple, but we must also remember to add new actions for the actors to use. + + *: "Crawling" + + Include Posturing by Fictitious Frode. + +First we expand the Table of Postures to create the crawling posture. + + To crawl is a verb. + + Table of Postures (continued) + Posture describe posture (text) assume posture (text) + crawling "crawling" "[crawl] on all four" + +We can then create two new actions, one to crawl and one to crawl on and in something. + + Crawling is an action applying to nothing. + Understand "crawl" as crawling. + Carry out an actor crawling: try the actor posturing crawling. + + Crawling on is an action applying to one thing. + Understand "crawl on/over [a supporter]" as crawling on. + Understand "crawl in [a container]" as crawling on. + Understand "crawl on/in/over/-- [something]" as crawling on. + + Carry out an actor crawling on: + If the holder of the actor is not the noun, silently try the actor entering the noun; + If the holder of the actor is the noun: + Unless the current posture of the actor is crawling, try the actor posturing crawling; + Else follow the report posturing rules; + +We can now create containers and supporters that work with crawling. + + Garage is a room. + A cardboard box is an enterable container in Garage. The compatible postures is {crawling}. + + Test me with "enter box / stand / crawl in box" diff --git a/README.md b/README.md index 7ecd39f..9b02351 100644 --- a/README.md +++ b/README.md @@ -5,11 +5,14 @@ See https://informedaif.wordpress.com/framework/ for more information. **Erotic Storytelling.i7x**: Main extension, containing layered clothing model, erotic actions and support functions, with templates for easy implementation. -**Template.ni**: -Sample project layout for an Inform 7 story. - +**Posturing.i7x**: +Support extension, providing postures for actors. + **Simple Conversations.i7x**: - Support extension, containing a conversation model. - +Support extension, containing a conversation model. + **Directionality.i7x**: Helper extension for listing out visible exits from a room. + +**Template.ni**: +Sample project layout for an Inform 7 story. diff --git a/Readme.txt b/Readme.txt index 095b1d9..d25208b 100644 --- a/Readme.txt +++ b/Readme.txt @@ -29,6 +29,7 @@ The extensions in the framework provides: * A framework to provide consent for actions affecting other actors, similar to how persuasion rules work. * Optional framework for arousal based consent, similar to TADS libraries. + * Optional support posturing by actors. * A model of simple conversations. Installation @@ -44,6 +45,7 @@ you want for your story. A full inclusion would look like this: Include Erotic Storytelling by Fictitious Frode. Include Simple Conversations by Fictitious Frode. + Include Posturing by Fictitious Frode. Include Directionality by Fictitious Frode. All of the extensions have proper documentation, available from the Extensions @@ -72,12 +74,17 @@ Each individual extension has a more detailed log of changes. * The previous framework has been completely reworked and rewritten, and the release history has been updated to only include the remake. + 2017-04-01: Beta-2 + ------------- + * Posturing has been updated and remade. + * Bug-fixes and minor updated to other extensions, see documentation in + each extension for details. + Future Plans ============== These are some ideas for future development: * Ropework - * Posturing * Lasting Penetrations * Numerical Arousal (NACS) diff --git a/Simple Conversations.i7x b/Simple Conversations.i7x index 4e89f1a..a6c74d6 100644 --- a/Simple Conversations.i7x +++ b/Simple Conversations.i7x @@ -1,4 +1,4 @@ -Version 1/161223 of Simple Conversations by Fictitious Frode begins here. +Version 2/170401 of Simple Conversations by Fictitious Frode begins here. Include Epistemology by Eric Eve. @@ -49,6 +49,11 @@ To update the cue of (subject - a thing) for (conversationalist - a person) to ( Now cue entry is cue; Now dialogue entry is ""; +To clear the cue of (subject - a thing) for (conversationalist - a person): + Repeat through dialogue of the conversationalist: + If there is a subject entry and the subject entry is subject: + Blank out the cue entry; + Chapter 1.1.2c - Updating Dialogue To update the dialogue of (subject - a thing) for (conversationalist - a person) to (dialogue - some text): @@ -66,6 +71,11 @@ To update the dialogue of (subject - a thing) for (conversationalist - a person) Now subject entry is subject; Now dialogue entry is dialogue; +To clear the dialogue of (subject - a thing) for (conversationalist - a person): + Repeat through dialogue of the conversationalist: + If there is a subject entry and the subject entry is subject: + Blank out the dialogue entry; + Chapter 1.1.2d - Toggling Availability To activate (subject - a thing) for (conversationalist - a person): @@ -278,6 +288,10 @@ Section 1.2 - Version History Individual default dialogue responses for each person. Availability for both subjects and individual dialogues can be toggled. Support for runtime alterations to dialogues. + +2017-04-01: Beta-2 (Release 2) + + Support for clearing cue and dialogue entries. Section 1.3 - Contact Info @@ -315,7 +329,6 @@ A subject isn't very interesting without a dialogue response for it from the oth To facilitate this we use a table-based approach, which allows for both shared and individual dialogue options. Each person has a 'dialogue' property which points to a table, which should look like the example below: - *: Library is a room. Bob is a person in Library. Bob's dialogue is the Table of Bob's Dialogue. @@ -340,6 +353,10 @@ It's important that the table contains the following five columns: It's also possible to write 'after talking to person about subject' rules. Typically these would be to unlock the effects of talking about the subject, such as updating cues and making other dialogues available. +Each person also have their own default dialogue property, which will be used as the response to all subjects that are not listed in the dialogue table. +Only subjects that the player knows about (which is handled using Eric Eve's Epistemology extension) can be talked about in this manner. +Attempts to converse about an unknown thing will be caught by the pondering to it about action, which when the noun is a person will also use the default dialogue. + Section 2.3 - Changing Dialogues Dialogue is seldom static, and the author has a few options on how to alter conversations. @@ -355,6 +372,9 @@ For these occasions you can have a separate table of dialogue for each act, and Chapter 3 - Technical Reference +Contained in this chapter is a technical description of all the new and altered mechanics for the extension, divided by type. +It's intended as a companion to the other chapters, although an experienced author could glean much of the previous information from this chapter alone. + Section 3.1 - New Kind: Subject Subject is a new kind which is defined by Eric Eve's Epistemology extension, to represent intangible knowledge that the player might want to talk to other characters about. @@ -375,12 +395,14 @@ It's very important that the table contains the following five columns: Turn stamp: Used to keep track of which dialogue options have been talked about, storing the turn number it was previously talked about. Dialogue: The text to output when talking about the option. -Section 3.3 - Phrases for Updating Values and Deciding On +Section 3.3 - Phrases The following phrases can be used to update the dialogues of a person, by altering the table that the dialogue property points to. - UPDATE THE CUE OF (thing) FOR (person) TO (text): Sets the cue text of the thing in the person's table to the given text. If the thing isn't listed in the table, it tries to find a blank row to insert a new row with no dialogue and 'false' availability. + UPDATE THE CUE OF (thing) FOR (person) TO (text): Sets the cue text of the thing in the person's table to the given text. If the thing isn't listed in the table, it tries to find a blank row to insert a new row with no dialogue and 'false' availability. Often used after talking about something that no longer requires cueing. + CLEAR THE CUE OF (thing) FOR (person): Blanks out the cue of the thing in the person's table. UPDATE THE DIALOGUE OF (thing) FOR (person) TO (text): Sets the dialogue text of the thing in the person's table to the given text. If the thing isn't listed in the table, it tries to find a blank row to insert a new row with the dialogue and 'false' availability. + CLEAR THE DIALOGUE OF (thing) FOR (person) : Blanks out the dialogue of the thing in the person's table. Rarely needed but provided for completion. ACTIVATE (thing) FOR (person): Sets the availability of the thing in the person's table to true. DEACTIVATE (thing) FOR (person): Sets the availability of the thing in the person's table to false. diff --git a/Template.ni b/Template.ni index 53e084f..5593bfc 100644 --- a/Template.ni +++ b/Template.ni @@ -9,6 +9,7 @@ Use consensual persuasion. [Defer persuasion to consent for the actions that req Include Directionality by Fictitious Frode. Include Erotic Storytelling by Fictitious Frode. [Include Simple Conversations by Fictitious Frode.] +[Include Posturing by Fictitious Frode.] Book 0.1 - Titlepage @@ -22,16 +23,16 @@ The release number is 0. Part 0.1.2 - Contents -[Heterosexuality is a story content. -Bondage is a disabled story content.] +[Heterosexuality is a story content.] +[Bondage is a disabled story content.] Part 0.1.3 - Dramatis Personae -[Create the persons of the story here] +[Defining the actors taking part in the story.] -Part 0.1.4 - Conversation Subject +Part 0.1.4 - Conversation Subjects -[Define conversation subjects that are common for multiple actors here.] +[Defining the general conversation subjects relevant to the story.] Part 0.2 - Declarations @@ -54,8 +55,10 @@ A penis is a part of every man. Book 0.2.2 - Custom Properties -[A body part can be spermed. A body part is usually not spermed. -A person can be proper-named. A person is usually not proper-named.] +[Any story-wide custom properties should go here.] + +[A body part can be spermed. A body part is usually not spermed.] +[A person can be proper-named. A person is usually not proper-named.] Book 0.3 - A Helping Hand @@ -84,7 +87,7 @@ Volume 1 - Act I Book 1.1 - Geology -[The rooms for Act I goes here] +[The locations related to Act I, divided into parts for regions with chapters for each room.] Part 1.1.1 - Region @@ -92,7 +95,7 @@ Chapter 1.1.1a - Room Book 1.2 - Inhabitants -[Characters related to Act I, one part for each person.] +[The actors related to Act I, one part for each.] Part 1.2.1 - Person @@ -137,7 +140,11 @@ Book 1.4 - Chronology [Break the act into scenes] -Part 1.4.1 - Scene +Part 1.4.1 - Progression + +[The scenes dealing with the story progression] + +Chapter 1.4.1a - Prologue Prologue is a scene. Prologue begins when play begins.