Go to the documentation of this file.
33 #define EXISTCHECK(ob) { \
34 if (!ob || !ob->obj || (object_was_destroyed(ob->obj, ob->obj->count))) { \
35 PyErr_SetString(PyExc_ReferenceError, "Crossfire object no longer exists"); \
44 #define TYPEEXISTCHECK(ob) { \
45 if (!ob || !PyObject_TypeCheck((PyObject*)ob, &Crossfire_ObjectType) || !ob->obj || (object_was_destroyed(ob->obj, ob->obj->count))) { \
46 PyErr_SetString(PyExc_ReferenceError, "Not a Crossfire object or Crossfire object no longer exists"); \
50 #define EXISTCHECK_INT(ob) { \
51 if (!ob || !ob->obj || (object_was_destroyed(ob->obj, ob->obj->count))) { \
52 PyErr_SetString(PyExc_ReferenceError, "Crossfire object no longer exists"); \
85 PyErr_SetString(PyExc_TypeError,
"Cannot delete the Title attribute");
89 PyErr_SetString(PyExc_TypeError,
"The Title attribute must be a string");
92 if (!PyArg_Parse(
value,
"s", &val))
116 if (
value == Py_None)
214 if (!PyArg_Parse(
value,
"i", &
x))
231 if (!PyArg_Parse(
value,
"i", &
y))
243 if (!PyArg_ParseTuple(
args,
"si", &code, &
state))
260 if (!PyArg_ParseTuple(
args,
"s", &code))
267 return Py_BuildValue(
"i",
state);
276 if (!PyArg_ParseTuple(
args,
"si", &code, &
state))
293 if (!PyArg_ParseTuple(
args,
"s", &code))
300 return Py_BuildValue(
"i", completed);
467 PyErr_SetString(PyExc_TypeError,
"Cannot delete the attribute");
471 PyErr_SetString(PyExc_TypeError,
"The attribute must be a string");
474 if (!PyArg_Parse(
value,
"s", &val))
485 if (!PyArg_Parse(
value,
"i", &val))
496 if (!PyArg_Parse(
value,
"f", &val))
507 if (!PyArg_Parse(
value,
"i", &val))
520 PyErr_SetString(PyExc_TypeError,
"Cannot delete the Name attribute");
524 PyErr_SetString(PyExc_TypeError,
"The Name attribute must be a string");
527 if (!PyArg_Parse(
value,
"s", &val))
541 PyErr_SetString(PyExc_TypeError,
"Cannot delete the NamePl attribute");
545 PyErr_SetString(PyExc_TypeError,
"The NamePl attribute must be a string");
548 if (!PyArg_Parse(
value,
"s", &val))
560 if (!PyArg_Parse(
value,
"i", &val))
584 if (!PyArg_Parse(
value,
"i", &val))
588 PyErr_SetString(PyExc_TypeError,
"Invalid quantity");
601 if (!PyArg_Parse(
value,
"s", &face))
605 PyErr_SetString(PyExc_TypeError,
"Unknown face.");
620 PyErr_SetString(PyExc_TypeError,
"Unknown animation.");
632 if (!PyArg_Parse(
value,
"l", &val))
666 if (!PyArg_Parse(
value,
"L", &val))
678 if (!PyArg_Parse(
value,
"B", &move))
689 if (!PyArg_Parse(
value,
"B", &move))
700 if (!PyArg_Parse(
value,
"B", &move))
711 if (!PyArg_Parse(
value,
"B", &move))
722 if (!PyArg_Parse(
value,
"B", &move))
733 if (!PyArg_Parse(
value,
"B", &move))
785 if (!PyArg_ParseTuple(
args,
"i", &clone_type))
788 if (clone_type != 0 && clone_type != 1)
790 PyErr_SetString(PyExc_ValueError,
"Clone type must be 0 (object_create_clone) or 1 (object_copy).");
798 PyErr_SetString(PyExc_RuntimeError,
"Clone failed.");
812 if (!PyArg_ParseTuple(
args,
"i", &
count))
819 PyErr_SetString(PyExc_ValueError, err);
856 return Py_BuildValue(
"i", val);
887 return Py_BuildValue(
"i",
result);
905 PyErr_SetString(PyExc_ValueError,
"too many NPCs");
910 cf_log(
llevError,
"warning, too long message in npcSay, will be truncated");
926 if (!PyArg_ParseTuple(
args,
"ii", &
x, &
y))
946 if (!PyArg_ParseTuple(
args,
"i", &resist))
949 return Py_BuildValue(
"l", 0);
958 if (!PyArg_ParseTuple(
args,
"ii", &resist, &
value))
1012 if (!PyArg_ParseTuple(
args,
"s", &spellname))
1042 if (!PyArg_ParseTuple(
args,
"L", &to_pay))
1047 return Py_BuildValue(
"i", val);
1060 return Py_BuildValue(
"i", val);
1068 if (!PyArg_ParseTuple(
args,
"s", &keyname))
1073 return Py_BuildValue(
"s", val ? val :
"");
1082 if (!PyArg_ParseTuple(
args,
"sz|i", &keyname, &
value, &add_key))
1093 if (!PyArg_ParseTuple(
args,
"li", &delay, &mode))
1104 if (!PyArg_ParseTuple(
args,
"s", &whatstr))
1127 if (!PyArg_ParseTuple(
args,
"s", &whatstr))
1138 if (!PyArg_ParseTuple(
args,
"ii", &
x, &
y))
1149 if (!PyArg_ParseTuple(
args,
"s", &txt))
1190 const char *skill = NULL;
1193 if (!PyArg_ParseTuple(
args,
"L|si", &exp, &skill, &arg))
1210 if (!PyArg_ParseTuple(
args,
"i", &dir))
1219 if (!PyArg_ParseTuple(
args,
"ii", &
x, &
y))
1248 if (!PyArg_ParseTuple(
args,
"i", &
level))
1264 return (left->
obj < right->
obj ? -1 : (left->
obj == right->
obj ? 0 : 1));
1273 Py_INCREF(Py_NotImplemented);
1274 return Py_NotImplemented;
1278 if (
result == -1 && PyErr_Occurred())
1301 return PyBool_FromLong(
result);
1444 { NULL, NULL, NULL, NULL, NULL }
1487 { NULL, NULL, 0, NULL }
1503 return (PyObject *)
self;
1514 Py_TYPE(
self)->tp_free(
obj);
1529 return (PyObject *)
self;
1540 Py_TYPE(
self)->tp_free(
obj);
1554 PyObject_HashNotImplemented,
1555 Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE,
1556 "Crossfire objects",
1573 { NULL, NULL, NULL, NULL, NULL }
1586 { NULL, NULL, 0, NULL }
1621 if (plwrap != NULL) {
1625 pyobj = (PyObject *)plwrap;
1628 if (wrapper != NULL) {
1629 wrapper->
obj = what;
1632 pyobj = (PyObject *)wrapper;
#define object_was_destroyed(op, old_tag)
static PyObject * Player_GetObjectProperty(Crossfire_Player *whoptr, void *closure)
static int Object_SetMoveOn(Crossfire_Object *whoptr, PyObject *value, void *closure)
#define CFAPI_OBJECT_PROP_TITLE
static PyGetSetDef Player_getseters[]
void cf_log(LogLevel logLevel, const char *format,...)
static PyObject * Crossfire_Object_Drop(Crossfire_Object *who, PyObject *args)
static PyObject * Crossfire_Object_CastAbility(Crossfire_Object *who, PyObject *args)
sstring cf_query_name_pl(object *ob)
static PyObject * Crossfire_Object_Move(Crossfire_Object *who, PyObject *args)
#define CFAPI_OBJECT_PROP_X
static PyObject * Crossfire_Object_Teleport(Crossfire_Object *who, PyObject *args)
object * cf_object_check_for_spell(object *op, const char *name)
PyObject_HEAD object * obj
static PyObject * Crossfire_Object_CheckTrigger(Crossfire_Object *who, PyObject *args)
sstring cf_add_string(const char *str)
static PyObject * Crossfire_Object_ForgetSpell(Crossfire_Object *who, PyObject *args)
static PyObject * Object_GetExpMul(Crossfire_Object *whoptr, void *closure)
#define CFAPI_OBJECT_PROP_CHA
#define CFAPI_OBJECT_PROP_ARCH_NAME
static PyObject * Crossfire_Object_WriteKey(Crossfire_Object *who, PyObject *args)
#define CFAPI_OBJECT_PROP_ATTACK_MOVEMENT
void cf_player_set_marked_item(object *op, object *ob)
int cf_object_teleport(object *ob, mapstruct *map, int x, int y)
int cf_object_out_of_map(object *op, int x, int y)
static PyObject * Object_GetNamePl(Crossfire_Object *whoptr, void *closure)
char * cf_object_get_string_property(object *op, int propcode, char *buf, int size)
long cf_object_get_long_property(object *op, long propcode)
#define CFAPI_OBJECT_PROP_LEVEL
static PyObject * Object_GetMoveAllow(Crossfire_Object *whoptr, void *closure)
#define CFAPI_PLAYER_PROP_BED_X
static PyObject * Object_GetFlagProperty(Crossfire_Object *whoptr, void *closure)
sstring cf_object_get_sstring_property(object *op, int propcode)
int cf_player_knowledge_has(object *op, const char *knowledge)
static void add_object_assoc(object *key, PyObject *value)
static int Player_SetParty(Crossfire_Player *whoptr, PyObject *value, void *closure)
static int Object_SetName(Crossfire_Object *whoptr, PyObject *value, void *closure)
#define FLAG_REFL_MISSILE
static int Object_SetMap(Crossfire_Object *whoptr, PyObject *value, void *closure)
object * cf_object_get_object_property(object *op, int propcode)
static int Crossfire_Object_InternalCompare(Crossfire_Object *left, Crossfire_Object *right)
static int Object_SetMoveSlow(Crossfire_Object *whoptr, PyObject *value, void *closure)
int cf_object_cast_spell(object *op, object *caster, int dir, object *spell_ob, char *stringarg)
void cf_fix_object(object *op)
static PyObject * Crossfire_Object_CreateTimer(Crossfire_Object *who, PyObject *args)
static PyObject * Crossfire_Object_KnowSpell(Crossfire_Object *who, PyObject *args)
#define TYPEEXISTCHECK(ob)
#define CFAPI_OBJECT_PROP_SLAYING
#define CFAPI_OBJECT_PROP_FRIENDLY
#define CFAPI_OBJECT_PROP_DEX
void cf_player_knowledge_give(object *op, const char *knowledge)
#define CFAPI_OBJECT_PROP_ARCHETYPE
static PyObject * Player_GetIP(Crossfire_Player *whoptr, void *closure)
static PyObject * Crossfire_Object_CreateInside(Crossfire_Object *who, PyObject *args)
static PyObject * Player_KnowledgeKnown(Crossfire_Player *who, PyObject *args)
static int Object_SetPickable(Crossfire_Object *whoptr, PyObject *value, void *closure)
object * cf_create_object_by_name(const char *name)
#define CFAPI_OBJECT_PROP_LAST_EAT
#define CFAPI_OBJECT_PROP_MOVE_ON
static PyObject * Crossfire_Object_AddExp(Crossfire_Object *who, PyObject *args)
#define CFAPI_OBJECT_PROP_STR
#define CFAPI_OBJECT_PROP_GOD
static PyObject * Crossfire_Player_CanPay(Crossfire_Player *who, PyObject *args)
char * cf_query_name(object *ob, char *name, int size)
void cf_object_set_float_property(object *op, int propcode, float value)
static PyObject * Crossfire_Object_InsertInto(Crossfire_Object *who, PyObject *args)
static int Object_SetOwner(Crossfire_Object *whoptr, PyObject *value, void *closure)
#define FLAG_SEE_INVISIBLE
int cf_object_apply(object *op, object *author, int flags)
knowledge
DIALOGCHECK MINARGS 1 MAXARGS 1
#define CFAPI_OBJECT_PROP_MAXSP
#define CFAPI_OBJECT_PROP_RAW_NAME
static PyObject * Crossfire_Object_Event(Crossfire_Object *who, PyObject *args)
static int Object_SetFace(Crossfire_Object *whoptr, PyObject *value, void *closure)
static PyMethodDef PlayerMethods[]
int64_t cf_object_get_int64_property(object *op, int propcode)
int cf_object_move_to(object *op, int x, int y)
PyObject * Crossfire_Party_wrap(partylist *what)
void cf_object_free_drop_inventory(object *ob)
#define CFAPI_OBJECT_PROP_Y
static const flag_definition flags[]
#define CFAPI_OBJECT_PROP_ENEMY
int cf_player_can_pay(object *op)
#define CFAPI_OBJECT_PROP_MOVE_TYPE
void cf_object_set_string_property(object *op, int propcode, const char *value)
int64_t cf_object_perm_exp(object *op)
#define CFAPI_OBJECT_PROP_FACE
#define CFAPI_OBJECT_PROP_ENVIRONMENT
void cf_quest_set_player_state(object *pl, sstring quest_code, int state)
static PyObject * Player_GetParty(Crossfire_Player *whoptr, void *closure)
int cf_player_arrest(object *who)
static PyObject * Crossfire_Object_SetResist(Crossfire_Object *who, PyObject *args)
static PyObject * Crossfire_Object_Remove(Crossfire_Object *who, PyObject *args)
static PyObject * Object_GetTotalExp(Crossfire_Object *whoptr, void *closure)
#define CFAPI_OBJECT_PROP_ITEM_POWER
#define CFAPI_OBJECT_PROP_CURRENT_WEAPON
CFPContext * current_context
static int Player_SetTitle(Crossfire_Object *whoptr, PyObject *value, void *closure)
void cf_player_set_title(object *op, const char *title)
void cf_spring_trap(object *trap, object *victim)
static PyObject * Crossfire_Object_Pay(Crossfire_Object *who, PyObject *args)
static PyObject * Object_GetMoveOn(Crossfire_Object *whoptr, void *closure)
int cf_object_pay_amount(object *pl, uint64_t to_pay)
#define CFAPI_OBJECT_PROP_INVISIBLE
PyObject * Crossfire_Object_wrap(object *what)
static PyObject * Object_GetMap(Crossfire_Object *whoptr, void *closure)
int cf_object_change_abil(object *op, object *tmp)
int cf_object_set_key(object *op, const char *keyname, const char *value, int add_key)
static int Object_SetFloatProperty(Crossfire_Object *whoptr, PyObject *value, void *closure)
static int Player_SetMarkedItem(Crossfire_Player *whoptr, PyObject *value, void *closure)
#define CFAPI_OBJECT_PROP_SKILL
static PyObject * Crossfire_Object_CheckInventory(Crossfire_Object *who, PyObject *args)
PyObject_HEAD object * obj
static PyObject * Player_QuestSetState(Crossfire_Player *whoptr, PyObject *args)
void cf_quest_start(object *pl, sstring quest_code, int state)
PyTypeObject Crossfire_PlayerType
static int Object_SetValue(Crossfire_Object *whoptr, PyObject *value, void *closure)
#define CFAPI_OBJECT_PROP_ANIM_SPEED
static event_registration m
#define CFAPI_OBJECT_PROP_AC
int cf_object_set_animation(object *op, const char *animation)
#define CFAPI_OBJECT_PROP_MOVE_OFF
void cf_log_plain(LogLevel logLevel, const char *message)
PyObject_HEAD mapstruct * map
#define CF_IS_PYSTR(cfpy_obj)
#define CFAPI_OBJECT_PROP_HP
#define CFAPI_OBJECT_PROP_MAXHP
partylist * cf_player_get_party(object *op)
void cf_object_say(object *op, const char *msg)
static PyObject * Player_QuestWasCompleted(Crossfire_Player *whoptr, PyObject *args)
#define CFAPI_OBJECT_PROP_OB_BELOW
int cf_timer_create(object *ob, long delay, int mode)
#define CFAPI_OBJECT_PROP_TOTAL_EXP
static PyObject * Object_GetFloatProperty(Crossfire_Object *whoptr, void *closure)
static PyObject * Object_GetExp(Crossfire_Object *whoptr, void *closure)
#define CFAPI_PLAYER_PROP_BED_Y
static int Player_SetBedY(Crossfire_Player *whoptr, PyObject *value, void *closure)
void cf_object_set_int64_property(object *op, int propcode, int64_t value)
static PyObject * Crossfire_Object_QueryName(Crossfire_Object *who, PyObject *args)
#define FLAG_KNOWN_CURSED
static PyObject * Crossfire_Object_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
#define CFAPI_OBJECT_PROP_RACE
#define CFAPI_OBJECT_PROP_MOVE_BLOCK
#define CFAPI_OBJECT_PROP_FACING
static int Player_SetBedX(Crossfire_Player *whoptr, PyObject *value, void *closure)
#define CFAPI_OBJECT_PROP_WEIGHT
static PyMethodDef ObjectMethods[]
static PyObject * Player_GetBedX(Crossfire_Player *whoptr, void *closure)
MoveType cf_object_get_movetype_property(object *op, int propcode)
object * cf_object_find_by_arch_name(const object *who, const char *name)
mapstruct * cf_object_get_map_property(object *op, int propcode)
#define CFAPI_OBJECT_PROP_DAM
int cf_object_query_money(const object *op)
static PyObject * Crossfire_Object_Clone(Crossfire_Object *who, PyObject *args)
static PyObject * Crossfire_Object_Say(Crossfire_Object *who, PyObject *args)
static PyObject * Object_GetValue(Crossfire_Object *whoptr, void *closure)
static int Object_SetAnim(Crossfire_Object *whoptr, PyObject *value, void *closure)
static PyObject * Object_GetPickable(Crossfire_Object *whoptr, void *closure)
static PyObject * Crossfire_Object_RemoveDepletion(Crossfire_Object *who, PyObject *args)
static PyObject * Object_GetMoveOff(Crossfire_Object *whoptr, void *closure)
object * cf_object_clone(object *op, int clonetype)
static PyObject * Player_GetTitle(Crossfire_Object *whoptr, void *closure)
CF_PYTHON_OBJECT(Object, Crossfire_Object_dealloc, &ObjectConvert, PyObject_HashNotImplemented, Py_TPFLAGS_DEFAULT|Py_TPFLAGS_BASETYPE, "Crossfire objects",(richcmpfunc) Crossfire_Object_RichCompare, ObjectMethods, Object_getseters, NULL, Crossfire_Object_new)
#define CFAPI_OBJECT_PROP_EXP
#define CFAPI_OBJECT_PROP_SPEED
#define CFAPI_OBJECT_PROP_TYPE
#define CFAPI_OBJECT_PROP_NROF
static void free_object_assoc(object *key)
double cf_object_get_double_property(object *op, int propcode)
PyObject * Crossfire_Archetype_wrap(archetype *what)
static int Object_SetMoveType(Crossfire_Object *whoptr, PyObject *value, void *closure)
def trigger(ob, con, pol=1, delay=5)
static PyObject * Crossfire_Object_RichCompare(Crossfire_Object *left, Crossfire_Object *right, int op)
static int Object_SetMoveBlock(Crossfire_Object *whoptr, PyObject *value, void *closure)
#define FLAG_UNAGGRESSIVE
static int Object_SetExp(Crossfire_Object *whoptr, PyObject *value, void *closure)
#define CFAPI_OBJECT_PROP_ATTACK_TYPE
static PyObject * Object_GetMaterial(Crossfire_Object *whoptr, void *closure)
#define FLAG_CAN_USE_SKILL
int cf_object_get_flag(object *ob, int flag)
static PyObject * Crossfire_Object_GetOutOfMap(Crossfire_Object *who, PyObject *args)
#define CFAPI_OBJECT_PROP_OWNER
void cf_object_drop(object *op, object *author)
int cf_object_transfer(object *op, int x, int y, int randomly, object *originator)
void cf_object_set_movetype_property(object *op, int propcode, MoveType value)
#define CFAPI_OBJECT_PROP_NAME_PLURAL
static PyObject * Crossfire_Object_Apply(Crossfire_Object *who, PyObject *args)
static std::map< object *, PyObject * > object_assoc_table
void cf_free_string(sstring str)
object * cf_object_present_archname_inside(object *op, char *whatstr)
#define CFAPI_OBJECT_PROP_WIS
void cf_object_pickup(object *op, object *what)
#define CFAPI_OBJECT_PROP_POW
archetype * cf_object_get_archetype_property(object *op, int propcode)
static PyObject * Object_GetMoveSlow(Crossfire_Object *whoptr, void *closure)
object * cf_player_get_marked_item(object *op)
#define CFAPI_OBJECT_PROP_CONTAINER
#define FLAG_KNOWN_MAGICAL
static PyObject * Crossfire_Object_Fix(Crossfire_Object *who, PyObject *args)
object * cf_object_insert_in_ob(object *op, object *where)
#define CFAPI_OBJECT_PROP_INVENTORY
#define CFAPI_OBJECT_PROP_MAP
int cf_object_user_event(object *op, object *activator, object *third, const char *message, int fix)
int cf_object_move(object *op, int dir, object *originator)
static PyObject * Crossfire_Object_PayAmount(Crossfire_Object *who, PyObject *args)
static PyObject * Crossfire_Object_ChangeAbil(Crossfire_Object *who, PyObject *args)
object * cf_object_split(object *orig_ob, uint32_t nr, char *err, size_t size)
void cf_player_set_party(object *op, partylist *party)
#define CFAPI_PLAYER_PROP_TRANSPORT
static PyObject * Crossfire_Object_GetResist(Crossfire_Object *who, PyObject *args)
static PyObject * Crossfire_Object_ReadKey(Crossfire_Object *who, PyObject *args)
PyTypeObject Crossfire_PartyType
#define CFAPI_OBJECT_PROP_ANIMATION
#define CFAPI_OBJECT_PROP_INT
#define CFAPI_OBJECT_PROP_SP
static int Object_SetMoveOff(Crossfire_Object *whoptr, PyObject *value, void *closure)
static PyObject * Object_GetOtherArchetype(Crossfire_Object *whoptr, void *closure)
#define CFAPI_OBJECT_PROP_NAME
#define CFAPI_OBJECT_PROP_EXP_MULTIPLIER
static PyObject * Crossfire_Object_LearnSpell(Crossfire_Object *who, PyObject *args)
void cf_object_set_flag(object *ob, int flag, int value)
static PyObject * Object_GetMoveBlock(Crossfire_Object *whoptr, void *closure)
const typedef char * sstring
static PyObject * Crossfire_Object_CheckArchInventory(Crossfire_Object *who, PyObject *args)
static PyObject * Player_GetMarkedItem(Crossfire_Player *whoptr, void *closure)
static PyObject * Player_GetBedMap(Crossfire_Player *whoptr, void *closure)
#define CFAPI_PLAYER_PROP_BED_MAP
int cf_object_set_nrof(object *, int nrof)
#define CFAPI_OBJECT_PROP_WC
#define CFAPI_OBJECT_PROP_GLOW_RADIUS
static PyObject * Player_QuestStart(Crossfire_Player *whoptr, PyObject *args)
int cf_object_check_trigger(object *op, object *cause)
static PyObject * Player_GetBedY(Crossfire_Player *whoptr, void *closure)
CF_PYTHON_NUMBER_METHODS(Object, Crossfire_Object_Long)
#define CFAPI_OBJECT_PROP_CON
int cf_quest_get_player_state(object *pl, sstring quest_code)
static PyObject * find_assoc_pyobject(object *key)
void cf_object_set_long_property(object *op, int propcode, long value)
static PyObject * Object_GetMoveType(Crossfire_Object *whoptr, void *closure)
static int Object_SetFlagProperty(Crossfire_Object *whoptr, PyObject *value, void *closure)
#define FLAG_BEEN_APPLIED
const char * cf_object_get_key(object *op, const char *keyname)
#define CFAPI_OBJECT_PROP_GP
static void Crossfire_Object_dealloc(PyObject *obj)
#define CFAPI_OBJECT_PROP_LAST_SP
static PyGetSetDef Object_getseters[]
#define CFAPI_OBJECT_PROP_MATERIAL
#define CFAPI_OBJECT_PROP_DURATION
#define CFAPI_OBJECT_PROP_OTHER_ARCH
static PyObject * Object_GetIntProperty(Crossfire_Object *whoptr, void *closure)
#define CFAPI_OBJECT_PROP_OB_ABOVE
static PyObject * Crossfire_Object_MoveTo(Crossfire_Object *who, PyObject *args)
static PyObject * Crossfire_Object_Reposition(Crossfire_Object *who, PyObject *args)
#define EXISTCHECK_INT(ob)
sstring npc_msgs[MAX_NPC]
#define CFAPI_OBJECT_PROP_MOVE_ALLOW
static PyObject * Crossfire_Object_Long(PyObject *obj)
static int Object_SetStringProperty(Crossfire_Object *whoptr, PyObject *value, void *closure)
static int Object_SetIntProperty(Crossfire_Object *whoptr, PyObject *value, void *closure)
char * cf_player_get_title(object *op, char *title, int size)
static int Player_SetBedMap(Crossfire_Player *whoptr, PyObject *value, void *closure)
static PyObject * Object_GetMoney(Crossfire_Object *whoptr, void *closure)
static int Object_SetMoveAllow(Crossfire_Object *whoptr, PyObject *value, void *closure)
static PyObject * Crossfire_Object_Split(Crossfire_Object *who, PyObject *args)
int cf_object_set_face(object *op, const char *face)
#define CFAPI_OBJECT_PROP_MOVE_SLOW
static PyObject * Player_QuestGetState(Crossfire_Player *whoptr, PyObject *args)
void cf_player_message(object *op, const char *txt, int flags)
static PyObject * Object_GetArchetype(Crossfire_Object *whoptr, void *closure)
static PyObject * Player_GiveKnowledge(Crossfire_Player *who, PyObject *args)
object * cf_object_change_map(object *op, mapstruct *m, object *originator, int flag, int x, int y)
#define CFAPI_OBJECT_PROP_LUCK
void cf_object_forget_spell(object *op, object *sp)
int cf_object_pay_item(object *op, object *pl)
object * cf_object_insert_object(object *op, object *container)
int16_t cf_object_get_resistance(object *op, int rtype)
void cf_object_set_int_property(object *op, int propcode, int value)
static PyObject * Crossfire_Object_Cast(Crossfire_Object *who, PyObject *args)
static int Object_SetEnemy(Crossfire_Object *whoptr, PyObject *value, void *closure)
static std::vector< std::string > split(const std::string &field, const std::string &by)
#define CFAPI_OBJECT_PROP_VALUE
#define CFAPI_OBJECT_PROP_MESSAGE
#define CFAPI_OBJECT_PROP_MOVE_SLOW_PENALTY
static PyObject * Crossfire_Object_ActivateRune(Crossfire_Object *who, PyObject *args)
#define CFAPI_OBJECT_PROP_MAXGP
#define CFAPI_OBJECT_PROP_COUNT
static void Crossfire_Player_dealloc(PyObject *obj)
static PyObject * Object_GetExists(Crossfire_Object *whoptr, void *closure)
#define CFAPI_OBJECT_PROP_SUBTYPE
void cf_object_remove(object *op)
static PyObject * Crossfire_Object_Arrest(Crossfire_Object *who, PyObject *args)
void cf_object_change_exp(object *op, int64_t exp, const char *skill_name, int flag)
static int Object_SetNamePl(Crossfire_Object *whoptr, PyObject *value, void *closure)
static int Object_SetQuantity(Crossfire_Object *whoptr, PyObject *value, void *closure)
static PyObject * Crossfire_Object_PermExp(Crossfire_Object *who, PyObject *args)
static PyObject * Object_GetSStringProperty(Crossfire_Object *whoptr, void *closure)
static PyObject * Crossfire_Object_Take(Crossfire_Object *who, PyObject *args)
sstring cf_player_get_ip(object *op)
PyObject * Crossfire_Map_wrap(mapstruct *what)
#define CFAPI_OBJECT_PROP_FP
static PyObject * Crossfire_Player_new(PyTypeObject *type, PyObject *args, PyObject *kwds)
void cf_object_set_object_property(object *op, int propcode, object *value)
PyTypeObject Crossfire_ObjectType
#define CFAPI_OBJECT_PROP_LAST_GRACE
void cf_object_learn_spell(object *op, object *spell, int special_prayer)
static PyObject * Crossfire_Player_Message(Crossfire_Player *who, PyObject *args)
int cf_object_get_int_property(object *op, int propcode)
int cf_quest_was_completed(object *pl, sstring quest_code)
static PyObject * Object_GetObjectProperty(Crossfire_Object *whoptr, void *closure)
float cf_object_get_float_property(object *op, int propcode)
#define CFAPI_OBJECT_PROP_DIRECTION
void cf_object_set_resistance(object *op, int rtype, int16_t value)
static PyObject * Object_GetName(Crossfire_Object *whoptr, void *closure)
int cf_object_remove_depletion(object *op, int level)
#define CFAPI_OBJECT_PROP_MATERIAL_NAME
#define CFAPI_OBJECT_PROP_WEIGHT_LIMIT
#define CFAPI_OBJECT_PROP_SPEED_LEFT
PyTypeObject Crossfire_MapType