Difference between revisions of "Object Functions"

From ADRIFT 5 Manual Wiki
Jump to: navigation, search
m (Links)
(Useage)
Line 58: Line 58:
 
*Parent ([[%object%.Parent function|Parent]]) - The location, character or object that is directly holding this object
 
*Parent ([[%object%.Parent function|Parent]]) - The location, character or object that is directly holding this object
 
*Part of what? ([[%object%.PartOfWhat function|PartOfWhat]]) - The object or character that this object is a part of
 
*Part of what? ([[%object%.PartOfWhat function|PartOfWhat]]) - The object or character that this object is a part of
 +
 +
== Useage ==
 +
These functions can be used with a specific object, or with any function or reference that returns an object key:
 +
*In a task containing an %object% reference, using the reference will apply the object function to the object that the player entered in the command.
 +
*A specific object can be selected by using its [[key]]. eg. "Object12.Name"
 +
*A location or character function can be used to obtain an object key, and the object function appended to it. eg "Character3.CharInsideWhat.Name" will print the name of the object inside which Character3 is currently located.
  
  
 
<TABLE ALIGN=CENTER BORDER=1 WIDTH="50%"><TD WIDTH="33%" ALIGN=CENTER>[[Character Functions|<<< Character Functions]]</TD><TD WIDTH="34%" ALIGN=CENTER>[[Object-oriented functions]]</TD><TD ALIGN=CENTER>[[Location Functions|Location Functions >>>]]</TD></TABLE>
 
<TABLE ALIGN=CENTER BORDER=1 WIDTH="50%"><TD WIDTH="33%" ALIGN=CENTER>[[Character Functions|<<< Character Functions]]</TD><TD WIDTH="34%" ALIGN=CENTER>[[Object-oriented functions]]</TD><TD ALIGN=CENTER>[[Location Functions|Location Functions >>>]]</TD></TABLE>
 
[[Category:Functions]]
 
[[Category:Functions]]

Revision as of 08:27, 20 November 2012

The object-oriented functions for objects can be listed by typing a dot (full-stop ".") immediately after either the object reference "%object%", or an object key, in a text box or expression.

This allows direct access to the property values of any object without having to use the %PropertyValue[]% function.

Scroll down to the wanted property and click on it to insert the property key into the function.

  • Note that properties that are not relevant to a particular object will be omitted from the list.
  • Properties that you create and add to objects will be added to this list.
  • If you type part of the name of the property then the list will be reduced to show only those that match.
  • Instead of clicking with the mouse you can type enough of the properties name to bring it to the top of the list and press enter or tab.

FunctionsObject.jpg

IconLocation.jpg Location properties

  • In location (InLocation) - Displays the KEY of the objects location. Entering another dot after this will access the properties of that location

IconCharacters.jpg Character properties

  • Held by who (HeldByWho) - Key of character that this object is being held by (Dynamic objects only)
  • Part of who (PartOfWho) - Key of character that this object is a part of (Face, hands, nose etc.)
  • Worn by who (WornByWho) - Key of character that this object is being worn by (Wearable objects only)

IconText.jpg Text properties

  • ...and description when read (ReadText) - Used for books and signs that we want to be readable
  • Description (Description) - The text box that describes the object
  • Location of the object (DynamicLocation) - The name of the current location of a dynamic object
  • Location of the object (StaticLocation) - The name of the location of a static object
  • Locked status (LockStatus) - Can the object be locked
  • Open status (OpenStatus) - Open, Closed or Locked
  • Object name (Name) - The name of the object
  • ObjectType (StaticOrDynamic) - Static or Dynamic
  • When the object is listed in location, display this (ListDescriptionDynamic) - Text to describe dynamic object in a location
  • When the object is listed in location, display this (ListDescription) - Text used to describe static object in a location description

IconInteger.jpg Integer properties

  • ...and the container can hold (Capacity) - How many tiny objects can fit in this object (Containers only)
  • ...and the surface can hold (SurfaceHold) - How many tiny objects can fit on top of this object (Supporters only)
  • Object size (Size) - How big is this object
  • Object weight (Weight) - How heavy is this object

IconGroup.jpg Group properties

  • At Location group (AtLocationGroup) - ????????????????
  • Children (Children) - List keys of objects and characters on top of this supporter object
    • %object%.Children.Count - Number of items on and in this object
    • %object%.Children.List - List items on and in this object
    • %object%.Children(Objects,In) - Keys of objects inside this object, add .Count for quantity, .List to list object names.
    • %object%.Children(Objects,On) - Keys of objects on top of this object, add .Count for quantity, .List to list object names.
    • %object%.Children(Characters,In) - Keys of Characters inside this object, add .Count for quantity, .List to list Character names.
    • %object%.Children(Characters,On) - Keys of Characters on this object, add .Count for quantity, .List to list Character names.
  • Contents (Contents) - Keys of objects and characters inside this container object
    • %object%.Contents.List - List of objects and characters inside this container object
    • %object%.Contents.Count - Number of items inside this object
    • %object%.Contents(Objects) - Keys of Objects inside this object
    • %object%.Contents(Objects).List - List of Objects inside this object
    • %object%.Contents(Objects).Count - Number of objects in this object
    • %object%.Contents(Characters) - Keys of Characters inside this object
    • %object%.Contents(Characters).List - List of Characters inside this object
    • %object%.Contents(Characters).Count - Number of Characters in this object

IconDynamicObject.jpg Object properties

  • Inside what? (InsideWhat) - The key of the container object that the object is inside of
  • Key for lock (LockKey) - The key of the object that is used as a key to unlock this object
  • On what? (OnWhat) - The object that this object is sitting on top of
  • Parent (Parent) - The location, character or object that is directly holding this object
  • Part of what? (PartOfWhat) - The object or character that this object is a part of

Useage

These functions can be used with a specific object, or with any function or reference that returns an object key:

  • In a task containing an %object% reference, using the reference will apply the object function to the object that the player entered in the command.
  • A specific object can be selected by using its key. eg. "Object12.Name"
  • A location or character function can be used to obtain an object key, and the object function appended to it. eg "Character3.CharInsideWhat.Name" will print the name of the object inside which Character3 is currently located.


<<< Character FunctionsObject-oriented functionsLocation Functions >>>