 |
Crossfire Server, Trunk
1.75.0
|
Go to the documentation of this file.
49 return val ? val :
"0";
93 char anim_name_buf[128];
94 int anim_name_len = strlen(op->
face->
name);
95 strncpy(anim_name_buf, op->
face->
name, 128);
97 anim_name_buf[anim_name_len-4] =
'\0';
98 strncat(anim_name_buf,
"_mimic", 128-anim_name_len+4);
sstring name
Face name, as used by archetypes and such.
int16_t maxhp
Max hit points.
@ MONSTER
A real, living creature.
void init_type_mimic(void)
Initializer for MIMIC type.
#define FABS(x)
Decstations have trouble with fabs()...
uint16_t difficulty
What level the player should be to play here.
static const char * object_try_get_value(object *op, const char *key)
void register_apply(int ob_type, apply_func method)
Registers the apply method for the given type.
float speed
Frequency of object 'moves' relative to server tick rate.
struct mapstruct * map
Pointer to the map in which this object is present.
void draw_ext_info_format(int flags, int pri, const object *pl, uint8_t type, uint8_t subtype, const char *format,...) PRINTF_ARGS(6
object * enemy
Monster/player to follow even if not closest.
static method_ret mimic_type_apply(object *op, object *applier, int aflags)
Implementation of mimics This should be usable for any item masquerading as a container (or other ite...
int16_t level
Level of creature or object.
object * object_insert_in_ob(object *op, object *where)
This function inserts the object op in the linked list inside the object environment.
Plugin animator file specs[Config] name
#define FLAG_ALIVE
Object can fight (or be fought)
short freearr_y[SIZEOFFREE]
Y offset when searching around a spot.
#define MSG_TYPE_APPLY_SUCCESS
Was able to apply object.
void query_name(const object *op, char *buf, size_t size)
Describes an item.
const Face * face
Face with colors.
#define FREE_AND_COPY(sv, nv)
Release the shared string if not NULL, and make it a reference to nv.
uint8_t type
PLAYER, BULLET, etc.
int16_t dam
How much damage this object does when hitting.
const Animations * animation
Animation of this item, NULL if not animated.
object * object_insert_in_map_at(object *op, mapstruct *m, object *originator, int flag, int x, int y)
Same as object_insert_in_map() except it handle separate coordinates and do a clean job preparing mul...
#define FLAG_MONSTER
Will attack players.
static std::shared_ptr< inja::Environment > env
Rendering environment.
#define MAX_BUF
Used for all kinds of things.
int8_t wc
Weapon Class, lower WC increases probability of hitting.
char method_ret
Define some standard return values for callbacks which don't need to return any other results.
#define NDI_UNIQUE
Print immediately, don't buffer.
sstring name
The name of the object, obviously...
object * env
Pointer to the object which is the environment.
int object_find_free_spot(const object *ob, mapstruct *m, int x, int y, int start, int stop)
object_find_free_spot(object, map, x, y, start, stop) will search for a spot at the given map and coo...
sstring object_get_value(const object *op, const char *const key)
Get an extra value by key.
int8_t ac
Armor Class, lower AC increases probability of not getting hit.
Animations * find_animation(const char *name)
#define MSG_TYPE_APPLY_FAILURE
Apply OK, but no/bad result.
#define FLAG_ANIMATE
The object looks at archetype for faces.
void object_remove(object *op)
This function removes the object op from the linked list of objects which it is currently tied to.
living stats
Str, Con, Dex, etc.
short freearr_x[SIZEOFFREE]
X offset when searching around a spot.
#define MSG_TYPE_APPLY
Applying objects.