This repository was archived by the owner on Feb 7, 2020. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 3
3. Objects Section
crankycyclops edited this page Jan 7, 2013
·
29 revisions
The objects section of game.xml is where you define objects in the game. Examples might include a sword, a candle or a treasure chest.
| Defines a new object in the game. (Optional) |
The <object> tag uniquely defines an object in the game. The object tag must contain a name="" attribute that uniquely identifies the object.
Example:
<object name="candle"> ... </object>
The following tags for configuring objects are recognized:
|
Valid value: Any string (Optional)
This is how the object is described to the user the first time they see it or anytime they explicitly look at it. If you use this tag more than once, Trogdor will issue a warning and the most recently defined setting will overwrite previous ones. |
|
|
Valid value: Integer greater than or equal to 0 (Optional)
This setting defines the weight of an object. A weight of 0 means the object has no weight. Anything greater defines how much inventory capacity the object consumes. This value, combined with the weight setting in the Player section's inventory configuration, will determine whether or not the player can hold onto the object along with anything else he might be carrying. If you use this tag more than once, Trogdor will issue a warning and the most recently defined setting will overwrite previous ones. |
|
|
Valid value: Any string (Optional)
Objects are identified primarily by their name attribute. However, it may also be useful to be able to refer to an object by other names. For example, an object with the name "rock" might also be readily identifiable as a "stone." If two or more objects in the same place share the same synonym and the player attempts to interact with one of them using the common name, Trogdor will ask the player for clarification. You can define an unlimited number of synonyms, each one defined inside its own <synonym> tag.
|
|
| TODO! | |
| TODO! | |
| TODO! | |
| TODO! | |
| TODO! |
The following custom messages are recognized by Trogdor for objects:
| take | Read to the player whenever the object is taken. If not defined, the default is, "You take the object name." |
| drop | Read to the player whenever the object is dropped. If not defined, the default is, "You drop the object name." |
TODO!