Crossfire Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

editing objects



This is a breif description on how to edit and create new
objects:

All objects in the game are contained in the archetypes file found in the lib
directory.
This file is read in at the beginning of each game.
Take a look at it.

Desciption of each argument:


name : What defualt name will appear when object is looked at. This name can
       be changed in the editor.

type : The type is defined in define.c.
        <defined in define.h, right after VERY_BIG_BUF>

face : What character in the font that the object will have.

anim/mina : If the object is to be animated, the numbers in between represent
            the order and which characters in the font to use in the animation.

alive : a flag, if set to 1, then the object is alive.

immune: a set of flags to determine what an object is immune to.

    #define PHYSICAL        1
    #define MAGIC           2
    #define FIRE            4
    #define ELECTRICITY     8
    #define COLD            16
    #define WATER           32
    #define ACID            64  /* Rusts things */
    #define DRAIN           128 /* Drain Life */
    #define WEAPONMAGIC     256
    #define GHOSTHIT        512 /* Attacker dissolves */


material: flag, to determine what type of material the object is made of.
    
     #define M_PAPER         1
     #define M_IRON          2
     #define M_GLASS         4
     #define M_LEATHER       8
     #define M_WOOD          16
     #define M_ORGANIC       32
     #define M_STONE         64


no_pick: if set to 1, player can not pick up the item.

no_pass: if set to 1, player can move over that object.

value: what an item is worth.

weight : what an item weighs.

walk_on : if set to 1, automatically applies the object, when walked on.

speed: tells how fast a live object will move or do an action.

nrof : I believe this determines if the object will disappear after being
       applied. This will happen if nrof is set to 1. (Don't quote me on this.)
       ???????

exp :
hp : 
maxhp :
ac : 
dam : 
wc :    Thaco, I believe.
level :

All the above act the same as a player's stats. The exp, is how much exp the
object is worth upon killing it.


sp :  this is a special ability for non-player objects. For generators it 
      determines how what a generator will generate. The number being the type
      number of the object to generator, "type" defined above.
     
      if object is of type 4, a treasure, it will generate a treasure when
      applied. It choses what type of treasure from several treasure lists,
      located in treasure.c. sp tells what list to choose from.



Any new object added to this file will automatically appear on the map editor.
Well, this will give people a start. Anyway, I know Frank has an Object
editor in the agenda after he gets back, but until then, you can change
archtypes directly.


any questions, give me a buzz.


tyler
skud.
tvangod@ecst.csuchio.edu