1 | /*****************************************************************************/ |
1 | /*****************************************************************************/ |
2 | /* That code is placed under the GNU General Public Licence (GPL) */ |
|
|
3 | /* (C)2001-2005 by Chachkoff Yann (Feel free to deliver your complaints) */ |
|
|
4 | /*****************************************************************************/ |
|
|
5 | /* CrossFire, A Multiplayer game for X-windows */ |
2 | /* CrossFire, A Multiplayer game for the X Window System */ |
6 | /* */ |
|
|
7 | /* Copyright (C) 2000 Mark Wedel */ |
|
|
8 | /* Copyright (C) 1992 Frank Tore Johansen */ |
|
|
9 | /* Copyright (C) 2006 perl plugin by Marc Lehmann <cf@schmorpd.e> */ |
|
|
10 | /* */ |
|
|
11 | /* This program is free software; you can redistribute it and/or modify */ |
|
|
12 | /* it under the terms of the GNU General Public License as published by */ |
|
|
13 | /* the Free Software Foundation; either version 2 of the License, or */ |
|
|
14 | /* (at your option) any later version. */ |
|
|
15 | /* */ |
|
|
16 | /* This program is distributed in the hope that it will be useful, */ |
|
|
17 | /* but WITHOUT ANY WARRANTY; without even the implied warranty of */ |
|
|
18 | /* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the */ |
|
|
19 | /* GNU General Public License for more details. */ |
|
|
20 | /* */ |
|
|
21 | /* You should have received a copy of the GNU General Public License */ |
|
|
22 | /* along with this program; if not, write to the Free Software */ |
|
|
23 | /* Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ |
|
|
24 | /* */ |
3 | /* */ |
25 | /*****************************************************************************/ |
4 | /*****************************************************************************/ |
|
|
5 | |
|
|
6 | /* |
|
|
7 | * This code is placed under the GNU General Public Licence (GPL) |
|
|
8 | * |
|
|
9 | * Copyright (C) 2001-2005 by Chachkoff Yann |
|
|
10 | * Copyright (C) 2006 by Marc Lehmann <cf@schmorpd.e> |
|
|
11 | * |
|
|
12 | * This program is free software; you can redistribute it and/or modify |
|
|
13 | * it under the terms of the GNU General Public License as published by |
|
|
14 | * the Free Software Foundation; either version 2 of the License, or |
|
|
15 | * (at your option) any later version. |
|
|
16 | * |
|
|
17 | * This program is distributed in the hope that it will be useful, |
|
|
18 | * but WITHOUT ANY WARRANTY; without even the implied warranty of |
|
|
19 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
|
|
20 | * GNU General Public License for more details. |
|
|
21 | * |
|
|
22 | * You should have received a copy of the GNU General Public License |
|
|
23 | * along with this program; if not, write to the Free Software |
|
|
24 | * Foundation, Inc. 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA |
|
|
25 | */ |
26 | |
26 | |
27 | #include <EXTERN.h> |
27 | #include <EXTERN.h> |
28 | #include <perl.h> |
28 | #include <perl.h> |
29 | #include <XSUB.h> |
29 | #include <XSUB.h> |
30 | |
30 | |
… | |
… | |
128 | case CFAPI_DOUBLE: |
128 | case CFAPI_DOUBLE: |
129 | sv = newSViv (*va_arg (args, double *)); |
129 | sv = newSViv (*va_arg (args, double *)); |
130 | break; |
130 | break; |
131 | |
131 | |
132 | case CFAPI_STRING: |
132 | case CFAPI_STRING: |
133 | sv = newSVpv (va_arg (args, char *), 0); |
133 | { |
|
|
134 | char *str = va_arg (args, char *); |
|
|
135 | sv = str ? newSVpv (str, 0) : &PL_sv_undef; |
|
|
136 | } |
134 | break; |
137 | break; |
135 | |
138 | |
136 | case CFAPI_POBJECT: |
139 | case CFAPI_POBJECT: |
137 | { |
140 | { |
138 | object *obj = va_arg (args, object *); |
141 | object *obj = va_arg (args, object *); |
… | |
… | |
156 | } |
159 | } |
157 | } |
160 | } |
158 | break; |
161 | break; |
159 | |
162 | |
160 | case CFAPI_PMAP: |
163 | case CFAPI_PMAP: |
161 | sv = newSVptr (va_arg (args, object *), "cf::map"); |
164 | sv = newSVptr (va_arg (args, mapstruct *), "cf::map"); |
162 | break; |
165 | break; |
163 | |
166 | |
164 | case CFAPI_PPLAYER: |
167 | case CFAPI_PPLAYER: |
165 | sv = newSVptr (va_arg (args, object *), "cf::player"); |
168 | sv = newSVptr (va_arg (args, player *), "cf::player"); |
166 | break; |
169 | break; |
167 | |
170 | |
168 | case CFAPI_PARCH: |
171 | case CFAPI_PARCH: |
169 | sv = newSVptr (va_arg (args, object *), "cf::arch"); |
172 | sv = newSVptr (va_arg (args, archetype *), "cf::arch"); |
170 | break; |
173 | break; |
171 | |
174 | |
172 | case CFAPI_PPARTY: |
175 | case CFAPI_PPARTY: |
173 | sv = newSVptr (va_arg (args, object *), "cf::party"); |
176 | sv = newSVptr (va_arg (args, partylist *), "cf::party"); |
174 | break; |
177 | break; |
175 | |
178 | |
176 | case CFAPI_PREGION: |
179 | case CFAPI_PREGION: |
177 | sv = newSVptr (va_arg (args, object *), "cf::region"); |
180 | sv = newSVptr (va_arg (args, region *), "cf::region"); |
178 | break; |
181 | break; |
179 | |
182 | |
180 | default: |
183 | default: |
181 | assert (("unhandled type in newSVcfapi", 0)); |
184 | assert (("unhandled type in newSVcfapi", 0)); |
182 | } |
185 | } |
… | |
… | |
215 | |
218 | |
216 | PUTBACK; |
219 | PUTBACK; |
217 | int count = call_pv ("cf::inject_event", G_SCALAR | G_EVAL); |
220 | int count = call_pv ("cf::inject_event", G_SCALAR | G_EVAL); |
218 | SPAGAIN; |
221 | SPAGAIN; |
219 | |
222 | |
|
|
223 | if (SvTRUE (ERRSV)) |
|
|
224 | LOG (llevError, "event '%d' callback evaluation error: %s", context->event_code, SvPV_nolen (ERRSV)); |
|
|
225 | |
220 | context->returnvalue = count > 0 ? POPi : 0; |
226 | context->returnvalue = count > 0 ? POPi : 0; |
221 | |
227 | |
222 | PUTBACK; |
228 | PUTBACK; |
223 | FREETMPS; |
229 | FREETMPS; |
224 | LEAVE; |
230 | LEAVE; |
225 | |
|
|
226 | if (SvTRUE (ERRSV)) |
|
|
227 | LOG (llevError, "event '%d' callback evaluation error: %s", context->event_code, SvPV_nolen (ERRSV)); |
|
|
228 | } |
231 | } |
229 | |
232 | |
230 | ///////////////////////////////////////////////////////////////////////////// |
233 | ///////////////////////////////////////////////////////////////////////////// |
231 | |
234 | |
232 | int |
235 | int |
… | |
… | |
259 | |
262 | |
260 | PUTBACK; |
263 | PUTBACK; |
261 | int count = call_pv ("cf::inject_command", G_SCALAR | G_EVAL); |
264 | int count = call_pv ("cf::inject_command", G_SCALAR | G_EVAL); |
262 | SPAGAIN; |
265 | SPAGAIN; |
263 | |
266 | |
|
|
267 | if (SvTRUE (ERRSV)) |
|
|
268 | LOG (llevError, "command '%s' callback evaluation error: %s", rtn_cmd.name, SvPV_nolen (ERRSV)); |
|
|
269 | |
264 | int returnvalue = count > 0 ? POPi : -1; |
270 | int returnvalue = count > 0 ? POPi : -1; |
265 | |
271 | |
266 | PUTBACK; |
272 | PUTBACK; |
267 | FREETMPS; |
273 | FREETMPS; |
268 | LEAVE; |
274 | LEAVE; |
269 | |
|
|
270 | if (SvTRUE (ERRSV)) |
|
|
271 | LOG (llevError, "command '%s' callback evaluation error: %s", rtn_cmd.name, SvPV_nolen (ERRSV)); |
|
|
272 | |
275 | |
273 | return returnvalue; |
276 | return returnvalue; |
274 | } |
277 | } |
275 | |
278 | |
276 | void * |
279 | void * |
… | |
… | |
540 | |
543 | |
541 | BOOT: |
544 | BOOT: |
542 | { |
545 | { |
543 | HV *stash = gv_stashpv ("cf", 1); |
546 | HV *stash = gv_stashpv ("cf", 1); |
544 | |
547 | |
545 | const struct { |
548 | static const struct { |
546 | const char *name; |
549 | const char *name; |
547 | IV iv; |
550 | IV iv; |
548 | } *civ, const_iv[] = { |
551 | } *civ, const_iv[] = { |
549 | # define const_iv(name) { # name, (IV)name }, |
552 | # define const_iv(name) { # name, (IV)name }, |
550 | const_iv (llevError) |
553 | const_iv (llevError) |
… | |
… | |
801 | const_iv (FLAG_IS_WATER) |
804 | const_iv (FLAG_IS_WATER) |
802 | const_iv (FLAG_CONTENT_ON_GEN) |
805 | const_iv (FLAG_CONTENT_ON_GEN) |
803 | const_iv (FLAG_IS_A_TEMPLATE) |
806 | const_iv (FLAG_IS_A_TEMPLATE) |
804 | const_iv (FLAG_IS_BUILDABLE) |
807 | const_iv (FLAG_IS_BUILDABLE) |
805 | const_iv (FLAG_AFK) |
808 | const_iv (FLAG_AFK) |
|
|
809 | |
|
|
810 | const_iv (NDI_BLACK) |
|
|
811 | const_iv (NDI_WHITE) |
|
|
812 | const_iv (NDI_NAVY) |
|
|
813 | const_iv (NDI_RED) |
|
|
814 | const_iv (NDI_ORANGE) |
|
|
815 | const_iv (NDI_BLUE) |
|
|
816 | const_iv (NDI_DK_ORANGE) |
|
|
817 | const_iv (NDI_GREEN) |
|
|
818 | const_iv (NDI_LT_GREEN) |
|
|
819 | const_iv (NDI_GREY) |
|
|
820 | const_iv (NDI_BROWN) |
|
|
821 | const_iv (NDI_GOLD) |
|
|
822 | const_iv (NDI_TAN) |
|
|
823 | const_iv (NDI_MAX_COLOR) |
|
|
824 | const_iv (NDI_COLOR_MASK) |
|
|
825 | const_iv (NDI_UNIQUE) |
|
|
826 | const_iv (NDI_ALL) |
|
|
827 | |
|
|
828 | const_iv (F_APPLIED) |
|
|
829 | const_iv (F_LOCATION) |
|
|
830 | const_iv (F_UNPAID) |
|
|
831 | const_iv (F_MAGIC) |
|
|
832 | const_iv (F_CURSED) |
|
|
833 | const_iv (F_DAMNED) |
|
|
834 | const_iv (F_OPEN) |
|
|
835 | const_iv (F_NOPICK) |
|
|
836 | const_iv (F_LOCKED) |
806 | }; |
837 | }; |
807 | |
838 | |
808 | for (civ = const_iv + sizeof (const_iv) / sizeof (const_iv [0]); civ-- > const_iv; ) |
839 | for (civ = const_iv + sizeof (const_iv) / sizeof (const_iv [0]); civ-- > const_iv; ) |
809 | newCONSTSUB (stash, (char *)civ->name, newSViv (civ->iv)); |
840 | newCONSTSUB (stash, (char *)civ->name, newSViv (civ->iv)); |
810 | |
841 | |
811 | const struct { |
842 | static const struct { |
812 | const char *name; |
843 | const char *name; |
813 | IV iv; |
844 | IV iv; |
814 | } *event, event_list[] = { |
845 | } *event, event_list[] = { |
815 | # define const_event(name) { # name, (IV)EVENT_ ## name }, |
846 | # define const_event(name) { # name, (IV)EVENT_ ## name }, |
816 | const_event (NONE) |
847 | const_event (NONE) |
… | |
… | |
847 | AV *av = get_av ("cf::EVENT", 1); |
878 | AV *av = get_av ("cf::EVENT", 1); |
848 | |
879 | |
849 | for (event = event_list + sizeof (event_list) / sizeof (event_list [0]); event-- > event_list; ) |
880 | for (event = event_list + sizeof (event_list) / sizeof (event_list [0]); event-- > event_list; ) |
850 | av_store (av, event->iv, newSVpv ((char *)event->name, 0)); |
881 | av_store (av, event->iv, newSVpv ((char *)event->name, 0)); |
851 | |
882 | |
852 | const struct { |
883 | static const struct { |
853 | int dtype; |
884 | int dtype; |
854 | const char *name; |
885 | const char *name; |
855 | IV idx; |
886 | IV idx; |
856 | } *cprop, prop_table[] = { |
887 | } *cprop, prop_table[] = { |
857 | # define prop(type, name) { type, # name, (IV) CFAPI_ ## name }, |
888 | # define prop(type, name) { type, # name, (IV) CFAPI_ ## name }, |
… | |
… | |
973 | prop (CFAPI_INT, OBJECT_PROP_DAM) |
1004 | prop (CFAPI_INT, OBJECT_PROP_DAM) |
974 | prop (CFAPI_STRING, OBJECT_PROP_GOD) |
1005 | prop (CFAPI_STRING, OBJECT_PROP_GOD) |
975 | prop (CFAPI_STRING, OBJECT_PROP_ARCH_NAME) |
1006 | prop (CFAPI_STRING, OBJECT_PROP_ARCH_NAME) |
976 | prop (CFAPI_INT, OBJECT_PROP_INVISIBLE) |
1007 | prop (CFAPI_INT, OBJECT_PROP_INVISIBLE) |
977 | prop (CFAPI_INT, OBJECT_PROP_FACE) |
1008 | prop (CFAPI_INT, OBJECT_PROP_FACE) |
978 | prop (CFAPI_STRING, PLAYER_PROP_IP) |
|
|
979 | prop (CFAPI_POBJECT, PLAYER_PROP_MARKED_ITEM) |
|
|
980 | prop (CFAPI_PPARTY, PLAYER_PROP_PARTY) |
|
|
981 | }; |
1009 | }; |
982 | |
1010 | |
983 | HV *prop_type = get_hv ("cf::PROP_TYPE", 1); |
1011 | HV *prop_type = get_hv ("cf::PROP_TYPE", 1); |
984 | HV *prop_idx = get_hv ("cf::PROP_IDX", 1); |
1012 | HV *prop_idx = get_hv ("cf::PROP_IDX", 1); |
985 | |
1013 | |
… | |
… | |
990 | } |
1018 | } |
991 | } |
1019 | } |
992 | |
1020 | |
993 | void |
1021 | void |
994 | LOG (int level, char *msg) |
1022 | LOG (int level, char *msg) |
|
|
1023 | PROTOTYPE: $$ |
995 | C_ARGS: level, "%s", msg |
1024 | C_ARGS: level, "%s", msg |
996 | |
1025 | |
997 | char * |
1026 | char * |
998 | cf_get_maps_directory (char *path) |
1027 | cf_get_maps_directory (char *path) |
|
|
1028 | PROTOTYPE: $ |
999 | ALIAS: maps_directory = 0 |
1029 | ALIAS: maps_directory = 0 |
1000 | |
1030 | |
1001 | char * |
1031 | char * |
1002 | mapdir () |
1032 | mapdir () |
|
|
1033 | PROTOTYPE: |
1003 | ALIAS: |
1034 | ALIAS: |
1004 | mapdir = 0 |
1035 | mapdir = 0 |
1005 | uniquedir = 1 |
1036 | uniquedir = 1 |
1006 | tmpdir = 2 |
1037 | tmpdir = 2 |
1007 | confdir = 3 |
1038 | confdir = 3 |
… | |
… | |
1011 | CODE: |
1042 | CODE: |
1012 | { |
1043 | { |
1013 | int unused_type; |
1044 | int unused_type; |
1014 | RETVAL = (char *)systemDirectory (&unused_type, ix); |
1045 | RETVAL = (char *)systemDirectory (&unused_type, ix); |
1015 | } |
1046 | } |
1016 | OUTPUT: |
1047 | OUTPUT: RETVAL |
1017 | RETVAL |
|
|
1018 | |
1048 | |
1019 | int |
1049 | int |
1020 | cf_find_animation (char *text) |
1050 | cf_find_animation (char *text) |
|
|
1051 | PROTOTYPE: $ |
1021 | |
1052 | |
1022 | MODULE = cf PACKAGE = cf::object PREFIX = cf_object_ |
1053 | MODULE = cf PACKAGE = cf::object PREFIX = cf_object_ |
1023 | |
|
|
1024 | PROTOTYPES: DISABLE |
|
|
1025 | |
1054 | |
1026 | SV * |
1055 | SV * |
1027 | get_property (object *obj, int type, int idx) |
1056 | get_property (object *obj, int type, int idx) |
1028 | CODE: |
1057 | CODE: |
1029 | RETVAL = newSVcfapi (type, cf_object_get_property (obj, idx)); |
1058 | RETVAL = newSVcfapi (type, cf_object_get_property (obj, idx)); |
1030 | OUTPUT: |
1059 | OUTPUT: RETVAL |
1031 | RETVAL |
|
|
1032 | |
1060 | |
1033 | SV * |
1061 | SV * |
1034 | set_property (object *obj, int type, int idx, SV *newval) |
1062 | set_property (object *obj, int type, int idx, SV *newval) |
1035 | CODE: |
1063 | CODE: |
1036 | switch (type) |
1064 | switch (type) |
… | |
… | |
1128 | |
1156 | |
1129 | char * |
1157 | char * |
1130 | base_name (object *ob, int plural) |
1158 | base_name (object *ob, int plural) |
1131 | CODE: |
1159 | CODE: |
1132 | RETVAL = cf_query_base_name (ob, plural); |
1160 | RETVAL = cf_query_base_name (ob, plural); |
|
|
1161 | OUTPUT: RETVAL |
|
|
1162 | |
|
|
1163 | MODULE = cf PACKAGE = cf::object PREFIX = cf_object_ |
|
|
1164 | |
|
|
1165 | object *cf_create_object_by_name (const char *name = 0) |
|
|
1166 | PROTOTYPE: ;$ |
|
|
1167 | ALIAS: |
|
|
1168 | create_object = 0 |
|
|
1169 | new = 0 |
|
|
1170 | CODE: |
|
|
1171 | RETVAL = name ? cf_create_object_by_name (name) : cf_create_object (); |
1133 | OUTPUT: |
1172 | OUTPUT: |
1134 | RETVAL |
1173 | RETVAL |
1135 | |
|
|
1136 | MODULE = cf PACKAGE = cf::object PREFIX = cf_object_ |
|
|
1137 | |
|
|
1138 | object *cf_create_object () |
|
|
1139 | ALIAS: new = 0 |
|
|
1140 | |
|
|
1141 | object *cf_create_object_by_name (const char *name) |
|
|
1142 | ALIAS: new_from_name = 0 |
|
|
1143 | |
|
|
1144 | void cf_free_object (object *ob) |
|
|
1145 | |
1174 | |
1146 | void cf_fix_object (object *pl) |
1175 | void cf_fix_object (object *pl) |
|
|
1176 | ALIAS: fix = 0 |
1147 | |
1177 | |
1148 | object *cf_insert_ob_in_ob (object *ob, object *where) |
1178 | object *cf_insert_ob_in_ob (object *ob, object *where) |
1149 | |
1179 | |
1150 | |
1180 | |
1151 | MODULE = cf PACKAGE = cf::object::player PREFIX = cf_player_ |
1181 | MODULE = cf PACKAGE = cf::object::player PREFIX = cf_player_ |
1152 | |
1182 | |
1153 | player *player (object *op) |
1183 | player *player (object *op) |
1154 | CODE: |
1184 | CODE: |
1155 | RETVAL = cf_player_find (cf_query_name (op)); |
1185 | RETVAL = cf_player_find (cf_query_name (op)); |
1156 | OUTPUT: |
1186 | OUTPUT: RETVAL |
1157 | RETVAL |
|
|
1158 | |
1187 | |
1159 | void cf_player_message (object *obj, char *txt, int flags = 0) |
1188 | void cf_player_message (object *obj, char *txt, int flags = NDI_ORANGE | NDI_UNIQUE) |
1160 | |
1189 | |
1161 | object *cf_player_send_inventory (object *op) |
1190 | object *cf_player_send_inventory (object *op) |
1162 | |
1191 | |
|
|
1192 | char *cf_player_get_ip (object *op) |
|
|
1193 | ALIAS: ip = 0 |
|
|
1194 | |
|
|
1195 | object *cf_player_get_marked_item (object *op) |
|
|
1196 | ALIAS: marked_item = 0 |
|
|
1197 | |
1163 | void cf_player_set_marked_item(object *op, object *ob) |
1198 | void cf_player_set_marked_item (object *op, object *ob) |
1164 | |
1199 | |
|
|
1200 | partylist *cf_player_get_party (object *op) |
|
|
1201 | ALIAS: party = 0 |
|
|
1202 | |
1165 | void cf_player_set_party(object *op, partylist *party) |
1203 | void cf_player_set_party (object *op, partylist *party) |
1166 | |
1204 | |
1167 | |
1205 | |
1168 | MODULE = cf PACKAGE = cf::object::map PREFIX = cf_ |
1206 | MODULE = cf PACKAGE = cf::object::map PREFIX = cf_ |
1169 | |
1207 | |
1170 | MODULE = cf PACKAGE = cf::player PREFIX = cf_ |
1208 | MODULE = cf PACKAGE = cf::player PREFIX = cf_player_ |
1171 | |
1209 | |
1172 | player *cf_player_find (char *name) |
1210 | player *cf_player_find (char *name) |
|
|
1211 | PROTOTYPE: $ |
1173 | |
1212 | |
1174 | void cf_player_move (player *pl, int dir) |
1213 | void cf_player_move (player *pl, int dir) |
1175 | |
1214 | |
|
|
1215 | # nonstandard |
|
|
1216 | object *ob (player *pl) |
|
|
1217 | CODE: |
|
|
1218 | RETVAL = pl->ob; |
|
|
1219 | OUTPUT: RETVAL |
1176 | |
1220 | |
|
|
1221 | |
1177 | MODULE = cf PACKAGE = cf::map PREFIX = cf_ |
1222 | MODULE = cf PACKAGE = cf::map PREFIX = cf_map_ |
1178 | |
1223 | |
1179 | SV * |
1224 | SV * |
1180 | get_property (mapstruct *obj, int type, int idx) |
1225 | get_property (mapstruct *obj, int type, int idx) |
1181 | CODE: |
1226 | CODE: |
1182 | RETVAL = newSVcfapi (type, cf_map_get_property (obj, idx)); |
1227 | RETVAL = newSVcfapi (type, cf_map_get_property (obj, idx)); |
1183 | OUTPUT: |
1228 | OUTPUT: RETVAL |
1184 | RETVAL |
|
|
1185 | |
1229 | |
1186 | SV * |
1230 | SV * |
1187 | set_property (mapstruct *obj, int type, int idx, SV *newval) |
1231 | set_property (mapstruct *obj, int type, int idx, SV *newval) |
1188 | CODE: |
1232 | CODE: |
1189 | switch (type) |
1233 | switch (type) |
… | |
… | |
1194 | default: |
1238 | default: |
1195 | croak ("unhandled type '%d' in set_property '%d'", type, idx); |
1239 | croak ("unhandled type '%d' in set_property '%d'", type, idx); |
1196 | } |
1240 | } |
1197 | |
1241 | |
1198 | mapstruct *cf_map_get_map (char *name) |
1242 | mapstruct *cf_map_get_map (char *name) |
|
|
1243 | PROTOTYPE: $ |
1199 | ALIAS: map = 0 |
1244 | ALIAS: map = 0 |
1200 | |
1245 | |
1201 | mapstruct *cf_map_get_first () |
1246 | mapstruct *cf_map_get_first () |
|
|
1247 | PROTOTYPE: |
1202 | ALIAS: first = 0 |
1248 | ALIAS: first = 0 |
1203 | |
1249 | |
1204 | object *cf_map_insert_object_there (mapstruct *where, object *op, object *originator, int flags) |
1250 | object *cf_map_insert_object_there (mapstruct *where, object *op, object *originator, int flags) |
1205 | |
1251 | |
1206 | object *cf_map_insert_object (mapstruct *where, object* op, int x, int y) |
1252 | object *cf_map_insert_object (mapstruct *where, object* op, int x, int y) |
… | |
… | |
1213 | |
1259 | |
1214 | |
1260 | |
1215 | MODULE = cf PACKAGE = cf::arch PREFIX = cf_archetype_ |
1261 | MODULE = cf PACKAGE = cf::arch PREFIX = cf_archetype_ |
1216 | |
1262 | |
1217 | archetype*cf_archetype_get_first() |
1263 | archetype*cf_archetype_get_first() |
|
|
1264 | PROTOTYPE: |
1218 | ALIAS: first = 0 |
1265 | ALIAS: first = 0 |
1219 | |
1266 | |
1220 | archetype *cf_archetype_get_next (archetype *arch) |
1267 | archetype *cf_archetype_get_next (archetype *arch) |
1221 | ALIAS: next = 0 |
1268 | ALIAS: next = 0 |
1222 | |
1269 | |
… | |
… | |
1229 | const char *cf_archetype_get_name (archetype *arch) |
1276 | const char *cf_archetype_get_name (archetype *arch) |
1230 | ALIAS: name = 0 |
1277 | ALIAS: name = 0 |
1231 | |
1278 | |
1232 | MODULE = cf PACKAGE = cf::party PREFIX = cf_party_ |
1279 | MODULE = cf PACKAGE = cf::party PREFIX = cf_party_ |
1233 | |
1280 | |
1234 | const char *cf_party_get_name (partylist *party) |
|
|
1235 | |
|
|
1236 | partylist *cf_party_get_first () |
1281 | partylist *cf_party_get_first () |
|
|
1282 | PROTOTYPE: |
1237 | ALIAS: first = 0 |
1283 | ALIAS: first = 0 |
1238 | |
1284 | |
1239 | partylist *cf_party_get_next (partylist *party) |
1285 | partylist *cf_party_get_next (partylist *party) |
1240 | ALIAS: next = 0 |
1286 | ALIAS: next = 0 |
1241 | |
1287 | |
|
|
1288 | const char *cf_party_get_name (partylist *party) |
|
|
1289 | |
1242 | const char *cf_party_get_password (partylist *party) |
1290 | const char *cf_party_get_password (partylist *party) |
1243 | ALIAS: password = 0 |
1291 | ALIAS: password = 0 |
1244 | |
1292 | |
1245 | player *cf_party_get_first_player (partylist *party) |
1293 | player *cf_party_get_first_player (partylist *party) |
1246 | ALIAS: first_player = 0 |
1294 | ALIAS: first_player = 0 |
… | |
… | |
1250 | |
1298 | |
1251 | |
1299 | |
1252 | MODULE = cf PACKAGE = cf::region PREFIX = cf_region_ |
1300 | MODULE = cf PACKAGE = cf::region PREFIX = cf_region_ |
1253 | |
1301 | |
1254 | region *cf_region_get_first () |
1302 | region *cf_region_get_first () |
|
|
1303 | PROTOTYPE: |
1255 | ALIAS: first = 0 |
1304 | ALIAS: first = 0 |
1256 | |
1305 | |
1257 | const char *cf_region_get_name (region *reg) |
1306 | const char *cf_region_get_name (region *reg) |
1258 | ALIAS: name = 0 |
1307 | ALIAS: name = 0 |
1259 | |
1308 | |