82 propname = va_arg(args,
const char *);
84 if (!strcmp(propname,
"Identification")) {
85 buf = va_arg(args,
char *);
86 size = va_arg(args,
int);
90 }
else if (!strcmp(propname,
"FullName")) {
91 buf = va_arg(args,
char *);
92 size = va_arg(args,
int);
106 #define FIRST_MOVE_KEY "citylife_first_move"
226 { NULL, -1, NULL, -1, 1,
"", NULL, 0 },
240 for (test = 0; available_zones[test].
count_points != -1; test++) {
241 if (strcmp(available_zones[test].mapname, map->
path) == 0)
242 return &available_zones[test];
345 for (test = 0; available_zones[test].
count_points != -1 && count < 50; test++) {
354 test = RANDOM()%count;
364 va_start(args, type);
365 code = va_arg(args,
int);
376 if (RANDOM()%40 == 0)
418 object *ground, *who, *activator, *third, *event;
422 va_start(args, type);
424 who = va_arg(args,
object *);
425 activator = va_arg(args,
object *);
426 third = va_arg(args,
object *);
427 buf = va_arg(args,
char *);
428 fix = va_arg(args,
int);
429 event = va_arg(args,
object *);
433 if (RANDOM()%100 < 30) {
439 if (strcmp(value,
"1") == 0) {
static const spawn_point scorn_se_points[]
static const spawn_zone scorn_nw_zones[]
#define CFAPI_OBJECT_PROP_OB_BELOW
const char * cf_object_get_key(object *op, const char *keyname)
static const spawn_point scorn_nw_points[]
void cf_object_set_flag(object *ob, int flag, int value)
static const spawn_point scorn_ne_points[]
#define CFAPI_OBJECT_PROP_INVENTORY
static const house_zone_struct zones[]
void *(* f_plug_api)(int *type,...)
void cf_system_register_global_event(int event, const char *name, f_plug_api hook)
sstring cf_add_string(const char *str)
CF_PLUGIN int postInitPlugin(void)
CF_PLUGIN int closePlugin(void)
static object * get_npc(const mapzone *zone)
static const spawn_point scorn_sw_points[]
static void add_npc_to_random_map(void)
void cf_log(LogLevel logLevel, const char *format,...)
CF_PLUGIN void * getPluginProperty(int *type,...)
CF_PLUGIN void * citylife_globalEventListener(int *type,...)
int cf_init_plugin(f_plug_api getHooks)
CF_PLUGIN void * eventListener(int *type,...)
static void add_npc_to_zone(const mapzone *zone, mapstruct *map)
static const mapzone available_zones[]
object * cf_object_insert_object(object *op, object *container)
const spawn_point * points
static void add_npc_to_point(const mapzone *zone, mapstruct *map)
static const spawn_zone scorn_ne_zones[]
void cf_object_remove(object *op)
object * cf_map_get_object_at(mapstruct *m, int x, int y)
CF_PLUGIN int citylife_runPluginCommand(object *op, char *params)
static const spawn_zone scorn_se_zones[]
object * cf_object_get_object_property(object *op, int propcode)
int snprintf(char *dest, int max, const char *format,...)
int cf_object_move(object *op, int dir, object *originator)
static const spawn_zone scorn_sw_zones[]
mapstruct * cf_map_has_been_loaded(const char *name)
static const char *const scorn_archs[]
static const mapzone * get_zone_for_map(mapstruct *map)
int cf_object_teleport(object *ob, mapstruct *map, int x, int y)
static void add_npcs_to_map(mapstruct *map)
void cf_object_free(object *ob)
#define CFAPI_OBJECT_PROP_OB_ABOVE
object * cf_create_object_by_name(const char *name)
const char *const * available_archetypes
CF_PLUGIN int initPlugin(const char *iversion, f_plug_api gethooksptr)
int cf_object_set_key(object *op, const char *keyname, const char *value, int add_key)