--- deliantra/server/pod/objects.pod 2006/12/18 16:53:04 1.4 +++ deliantra/server/pod/objects.pod 2006/12/20 13:07:13 1.13 @@ -96,6 +96,10 @@ equal to 0 the absolute value of the speed field is added to speed_left on the end of the tick. +This means: the lower the speed field is (but still above MIN_ACTIVE_SPEED) +the more seldom the object is processed. And the higher the speed field is +the more often the object is processed. + =item no_drop (0|1) Sets the flag FLAG_NO_DROP. @@ -116,6 +120,36 @@ Sets the flag FLAG_AUTO_APPLY. See Flags section below. +=item no_steal (0|1) + +Sets the flag FLAG_NO_STEAL. +See Flags section below. + +=item reflecting (0|1) + +Sets the flag FLAG_REFLECTING. +See Flags section below. + +=item reflect_spell (0|1) + +Sets the flag FLAG_REFL_SPELL. +See Flags section below. + +=item no_skill_ident (0|1) + +Sets the flag FLAG_NO_SKILL_IDENT. +See Flags section below. + +=item activate_on_push (0|1) (default: 1) + +Sets the flag FLAG_ACTIVATE_ON_PUSH. +See Flags section below. + +=item activate_on_release (0|1) (default: 1) + +Sets the flag FLAG_ACTIVATE_ON_RELEASE. +See Flags section below. + =item editable (more than deprecated) This field had a special meaning for crossedit, which used parts @@ -165,6 +199,50 @@ This flag has currently only meaning for the TREASURE type, see below. +=item FLAG_ACTIVATE_ON_PUSH + +This flag has only meaning for objects that can be linked together +with the 'connected' field and controls wether the object should +be activated when the connection is 'pushed' or it is 'released'. + +This flag is by default on. + +=item FLAG_ACTIVATE_ON_RELEASE + +This flag has only meaning for objects that can be linked together +with the 'connected' field and controls wether the object should +be activated when the connection is 'pushed' or it is 'released'. + +This flag is by default on. + +=item FLAG_NO_STEAL + +When this flag is set this object can't be stolen. The flag will be +resetted once the object is placed on a map. + +When this flag is set on a monster it can defent attempts of stealing +(but in this context the flag is only used internally). + +=item FLAG_NO_SKILL_IDENT + +This flag is mostly used internal and prevents unidentified objects +(objects which don't have FLAG_IDENTIFIED set) being identified by +skills. + +This flag is used to mark objects to never being identified by a skill +once a player failed to identify an object. So that multiple tries +of identifying aren't more effective than one. + +=item FLAG_REFLECTING + +This flag is used by spell effects (eg. SP_BOLT), THROWN_OBJ and ARROW +to indicate whether this object reflects off walls. + +=item FLAG_REFL_SPELL + +This flag indicates whether something reflects spells, like spell reflecting +amuletts. + =back =head2 Description of type specific attributes @@ -303,8 +381,7 @@ =item on_use_yield -When this object is applied this object will be created. -This field is also used by FOOD and POISON. +When this object is applied an instance of will be created. =item subtypes @@ -334,6 +411,161 @@ =back +=head3 FOOD - type 6 - Eatable stuff + +This is for objects that are representing general eatables like +beef or bread. + +The main difference between FOOD, FLESH and DRINK is that they +give different messages. + +The specialty of FLESH is that it inherits the resistancies of the +monsters it was generated in and will let dragons raise their resistancies +with that. If the monster has the POISON attacktype the FLESH +will change into POISON. + +If a player runs low on food he will grab for FOOD, DRINK and POISON +and if he doesn't find any of that he will start eating FLESH. + +=over 4 + +=item title + +If the food has a title or is cursed it is considered 'special', which means that the +fields Str, Dex, Con, Int, Wis, Pow, resist_, hp and sp +are interpreted and have further effects on the player. + +The higher the food field is the longer the improvement of the player lasts +(except for hp and sp). + +=item food + +This is the amount of food points the player gets when he eats this. + +=item on_use_yield + +When this object is applied an instance of will be created. + +=back + +=head3 POISON - type 7 - Poisonous stuff + +This type is for objects that can poison the player when drinking. +When applied it will hit the attacked with AT_POISON and will create +a POISONING object in the one who was hit. + +=over 4 + +=item level + +This field affects the propability of poisoning. The higher the level difference +between the one who is hit and the poision the mose propable it is the attacked +one will be poisoned. + +=item slaying + +On poison this field has the usual meaning of 'slaying', when the +ones race matches the slaying field the damage done by the poison +is multiplied by 3. + +=item hp + +This is the amount of damage the player will receive from applying this. The +attacktype AT_POISON will be used to hit the player and the damage will +determine the strenght, duration and depletion of stats of the poisoning. The +created POISONING object which is being placed in the one who was attacked will +get the damage from this field (which is maybe adjusted by slaying or the +resistancies). + +=item food + +1/4 of will be drained from the players food. + +=item on_use_yield + +When this object is applied an instance of will be created. + +=back + +=head3 BOOK - type 8 - Readable books + +This type is basically for representing text books in the game. + +Reading a book also identifys it (if FLAG_NO_SKILL_IDENT is not set). + +=over 4 + +=item msg + +This is the contents of the book. When this field is unset +at treasure generation a random text will be inserted. + +=item skill + +The skill required to read this book. (The most resonable +skill would be literacy). + +=item exp + +The experience points the player get for reading this book. + +=item subtype + +This field determines the type of the readable. +Please see common/readable.C in the readable_message_types table. + +=back + +=head3 CLOCK - type 9 - Clocks + +This type of objects just display the time when being applied. + +=head3 LIGHTNING - type 12 - Lightnings (DEPRECATED, see SPELL_EFFECT subtype SP_BOLT) + +This is a spell effect of a moving bolt. It moves straigt forward +through the map until something blocks it. +If FLAG_REFLECTING is set it even reflects on walls. + +FLAG_IS_TURNABLE should be set on these objects. + +=over 4 + +=item move_type + +This field affects the move type with which the lightning moves through +the map and which map cells will reflect or block it. + +=item attacktype + +The attacktype with which it hits the objects on the map. + +=item dam + +The damage this bolt inflicts when it hits objects on the map. + +=item Dex + +This is the fork percentage, it is reduced by 10 per fork. +And the damage is halved on each fork. + +=item Con + +This value is a percentage of which the forking lightning +is deflected to the left. This value should be mostly used internally. + +=item duration + +The duration the bolt stays on a map cell. This field is decreased each time +the object is processed (see the meaning of speed and speed_left fields in +the object general description). + +=item range + +This is the range of the bolt, each space it advances this field is decreased. + +=back + + =head3 WEAPON - type 15 - Weapons This type is for general hack and slash weapons like swords, maces @@ -480,10 +712,163 @@ FLAG_SEE_IN_DARK FLAG_UNDEAD +=head3 GRIMREAPER - type 28 - Grimreapers + +These type are mostly used for monsters, they give the +monster the ability to dissapear after 10 hits with AT_DRAIN. + +=over 4 + +=item value + +This field stores the hits the monster did yet. + +=back + +=head3 DRINK - type 54 - Drinkable stuff + +See FOOD description. + +=head3 CHECK_INV - type 64 - Inventory checkers + +This object checks whether the player has a specific item in his +inventory when he moves above the inventory checker. If the player has +the item (or not, which can be controlled with a flag) a connection will be triggered. + +If you set move_block you can deny players and monsters to reach the space where +the inventory checker is on, see 'move_block' description below. + +The conditions specified by hp, slaying and race are concationated with OR. +So matching one of those conditions is enough. + +=over 4 + +=item move_block + +If you set this field to block a movetype the move code will block any moves +onto the space with the inventory checker, IF the moving object doesn't have +(or has - if last_sp = 0) the item that the checker is searching for. + +=item last_sp (0|1) + +If last_sp is 1 'having' the item that is being checked for will +activate the connection or make the space with the checker non-blocking. +If last_sp is 0 'not having' the item will activate the connection +or make the space with the checker non-blocking. + +=item last_heal (0|1) + +If last_heal is 1 the matching item will be removed if the inventory checker +activates a connection and finds the item in the inventory. + +(A inventory checker that blocks a space won't remove anything from inventories) + +=item hp + +If this field is not 0 the inventory checker will search for an object +with the type id . + +=item slaying + +If this field is set the inventory checker will search for an object that +has the same string in the slaying field (for example a key string of a key). + +=item race + +If this field is set the inventory checker will search for an object which +has the archetype name that matches . + +=item connected + +This is the connection that will be activated. + +=back + +=head3 FLESH - type 72 - Organs and body parts + +See FOOD description. + +=head3 MISC_OBJECT - type 79 - Misc. objects + +A type for any object that has no special behaviour. + +=head3 HOLE - type 94 - Holes + +Holes are holes in the ground where objects can fall through. When the hole +opens and/or is completly open all objects above it fall through (more +precisely: if their head is above the hole). + +Trapdoors can only transfer the one who falls through to other coordinates +on the B map. + +=over 4 + +=item maxsp (0|1) + +This field negates the state of the connection: When maxsp is 1 the pit will +open/close when the connection is deactivated. Otherwise it will open/close +when the connection is activated. This field only has effect when the +connection is triggered. So if you put a closed hole on a map, and the +connection is deactivated, and maxsp is 1 the hole will remain closed until the +connection was triggered once. + +=item connected + +This is the connection id, which lets the hole opening or closing when +activated. The flags FLAG_ACTIVATE_ON_PUSH and FLAG_ACTIVATE_ON_RELEASE control +at which connection state the object is activated. + +For example: if FLAG_ACTIVATE_ON_RELEASE is set to 0 the hole won't react when +the connection is released. + +=item wc (internal) + +This is an internal flag. If it is greater than 0 it means that the hole is not +yet fully open. More preciesly: this field is the animation-step and if it is +set to the 'closed' step of the animation the hole is closed and if it is on +the 'open' animation step (wc = 0), the hole is open. + +=item sp + +The destination y coordinates on the same map. + +=item hp + +The destination x coordinates on the same map. + +=back + +=head3 POISONING - type 105 - The poisoning of players and monsters + +This type is doing the actual damage to the ones who were attacked +via AT_POISON (or drank POISON). + +The duration is handled via the FLAG_IS_USED_UP mechanism (please look +there for details). + +=over 4 + +=item dam + +Each time the poisoning is processed (which is determined by the speed and speed_left +fields, see the general object attributes above) it hits the player with + damage and the AT_INTERNAL attacktype (means: it will simply +hit the player with no strings attached). + +=item food + +Just a note: The posion is removed when food == 1 and not when +the whole duration is up, because the POISONING code has to remove +the poison-effects from the player before the FLAG_IS_USED_UP mechanism +deletes the POISONING object. + +=back + =head3 FORCE - type 114 - Forces Forces are a very 'thin' type. They don't have much behaviour other than -disappearing after a time and/or affecting the player if they are in his inventory. +disappearing after a time and/or affecting the player if they are in his +inventory. Forces only take effect on the player if they have set FLAG_APPLIED. @@ -491,12 +876,18 @@ speed and speed_left field. Look above at the generic description of these fields. +NOTE: Setting FLAG_IS_USED_UP on an force will also consider the 'food' field +like stated above in the FLAG_IS_USED_UP description. BUT: If the food field reaches +0 before duration and FLAG_APPLIED is set, the force will last for 'duration'. +If the FLAG_APPLIED is not set the force is removed when food reaches 0. +Generally this means: FLAG_IS_USED_UP doesn't have good semantics on forces. + =over 4 =item duration -While this field is greater than 0 the force/object is not destroyed. -It is decreased each tick by 1. +While this field is greater than 0 the force/object is not destroyed. It is +decreased each tick by 1. If it reaches 0 the force/object is destroyed. @@ -508,10 +899,11 @@ =head3 POTION_EFFECT - type 115 - Potion effects (resistancies) -This object is generated by the POTION code when the potion is a -resistance giving potion. It has mainly the same behaviour as a FORCE. +This object is generated by the POTION code when the potion is a resistance +giving potion. It has mainly the same behaviour as a FORCE. The specialty of the potion effect is that the resistancy it gives is absolute, -so if you drin a resistancy potion of fire+60 you will get 60% resistancy to fire. +so if you drin a resistancy potion of fire+60 you will get 60% resistancy to +fire. Multiple potion effects only give you the maximum of their resistancy.