Crossfire Server, Trunk
plugin_common.h
Go to the documentation of this file.
1 /*****************************************************************************/
2 /* Crossfire Plugin Interface Common Parts */
3 /* Version: 2.0beta8 (also known as "Alexander") */
4 /* Contact: yann.chachkoff@myrealbox.com */
5 /*****************************************************************************/
6 /* That code is placed under the GNU General Public Licence (GPL) */
7 /* (C)2001-2005 by Chachkoff Yann (Feel free to deliver your complaints) */
8 /*****************************************************************************/
9 /* CrossFire, A Multiplayer game for X-windows */
10 /* */
11 /* Copyright (C) 2000 Mark Wedel */
12 /* Copyright (C) 1992 Frank Tore Johansen */
13 /* */
14 /* This program is free software; you can redistribute it and/or modify */
15 /* it under the terms of the GNU General Public License as published by */
16 /* the Free Software Foundation; either version 2 of the License, or */
17 /* (at your option) any later version. */
18 /* */
19 /* This program is distributed in the hope that it will be useful, */
20 /* but WITHOUT ANY WARRANTY; without even the implied warranty of */
21 /* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the */
22 /* GNU General Public License for more details. */
23 /* */
24 /* You should have received a copy of the GNU General Public License */
25 /* along with this program; if not, write to the Free Software */
26 /* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */
27 /* */
28 /*****************************************************************************/
29 #ifndef PLUGIN_COMMON_H
30 #define PLUGIN_COMMON_H
31 
32 #ifdef WIN32
33 #define CF_PLUGIN __declspec(dllexport)
34 #else
35 #ifdef HAVE_VISIBILITY
36 #define CF_PLUGIN __attribute__((visibility("default")))
37 #else
38 #define CF_PLUGIN
39 #endif
40 #endif
41 
42 extern "C" {
43 #include <plugin.h>
44 }
45 
46 #define PLUGIN_ERROR_INT 0x0FFFFF
47 
48 extern int cf_init_plugin(f_plug_api getHooks);
49 extern void cf_system_register_global_event(int event, const char *name, f_plug_event hook);
50 extern void cf_system_unregister_global_event(int event, const char *name);
51 extern command_registration cf_system_register_command(const char *name, command_function func, uint8_t command_type, float time);
52 extern command_registration cf_system_register_command_extra(const char *name, const char *extra, command_function_extra func, uint8_t command_type, float time);
54 
55 /* General functions */
56 extern sstring cf_add_string(const char *str);
57 extern void cf_free_string(sstring str);
58 extern sstring cf_find_string(const char *str);
59 extern char *cf_strdup_local(const char *str);
60 extern char *cf_get_maps_directory(const char *name, char *buf, int size);
61 extern int cf_find_animation(const char *txt);
62 extern int cf_find_face(const char *name, int error);
63 extern void cf_log(LogLevel logLevel, const char *format, ...);
64 extern void cf_log_plain(LogLevel logLevel, const char *message);
65 extern void cf_get_time(timeofday_t *tod);
66 extern int cf_timer_create(object *ob, long delay, int mode);
67 extern int cf_timer_destroy(int id);
68 extern const char *cf_get_directory(int id);
69 extern const char *cf_re_cmp(const char *str, const char *regexp);
70 extern const char *cf_get_season_name(int index);
71 extern const char *cf_get_month_name(int index);
72 extern const char *cf_get_weekday_name(int index);
73 extern const char *cf_get_periodofday_name(int index);
74 extern void cf_cost_string_from_value(uint64_t cost, int largest_coin, char *buffer, int length);
75 
76 /* Objects */
77 extern void cf_object_set_int_property(object *op, int propcode, int value);
78 extern int cf_object_get_int_property(object *op, int propcode);
79 extern long cf_object_get_long_property(object *op, long propcode);
80 extern void cf_object_set_movetype_property(object *op, int propcode, MoveType value);
81 extern MoveType cf_object_get_movetype_property(object *op, int propcode);
82 extern object *cf_object_get_object_property(object *op, int propcode);
83 extern void cf_object_set_object_property(object *op, int propcode, object *value);
84 extern float cf_object_get_float_property(object *op, int propcode);
85 extern void cf_object_set_float_property(object *op, int propcode, float value);
86 extern mapstruct *cf_object_get_map_property(object *op, int propcode);
87 extern archetype *cf_object_get_archetype_property(object *op, int propcode);
88 extern partylist *cf_object_get_partylist_property(object *op, int propcode);
89 extern int64_t cf_object_get_int64_property(object *op, int propcode);
90 extern void cf_object_set_int64_property(object *op, int propcode, int64_t value);
91 extern double cf_object_get_double_property(object *op, int propcode);
92 extern sstring cf_object_get_sstring_property(object *op, int propcode);
93 extern char *cf_object_get_string_property(object *op, int propcode, char *buf, int size);
94 extern void cf_fix_object(object *op);
95 extern char *cf_query_name(object *ob, char *name, int size);
96 extern sstring cf_query_name_pl(object *ob);
97 extern const char *cf_object_get_msg(object *);
98 extern void cf_object_set_weight(object *ob, int weight);
99 extern int cf_object_get_weight(object *ob);
100 extern void cf_object_set_weight_limit(object *ob, int weight);
101 extern int cf_object_get_weight_limit(object *ob);
102 extern int cf_object_set_nrof(object *, int nrof);
103 extern int cf_object_get_nrof(object *);
104 extern int cf_object_get_flag(object *ob, int flag);
105 extern void cf_object_set_flag(object *ob, int flag, int value);
106 extern object *cf_object_insert_in_ob(object *op, object *where);
107 extern void cf_object_set_string_property(object *op, int propcode, const char *value);
108 extern void cf_spring_trap(object *trap, object *victim);
109 extern int cf_object_check_trigger(object *op, object *cause);
110 extern int cf_object_query_money(const object *op);
111 extern int cf_object_query_cost(const object *tmp, object *who, int flag);
112 extern void cf_object_query_cost_string(const object *tmp, object *who, int flag, char *buffer, int length);
113 extern int cf_object_cast_spell(object *op, object *caster, int dir, object *spell_ob, char *stringarg);
114 extern void cf_object_learn_spell(object *op, object *spell, int special_prayer);
115 extern void cf_object_forget_spell(object *op, object *sp);
116 extern object *cf_object_check_for_spell(object *op, const char *name);
117 extern int cf_object_pay_amount(object *pl, uint64_t to_pay);
118 extern int cf_object_pay_item(object *op, object *pl);
119 extern void cf_object_set_long_property(object *op, int propcode, long value);
120 extern int cf_object_transfer(object *op, int x, int y, int randomly, object *originator);
121 extern int cf_object_move_to(object *op, int x, int y);
122 extern int cf_object_out_of_map(object *op, int x, int y);
123 extern void cf_object_drop(object *op, object *author);
124 extern void cf_object_say(object *op, const char *msg);
125 extern object *cf_object_insert_object(object *op, object *container);
126 extern object *cf_object_present_archname_inside(object *op, char *whatstr);
127 extern int cf_object_apply(object *op, object *author, int flags);
128 extern void cf_object_remove(object *op);
129 extern void cf_object_free_drop_inventory(object *ob);
130 extern object *cf_create_object(void);
131 extern object *cf_create_object_by_name(const char *name);
132 extern object *cf_object_change_map(object *op, mapstruct *m, object *originator, int flag, int x, int y);
133 extern int cf_object_teleport(object *ob, mapstruct *map, int x, int y);
134 extern void cf_object_update(object *op, int flags);
135 extern void cf_object_pickup(object *op, object *what);
136 extern const char *cf_object_get_key(object *op, const char *keyname);
137 extern int cf_object_set_key(object *op, const char *keyname, const char *value, int add_key);
138 extern int16_t cf_object_get_resistance(object *op, int rtype);
139 extern void cf_object_set_resistance(object *op, int rtype, int16_t value);
140 extern int cf_object_move(object *op, int dir, object*originator);
141 extern void cf_object_apply_below(object *pl);
142 extern object *cf_object_clone(object *op, int clonetype);
143 extern void cf_object_change_exp(object *op, int64_t exp, const char *skill_name, int flag);
144 extern int cf_object_change_abil(object *op, object *tmp);
145 extern int cf_object_user_event(object *op, object *activator, object *third, const char *message, int fix);
146 extern int cf_object_remove_depletion(object *op, int level);
147 extern object *cf_object_find_by_arch_name(const object *who, const char *name);
148 extern object *cf_object_find_by_name(const object *who, const char *name);
149 extern object *cf_object_split(object *orig_ob, uint32_t nr, char *err, size_t size);
150 extern object *cf_object_clone(object *op, int clonetype);
151 extern int cf_object_set_face(object *op, const char *face);
152 extern int cf_object_set_animation(object *op, const char *animation);
153 extern object *cf_identify(object *op);
154 extern int64_t cf_object_perm_exp(object *op);
155 /* Maps */
156 /*extern void *cf_map_get_property(mapstruct *map, int propcode);*/
157 extern sstring cf_map_get_sstring_property(mapstruct *map, int propcode);
158 extern mapstruct *cf_map_get_map_property(mapstruct *map, int propcode);
159 extern region *cf_map_get_region_property(mapstruct *map, int propcode);
160 extern int cf_map_get_int_property(mapstruct *map, int property);
161 
162 extern void cf_map_set_int_property(mapstruct *map, int propcode, int value);
163 extern void cf_map_set_string_property(mapstruct *map, int propcode, const char *value);
164 extern mapstruct *cf_map_get_map(const char *name, int flags);
165 extern mapstruct *cf_get_empty_map(int sizex, int sizey);
166 extern mapstruct *cf_map_get_first(void);
167 extern mapstruct *cf_map_has_been_loaded(const char *name);
168 extern void cf_map_message(mapstruct *m, const char *msg, int color);
169 extern object *cf_map_get_object_at(mapstruct *m, int x, int y);
170 extern object *cf_map_insert_object(mapstruct *where, object *op, int x, int y);
171 extern object *cf_map_insert_object_around(mapstruct *where, object *op, int x, int y);
172 extern object *cf_map_find_by_archetype_name(const char *str, mapstruct *map, int nx, int ny);
173 extern int cf_map_get_flags(mapstruct *oldmap, mapstruct **newmap, int16_t x, int16_t y, int16_t *nx, int16_t *ny);
174 extern object *cf_map_insert_object_there(object *op, mapstruct *m, object *originator, int flag);
175 extern int cf_map_get_difficulty(mapstruct *map);
176 extern int cf_map_get_reset_time(mapstruct *map);
178 extern int cf_map_get_players(mapstruct *map);
179 extern int cf_map_get_darkness(mapstruct *map);
180 extern int cf_map_get_light(mapstruct *map);
181 extern int cf_map_get_width(mapstruct *map);
182 extern int cf_map_get_height(mapstruct *map);
183 extern int cf_map_get_enter_x(mapstruct *map);
184 extern int cf_map_get_enter_y(mapstruct *map);
185 extern int cf_map_change_light(mapstruct *m, int change);
186 extern void cf_map_trigger_connected(objectlink *ol, object *cause, int state);
187 
188 /* Random maps */
189 extern int cf_random_map_set_variable(RMParms *rp, const char *buf);
190 extern mapstruct *cf_random_map_generate(const char *OutFileName, RMParms *RP, char **use_layout, sstring reset_group);
191 
192 /* Players */
193 extern char *cf_player_get_title(object *op, char *title, int size);
194 extern void cf_player_set_title(object *op, const char *title);
195 extern sstring cf_player_get_ip(object *op);
196 extern object *cf_player_get_marked_item(object *op);
197 extern void cf_player_set_marked_item(object *op, object *ob);
198 extern player *cf_player_find(const char *plname);
199 extern void cf_player_message(object *op, char *txt, int flags);
200 extern int cf_player_move(player *pl, int dir);
201 extern partylist *cf_player_get_party(object *op);
202 extern void cf_player_set_party(object *op, partylist *party);
203 extern int cf_player_can_pay(object *op);
204 extern int cf_player_knowledge_has(object *op, const char *knowledge);
205 extern void cf_player_knowledge_give(object *op, const char *knowledge);
206 extern int cf_player_arrest(object *who);
207 
208 /* Archetypes */
209 extern archetype *cf_archetype_get_first(void);
214 extern object *cf_archetype_get_clone(archetype *arch);
215 
216 /* Parties */
217 extern partylist *cf_party_get_first(void);
218 extern const char *cf_party_get_name(partylist *party);
219 extern partylist *cf_party_get_next(partylist *party);
220 extern const char *cf_party_get_password(partylist *party);
223 
224 /* Regions */
225 extern region *cf_region_get_first(void);
226 extern const char *cf_region_get_name(region *reg);
227 extern region *cf_region_get_next(region *reg);
228 extern region *cf_region_get_parent(region *reg);
229 extern const char *cf_region_get_longname(region *reg);
230 extern const char *cf_region_get_message(region *reg);
231 extern int cf_region_get_jail_x(region *reg);
232 extern int cf_region_get_jail_y(region *reg);
233 extern const char *cf_region_get_jail_path(region *reg);
234 
235 /* Friendly list */
236 extern object *cf_friendlylist_get_first(void);
237 extern object *cf_friendlylist_get_next(object *ob);
238 
239 /* Quest-related functions */
240 extern int cf_quest_get_player_state(object *pl, sstring quest_code);
241 extern void cf_quest_start(object *pl, sstring quest_code, int state);
242 extern void cf_quest_set_player_state(object *pl, sstring quest_code, int state);
243 extern int cf_quest_was_completed(object *pl, sstring quest_code);
244 
245 #endif /* PLUGIN_COMMON_H */
cf_cost_string_from_value
void cf_cost_string_from_value(uint64_t cost, int largest_coin, char *buffer, int length)
Definition: plugin_common.cpp:984
cf_map_get_region_property
region * cf_map_get_region_property(mapstruct *map, int propcode)
Definition: plugin_common.cpp:278
cf_log
void cf_log(LogLevel logLevel, const char *format,...)
Definition: plugin_common.cpp:1512
cf_query_name_pl
sstring cf_query_name_pl(object *ob)
Definition: plugin_common.cpp:1199
cf_map_get_height
int cf_map_get_height(mapstruct *map)
Definition: plugin_common.cpp:1394
cf_object_check_for_spell
object * cf_object_check_for_spell(object *op, const char *name)
Definition: plugin_common.cpp:768
cf_get_weekday_name
const char * cf_get_weekday_name(int index)
Definition: plugin_common.cpp:1564
cf_region_get_jail_y
int cf_region_get_jail_y(region *reg)
Definition: plugin_common.cpp:1979
cf_add_string
sstring cf_add_string(const char *str)
Definition: plugin_common.cpp:1157
cf_map_get_first
mapstruct * cf_map_get_first(void)
Definition: plugin_common.cpp:965
cf_map_get_sstring_property
sstring cf_map_get_sstring_property(mapstruct *map, int propcode)
Definition: plugin_common.cpp:260
cf_get_directory
const char * cf_get_directory(int id)
Definition: plugin_common.cpp:1120
cf_object_get_weight
int cf_object_get_weight(object *ob)
Definition: plugin_common.cpp:1231
cf_map_get_int_property
int cf_map_get_int_property(mapstruct *map, int property)
Definition: plugin_common.cpp:244
cf_player_set_marked_item
void cf_player_set_marked_item(object *op, object *ob)
Definition: plugin_common.cpp:856
cf_map_get_players
int cf_map_get_players(mapstruct *map)
Definition: plugin_common.cpp:1382
cf_object_teleport
int cf_object_teleport(object *ob, mapstruct *map, int x, int y)
Definition: plugin_common.cpp:1350
cf_party_get_name
const char * cf_party_get_name(partylist *party)
Definition: plugin_common.cpp:1788
cf_object_out_of_map
int cf_object_out_of_map(object *op, int x, int y)
Definition: plugin_common.cpp:1025
cf_get_season_name
const char * cf_get_season_name(int index)
Definition: plugin_common.cpp:1546
cf_object_get_string_property
char * cf_object_get_string_property(object *op, int propcode, char *buf, int size)
Definition: plugin_common.cpp:438
cf_object_get_long_property
long cf_object_get_long_property(object *op, long propcode)
Definition: plugin_common.cpp:332
cf_object_apply_below
void cf_object_apply_below(object *pl)
Definition: plugin_common.cpp:543
cf_archetype_get_name
sstring cf_archetype_get_name(archetype *arch)
Definition: plugin_common.cpp:1692
cf_archetype_get_first
archetype * cf_archetype_get_first(void)
Definition: plugin_common.cpp:1676
diamondslots.x
x
Definition: diamondslots.py:15
cf_object_get_sstring_property
sstring cf_object_get_sstring_property(object *op, int propcode)
Definition: plugin_common.cpp:430
cf_player_knowledge_has
int cf_player_knowledge_has(object *op, const char *knowledge)
Definition: plugin_common.cpp:890
archininventory.arch
arch
DIALOGCHECK MINARGS 1 MAXARGS 1
Definition: archininventory.py:16
cf_object_query_cost
int cf_object_query_cost(const object *tmp, object *who, int flag)
cf_object_get_object_property
object * cf_object_get_object_property(object *op, int propcode)
Definition: plugin_common.cpp:355
cf_object_cast_spell
int cf_object_cast_spell(object *op, object *caster, int dir, object *spell_ob, char *stringarg)
Definition: plugin_common.cpp:734
cf_fix_object
void cf_fix_object(object *op)
Definition: plugin_common.cpp:1146
cf_region_get_jail_path
const char * cf_region_get_jail_path(region *reg)
Definition: plugin_common.cpp:1994
cf_player_knowledge_give
void cf_player_knowledge_give(object *op, const char *knowledge)
Definition: plugin_common.cpp:903
cf_strdup_local
char * cf_strdup_local(const char *str)
Definition: plugin_common.cpp:1436
pl
Definition: player.h:105
cf_create_object_by_name
object * cf_create_object_by_name(const char *name)
Definition: plugin_common.cpp:1083
cf_map_get_reset_time
int cf_map_get_reset_time(mapstruct *map)
Definition: plugin_common.cpp:1374
MoveType
unsigned char MoveType
Definition: define.h:417
guildjoin.ob
ob
Definition: guildjoin.py:42
cf_query_name
char * cf_query_name(object *ob, char *name, int size)
Definition: plugin_common.cpp:1191
cf_map_insert_object_around
object * cf_map_insert_object_around(mapstruct *where, object *op, int x, int y)
Definition: plugin_common.cpp:1341
cf_object_set_float_property
void cf_object_set_float_property(object *op, int propcode, float value)
Definition: plugin_common.cpp:386
cf_party_get_first_player
player * cf_party_get_first_player(partylist *party)
Definition: plugin_common.cpp:1836
cf_timer_destroy
int cf_timer_destroy(int id)
Definition: plugin_common.cpp:1610
cf_object_apply
int cf_object_apply(object *op, object *author, int flags)
Definition: plugin_common.cpp:532
giveknowledge.knowledge
knowledge
DIALOGCHECK MINARGS 1 MAXARGS 1
Definition: giveknowledge.py:15
cf_region_get_next
region * cf_region_get_next(region *reg)
Definition: plugin_common.cpp:1900
cf_object_get_int64_property
int64_t cf_object_get_int64_property(object *op, int propcode)
Definition: plugin_common.cpp:371
cf_object_move_to
int cf_object_move_to(object *op, int x, int y)
Definition: plugin_common.cpp:620
cf_object_free_drop_inventory
void cf_object_free_drop_inventory(object *ob)
Definition: plugin_common.cpp:561
cf_player_can_pay
int cf_player_can_pay(object *op)
Definition: plugin_common.cpp:876
cf_find_string
sstring cf_find_string(const char *str)
Definition: plugin_common.cpp:1179
cf_object_set_string_property
void cf_object_set_string_property(object *op, int propcode, const char *value)
Definition: plugin_common.cpp:446
Ice.tmp
int tmp
Definition: Ice.py:207
cf_object_perm_exp
int64_t cf_object_perm_exp(object *op)
Definition: plugin_common.cpp:505
plugin.h
cf_quest_set_player_state
void cf_quest_set_player_state(object *pl, sstring quest_code, int state)
Definition: plugin_common.cpp:2065
cf_map_get_light
int cf_map_get_light(mapstruct *map)
cf_map_insert_object
object * cf_map_insert_object(mapstruct *where, object *op, int x, int y)
Definition: plugin_common.cpp:1319
cf_player_arrest
int cf_player_arrest(object *who)
Definition: plugin_common.cpp:914
flags
static const flag_definition flags[]
Definition: gridarta-types-convert.c:101
cf_player_move
int cf_player_move(player *pl, int dir)
Definition: plugin_common.cpp:514
cf_party_get_next
partylist * cf_party_get_next(partylist *party)
Definition: plugin_common.cpp:1804
smoking_pipe.color
color
Definition: smoking_pipe.py:5
buf
StringBuffer * buf
Definition: readable.cpp:1611
cf_archetype_get_clone
object * cf_archetype_get_clone(archetype *arch)
Definition: plugin_common.cpp:1757
cf_player_set_title
void cf_player_set_title(object *op, const char *title)
Definition: plugin_common.cpp:832
_timeofday
Definition: tod.h:38
RMParms
Definition: random_map.h:14
cf_spring_trap
void cf_spring_trap(object *trap, object *victim)
Definition: plugin_common.cpp:995
cf_object_get_msg
const char * cf_object_get_msg(object *)
Definition: plugin_common.cpp:1208
cf_object_pay_amount
int cf_object_pay_amount(object *pl, uint64_t to_pay)
Definition: plugin_common.cpp:722
cf_object_change_abil
int cf_object_change_abil(object *op, object *tmp)
Definition: plugin_common.cpp:1661
cf_object_set_key
int cf_object_set_key(object *op, const char *keyname, const char *value, int add_key)
Definition: plugin_common.cpp:1649
archt
Definition: object.h:472
cf_quest_start
void cf_quest_start(object *pl, sstring quest_code, int state)
Definition: plugin_common.cpp:2054
cf_region_get_parent
region * cf_region_get_parent(region *reg)
Definition: plugin_common.cpp:1916
m
static event_registration m
Definition: citylife.cpp:425
autojail.who
who
Definition: autojail.py:3
cf_archetype_get_more
archetype * cf_archetype_get_more(archetype *arch)
Definition: plugin_common.cpp:1725
cf_object_set_animation
int cf_object_set_animation(object *op, const char *animation)
Definition: plugin_common.cpp:476
disinfect.map
map
Definition: disinfect.py:4
titlestruct
Definition: readable.cpp:108
cf_log_plain
void cf_log_plain(LogLevel logLevel, const char *message)
Definition: plugin_common.cpp:1532
cf_party_get_first
partylist * cf_party_get_first(void)
Definition: plugin_common.cpp:1773
cf_player_get_party
partylist * cf_player_get_party(object *op)
Definition: plugin_common.cpp:862
cf_object_say
void cf_object_say(object *op, const char *msg)
Definition: plugin_common.cpp:1039
diamondslots.activator
activator
Definition: diamondslots.py:10
cf_map_get_object_at
object * cf_map_get_object_at(mapstruct *m, int x, int y)
Definition: plugin_common.cpp:645
cf_timer_create
int cf_timer_create(object *ob, long delay, int mode)
Definition: plugin_common.cpp:1594
cf_identify
object * cf_identify(object *op)
Definition: plugin_common.cpp:802
cf_object_set_int64_property
void cf_object_set_int64_property(object *op, int propcode, int64_t value)
Definition: plugin_common.cpp:392
cf_find_face
int cf_find_face(const char *name, int error)
Definition: plugin_common.cpp:1500
cf_map_insert_object_there
object * cf_map_insert_object_there(object *op, mapstruct *m, object *originator, int flag)
Definition: plugin_common.cpp:1305
f_plug_api
void(* f_plug_api)(int *type,...)
Definition: plugin.h:81
cf_map_get_enter_y
int cf_map_get_enter_y(mapstruct *map)
Definition: plugin_common.cpp:1402
cf_system_unregister_global_event
void cf_system_unregister_global_event(int event, const char *name)
Definition: plugin_common.cpp:1099
cf_get_month_name
const char * cf_get_month_name(int index)
Definition: plugin_common.cpp:1555
cf_init_plugin
int cf_init_plugin(f_plug_api getHooks)
Definition: plugin_common.cpp:141
cf_object_get_movetype_property
MoveType cf_object_get_movetype_property(object *op, int propcode)
Definition: plugin_common.cpp:347
cf_object_find_by_arch_name
object * cf_object_find_by_arch_name(const object *who, const char *name)
Definition: plugin_common.cpp:582
cf_object_get_map_property
mapstruct * cf_object_get_map_property(object *op, int propcode)
Definition: plugin_common.cpp:363
cf_object_query_money
int cf_object_query_money(const object *op)
Definition: plugin_common.cpp:973
make_face_from_files.str
str
Definition: make_face_from_files.py:24
cf_region_get_longname
const char * cf_region_get_longname(region *reg)
Definition: plugin_common.cpp:1932
cf_get_empty_map
mapstruct * cf_get_empty_map(int sizex, int sizey)
Definition: plugin_common.cpp:938
cf_region_get_first
region * cf_region_get_first(void)
Definition: plugin_common.cpp:1868
cf_map_set_int_property
void cf_map_set_int_property(mapstruct *map, int propcode, int value)
Definition: plugin_common.cpp:288
cf_object_query_cost_string
void cf_object_query_cost_string(const object *tmp, object *who, int flag, char *buffer, int length)
navar-midane_pickup.msg
list msg
Definition: navar-midane_pickup.py:13
cf_object_get_partylist_property
partylist * cf_object_get_partylist_property(object *op, int propcode)
Definition: plugin_common.cpp:414
cf_object_get_nrof
int cf_object_get_nrof(object *)
Definition: plugin_common.cpp:1260
cf_object_set_weight_limit
void cf_object_set_weight_limit(object *ob, int weight)
Definition: plugin_common.cpp:1224
cf_object_clone
object * cf_object_clone(object *op, int clonetype)
Definition: plugin_common.cpp:673
cf_object_get_double_property
double cf_object_get_double_property(object *op, int propcode)
Definition: plugin_common.cpp:422
sstring
const typedef char * sstring
Definition: global.h:43
cf_map_message
void cf_map_message(mapstruct *m, const char *msg, int color)
Definition: plugin_common.cpp:657
cf_map_get_reset_timeout
int cf_map_get_reset_timeout(mapstruct *map)
Definition: plugin_common.cpp:1378
cf_object_get_flag
int cf_object_get_flag(object *ob, int flag)
Definition: plugin_common.cpp:1267
devourers.command
command
Definition: devourers.py:16
mapdef
Definition: map.h:317
cf_object_drop
void cf_object_drop(object *op, object *author)
Definition: plugin_common.cpp:1033
cf_map_get_enter_x
int cf_map_get_enter_x(mapstruct *map)
Definition: plugin_common.cpp:1398
cf_map_get_map_property
mapstruct * cf_map_get_map_property(mapstruct *map, int propcode)
Definition: plugin_common.cpp:269
cf_object_transfer
int cf_object_transfer(object *op, int x, int y, int randomly, object *originator)
Definition: plugin_common.cpp:608
cf_object_set_movetype_property
void cf_object_set_movetype_property(object *op, int propcode, MoveType value)
Definition: plugin_common.cpp:340
cf_map_get_flags
int cf_map_get_flags(mapstruct *oldmap, mapstruct **newmap, int16_t x, int16_t y, int16_t *nx, int16_t *ny)
Definition: plugin_common.cpp:1451
party_struct
Definition: party.h:10
cf_free_string
void cf_free_string(sstring str)
Definition: plugin_common.cpp:1172
cf_region_get_message
const char * cf_region_get_message(region *reg)
Definition: plugin_common.cpp:1948
cf_random_map_set_variable
int cf_random_map_set_variable(RMParms *rp, const char *buf)
Definition: plugin_common.cpp:1463
cf_object_present_archname_inside
object * cf_object_present_archname_inside(object *op, char *whatstr)
Definition: plugin_common.cpp:569
cf_object_find_by_name
object * cf_object_find_by_name(const object *who, const char *name)
Definition: plugin_common.cpp:595
cf_object_pickup
void cf_object_pickup(object *op, object *what)
Definition: plugin_common.cpp:1424
cf_region_get_jail_x
int cf_region_get_jail_x(region *reg)
Definition: plugin_common.cpp:1964
cf_object_get_archetype_property
archetype * cf_object_get_archetype_property(object *op, int propcode)
Definition: plugin_common.cpp:406
cf_player_get_marked_item
object * cf_player_get_marked_item(object *op)
Definition: plugin_common.cpp:847
cf_system_register_command_extra
command_registration cf_system_register_command_extra(const char *name, const char *extra, command_function_extra func, uint8_t command_type, float time)
Definition: plugin_common.cpp:2093
cf_map_set_string_property
void cf_map_set_string_property(mapstruct *map, int propcode, const char *value)
Definition: plugin_common.cpp:295
cf_object_insert_in_ob
object * cf_object_insert_in_ob(object *op, object *where)
Definition: plugin_common.cpp:1288
cf_object_user_event
int cf_object_user_event(object *op, object *activator, object *third, const char *message, int fix)
Definition: plugin_common.cpp:252
cf_object_move
int cf_object_move(object *op, int dir, object *originator)
Definition: plugin_common.cpp:521
diamondslots.message
string message
Definition: diamondslots.py:57
cf_object_split
object * cf_object_split(object *orig_ob, uint32_t nr, char *err, size_t size)
Definition: plugin_common.cpp:687
cf_system_register_global_event
void cf_system_register_global_event(int event, const char *name, f_plug_event hook)
Definition: plugin_common.cpp:1092
cf_system_register_command
command_registration cf_system_register_command(const char *name, command_function func, uint8_t command_type, float time)
Definition: plugin_common.cpp:2085
cf_player_set_party
void cf_player_set_party(object *op, partylist *party)
Definition: plugin_common.cpp:866
cf_find_animation
int cf_find_animation(const char *txt)
Definition: plugin_common.cpp:1488
cf_object_set_weight
void cf_object_set_weight(object *ob, int weight)
Definition: plugin_common.cpp:1217
cf_archetype_get_next
archetype * cf_archetype_get_next(archetype *arch)
Definition: plugin_common.cpp:1709
cf_get_periodofday_name
const char * cf_get_periodofday_name(int index)
Definition: plugin_common.cpp:1573
cf_map_trigger_connected
void cf_map_trigger_connected(objectlink *ol, object *cause, int state)
Definition: plugin_common.cpp:1018
reputation.victim
victim
Definition: reputation.py:14
cf_object_set_flag
void cf_object_set_flag(object *ob, int flag, int value)
Definition: plugin_common.cpp:1278
f_plug_event
int(* f_plug_event)(int *type,...)
Definition: events.h:67
cf_region_get_name
const char * cf_region_get_name(region *reg)
Definition: plugin_common.cpp:1884
give.op
op
Definition: give.py:33
autojail.value
value
Definition: autojail.py:6
board.author
author
Definition: board.py:59
cf_object_set_nrof
int cf_object_set_nrof(object *, int nrof)
Definition: plugin_common.cpp:1250
cf_map_has_been_loaded
mapstruct * cf_map_has_been_loaded(const char *name)
Definition: plugin_common.cpp:951
cf_re_cmp
const char * cf_re_cmp(const char *str, const char *regexp)
Definition: plugin_common.cpp:1133
cf_object_check_trigger
int cf_object_check_trigger(object *op, object *cause)
Definition: plugin_common.cpp:1006
cf_quest_get_player_state
int cf_quest_get_player_state(object *pl, sstring quest_code)
Definition: plugin_common.cpp:2041
cf_object_set_long_property
void cf_object_set_long_property(object *op, int propcode, long value)
Definition: plugin_common.cpp:380
diamondslots.y
y
Definition: diamondslots.py:16
cf_create_object
object * cf_create_object(void)
Definition: plugin_common.cpp:1071
python_pickup.where
where
Definition: python_pickup.py:7
cf_get_maps_directory
char * cf_get_maps_directory(const char *name, char *buf, int size)
Definition: plugin_common.cpp:1059
npc_dialog.index
int index
Definition: npc_dialog.py:102
cf_object_get_key
const char * cf_object_get_key(object *op, const char *keyname)
Definition: plugin_common.cpp:1627
cf_player_find
player * cf_player_find(const char *plname)
Definition: plugin_common.cpp:815
cf_friendlylist_get_next
object * cf_friendlylist_get_next(object *ob)
Definition: plugin_common.cpp:2026
cf_party_get_password
const char * cf_party_get_password(partylist *party)
Definition: plugin_common.cpp:1820
cf_player_get_title
char * cf_player_get_title(object *op, char *title, int size)
Definition: plugin_common.cpp:824
cf_system_unregister_command
void cf_system_unregister_command(command_registration command)
Definition: plugin_common.cpp:2101
cf_archetype_get_head
archetype * cf_archetype_get_head(archetype *arch)
Definition: plugin_common.cpp:1741
command_function_extra
void(* command_function_extra)(object *op, const char *params, const char *extra)
Definition: commands.h:29
cf_map_get_difficulty
int cf_map_get_difficulty(mapstruct *map)
Definition: plugin_common.cpp:1370
cf_party_get_next_player
player * cf_party_get_next_player(partylist *party, player *op)
Definition: plugin_common.cpp:1854
cf_object_set_face
int cf_object_set_face(object *op, const char *face)
Definition: plugin_common.cpp:464
animate.event
event
DIALOGCHECK MINARGS 1 MAXARGS 2
Definition: animate.py:17
quest.state
state
Definition: quest.py:13
command_registration
uint64_t command_registration
Definition: commands.h:32
cf_map_get_darkness
int cf_map_get_darkness(mapstruct *map)
Definition: plugin_common.cpp:1386
cf_map_get_map
mapstruct * cf_map_get_map(const char *name, int flags)
Definition: plugin_common.cpp:925
cf_object_change_map
object * cf_object_change_map(object *op, mapstruct *m, object *originator, int flag, int x, int y)
Definition: plugin_common.cpp:632
cf_random_map_generate
mapstruct * cf_random_map_generate(const char *OutFileName, RMParms *RP, char **use_layout, sstring reset_group)
Definition: plugin_common.cpp:1475
cf_object_forget_spell
void cf_object_forget_spell(object *op, object *sp)
Definition: plugin_common.cpp:758
cf_object_pay_item
int cf_object_pay_item(object *op, object *pl)
Definition: plugin_common.cpp:710
cf_object_get_weight_limit
int cf_object_get_weight_limit(object *ob)
Definition: plugin_common.cpp:1239
cf_object_insert_object
object * cf_object_insert_object(object *op, object *container)
Definition: plugin_common.cpp:1046
cf_object_get_resistance
int16_t cf_object_get_resistance(object *op, int rtype)
Definition: plugin_common.cpp:303
cf_object_set_int_property
void cf_object_set_int_property(object *op, int propcode, int value)
Definition: plugin_common.cpp:319
report.error
def error(pl)
Definition: report.py:43
LogLevel
LogLevel
Definition: logger.h:10
diamondslots.cost
int cost
Definition: diamondslots.py:21
cf_object_update
void cf_object_update(object *op, int flags)
Definition: plugin_common.cpp:1418
cf_friendlylist_get_first
object * cf_friendlylist_get_first(void)
Definition: plugin_common.cpp:2010
oblnk
Definition: object.h:449
cf_object_remove
void cf_object_remove(object *op)
Definition: plugin_common.cpp:552
command_function
void(* command_function)(object *op, const char *params)
Definition: commands.h:17
cf_object_change_exp
void cf_object_change_exp(object *op, int64_t exp, const char *skill_name, int flag)
Definition: plugin_common.cpp:494
cf_player_get_ip
sstring cf_player_get_ip(object *op)
Definition: plugin_common.cpp:838
cf_player_message
void cf_player_message(object *op, char *txt, int flags)
Definition: plugin_common.cpp:777
cf_object_set_object_property
void cf_object_set_object_property(object *op, int propcode, object *value)
Definition: plugin_common.cpp:483
cf_map_find_by_archetype_name
object * cf_map_find_by_archetype_name(const char *str, mapstruct *map, int nx, int ny)
Definition: plugin_common.cpp:1361
cf_object_learn_spell
void cf_object_learn_spell(object *op, object *spell, int special_prayer)
Definition: plugin_common.cpp:746
cf_map_get_width
int cf_map_get_width(mapstruct *map)
Definition: plugin_common.cpp:1390
cf_object_get_int_property
int cf_object_get_int_property(object *op, int propcode)
Definition: plugin_common.cpp:325
cf_quest_was_completed
int cf_quest_was_completed(object *pl, sstring quest_code)
Definition: plugin_common.cpp:2076
cf_object_get_float_property
float cf_object_get_float_property(object *op, int propcode)
Definition: plugin_common.cpp:398
cf_map_change_light
int cf_map_change_light(mapstruct *m, int change)
Definition: plugin_common.cpp:1410
cf_get_time
void cf_get_time(timeofday_t *tod)
Definition: plugin_common.cpp:1539
cf_object_set_resistance
void cf_object_set_resistance(object *op, int rtype, int16_t value)
Definition: plugin_common.cpp:311
cf_object_remove_depletion
int cf_object_remove_depletion(object *op, int level)
Definition: plugin_common.cpp:788
give.name
name
Definition: give.py:27
level
Definition: level.py:1
regiondef
Definition: map.h:275