ViewVC Help
View File | Revision Log | Show Annotations | Download File
/cvs/deliantra/server/server/cfperl.xs
(Generate patch)

Comparing deliantra/server/server/cfperl.xs (file contents):
Revision 1.346 by root, Sat Jan 16 17:41:01 2010 UTC vs.
Revision 1.357 by root, Sun Apr 4 04:17:02 2010 UTC

1455 const_iv (MOOD_FLOOR) const_iv (EXIT) const_iv (ENCOUNTER) const_iv (SHOP_FLOOR) 1455 const_iv (MOOD_FLOOR) const_iv (EXIT) const_iv (ENCOUNTER) const_iv (SHOP_FLOOR)
1456 const_iv (SHOP_MAT) const_iv (RING) const_iv (FLOOR) const_iv (FLESH) 1456 const_iv (SHOP_MAT) const_iv (RING) const_iv (FLOOR) const_iv (FLESH)
1457 const_iv (INORGANIC) const_iv (SKILL_TOOL) const_iv (LIGHTER) const_iv (BUILDABLE_WALL) 1457 const_iv (INORGANIC) const_iv (SKILL_TOOL) const_iv (LIGHTER) const_iv (BUILDABLE_WALL)
1458 const_iv (MISC_OBJECT) const_iv (LAMP) const_iv (DUPLICATOR) const_iv (SPELLBOOK) 1458 const_iv (MISC_OBJECT) const_iv (LAMP) const_iv (DUPLICATOR) const_iv (SPELLBOOK)
1459 const_iv (CLOAK) const_iv (SPINNER) const_iv (GATE) const_iv (BUTTON) 1459 const_iv (CLOAK) const_iv (SPINNER) const_iv (GATE) const_iv (BUTTON)
1460 const_iv (T_HANDLE) const_iv (HOLE) const_iv (TRAPDOOR) const_iv (SIGN) 1460 const_iv (T_HANDLE) const_iv (HOLE) const_iv (TRAPDOOR) const_iv (SIGN)
1461 const_iv (BOOTS) const_iv (GLOVES) const_iv (SPELL) const_iv (SPELL_EFFECT) 1461 const_iv (BOOTS) const_iv (GLOVES) const_iv (SPELL) const_iv (SPELL_EFFECT)
1462 const_iv (CONVERTER) const_iv (BRACERS) const_iv (POISONING) const_iv (SAVEBED) 1462 const_iv (CONVERTER) const_iv (BRACERS) const_iv (POISONING) const_iv (SAVEBED)
1463 const_iv (WAND) const_iv (SCROLL) const_iv (DIRECTOR) const_iv (GIRDLE) 1463 const_iv (WAND) const_iv (SCROLL) const_iv (DIRECTOR) const_iv (GIRDLE)
1464 const_iv (FORCE) const_iv (POTION_EFFECT) const_iv (EVENT_CONNECTOR) const_iv (CLOSE_CON) 1464 const_iv (FORCE) const_iv (POTION_EFFECT) const_iv (EVENT_CONNECTOR) const_iv (CLOSE_CON)
1465 const_iv (CONTAINER) const_iv (ARMOUR_IMPROVER) const_iv (WEAPON_IMPROVER) const_iv (SKILLSCROLL) 1465 const_iv (CONTAINER) const_iv (ARMOUR_IMPROVER) const_iv (WEAPON_IMPROVER) const_iv (SKILLSCROLL)
1466 const_iv (DEEP_SWAMP) const_iv (IDENTIFY_ALTAR) const_iv (MENU) const_iv (RUNE) 1466 const_iv (DEEP_SWAMP) const_iv (IDENTIFY_ALTAR) const_iv (MENU) const_iv (RUNE)
1467 const_iv (TRAP) const_iv (POWER_CRYSTAL) const_iv (CORPSE) const_iv (DISEASE) 1467 const_iv (TRAP) const_iv (POWER_CRYSTAL) const_iv (CORPSE) const_iv (DISEASE)
1468 const_iv (SYMPTOM) const_iv (BUILDER) const_iv (MATERIAL) const_iv (ITEM_TRANSFORMER) 1468 const_iv (SYMPTOM) const_iv (BUILDER) const_iv (MATERIAL) const_iv (ITEM_TRANSFORMER)
1469 const_iv (MAPSCRIPT) const_iv (SAFE_GROUND) 1469 const_iv (MAPSCRIPT) const_iv (SAFE_GROUND) const_iv (VEIN)
1470 1470
1471 const_iv (NUM_TYPES) const_iv (NUM_SUBTYPES) 1471 const_iv (NUM_TYPES) const_iv (NUM_SUBTYPES)
1472 1472
1473 const_iv (ST_BD_BUILD) const_iv (ST_BD_REMOVE) 1473 const_iv (ST_BD_BUILD) const_iv (ST_BD_REMOVE)
1474 const_iv (ST_MAT_FLOOR) const_iv (ST_MAT_WALL) const_iv (ST_MAT_ITEM) 1474 const_iv (ST_MAT_FLOOR) const_iv (ST_MAT_WALL) const_iv (ST_MAT_ITEM)
1520 const_iv (NDI_NOCREATE) const_iv (NDI_CLEAR) const_iv (NDI_VERBATIM) 1520 const_iv (NDI_NOCREATE) const_iv (NDI_CLEAR) const_iv (NDI_VERBATIM)
1521 1521
1522 const_iv (UPD_LOCATION) const_iv (UPD_FLAGS) const_iv (UPD_WEIGHT) const_iv (UPD_FACE) 1522 const_iv (UPD_LOCATION) const_iv (UPD_FLAGS) const_iv (UPD_WEIGHT) const_iv (UPD_FACE)
1523 const_iv (UPD_NAME) const_iv (UPD_ANIM) const_iv (UPD_ANIMSPEED) const_iv (UPD_NROF) 1523 const_iv (UPD_NAME) const_iv (UPD_ANIM) const_iv (UPD_ANIMSPEED) const_iv (UPD_NROF)
1524 1524
1525 const_iv (UPD_SP_MANA) const_iv (UPD_SP_GRACE) const_iv (UPD_SP_DAMAGE) 1525 const_iv (UPD_SP_MANA) const_iv (UPD_SP_GRACE) const_iv (UPD_SP_LEVEL)
1526 1526
1527 const_iv (SP_RAISE_DEAD) 1527 const_iv (SP_RAISE_DEAD)
1528 const_iv (SP_RUNE) 1528 const_iv (SP_RUNE)
1529 const_iv (SP_MAKE_MARK) 1529 const_iv (SP_MAKE_MARK)
1530 const_iv (SP_BOLT) 1530 const_iv (SP_BOLT)
1571 const_iv (SP_CAUSE_DISEASE) 1571 const_iv (SP_CAUSE_DISEASE)
1572 const_iv (SP_AURA) 1572 const_iv (SP_AURA)
1573 const_iv (SP_TOWN_PORTAL) 1573 const_iv (SP_TOWN_PORTAL)
1574 const_iv (SP_PARTY_SPELL) 1574 const_iv (SP_PARTY_SPELL)
1575 1575
1576 const_iv (AP_TOGGLE) const_iv (AP_APPLY) const_iv (AP_UNAPPLY) const_iv (AP_MODE)
1577 const_iv (AP_NO_MERGE) const_iv (AP_NO_SLOT) const_iv (AP_PRINT) const_iv (AP_IGNORE_CURSE)
1578
1576 const_iv (F_APPLIED) const_iv (F_LOCATION) const_iv (F_UNPAID) const_iv (F_MAGIC) 1579 const_iv (F_APPLIED) const_iv (F_LOCATION) const_iv (F_UNPAID) const_iv (F_MAGIC)
1577 const_iv (F_CURSED) const_iv (F_DAMNED) const_iv (F_OPEN) const_iv (F_NOPICK) 1580 const_iv (F_CURSED) const_iv (F_DAMNED) const_iv (F_OPEN) const_iv (F_NOPICK)
1578 const_iv (F_LOCKED) 1581 const_iv (F_LOCKED)
1579 1582
1580 const_iv (F_BUY) const_iv (F_SHOP) const_iv (F_SELL) 1583 const_iv (F_BUY) const_iv (F_SHOP) const_iv (F_SELL)
1608 const_iv (SK_WOODSMAN) const_iv (SK_INSCRIPTION) const_iv (SK_ONE_HANDED_WEAPON) const_iv (SK_MISSILE_WEAPON) 1611 const_iv (SK_WOODSMAN) const_iv (SK_INSCRIPTION) const_iv (SK_ONE_HANDED_WEAPON) const_iv (SK_MISSILE_WEAPON)
1609 const_iv (SK_THROWING) const_iv (SK_USE_MAGIC_ITEM) const_iv (SK_DISARM_TRAPS) const_iv (SK_SET_TRAP) 1612 const_iv (SK_THROWING) const_iv (SK_USE_MAGIC_ITEM) const_iv (SK_DISARM_TRAPS) const_iv (SK_SET_TRAP)
1610 const_iv (SK_THAUMATURGY) const_iv (SK_PRAYING) const_iv (SK_CLAWING) const_iv (SK_LEVITATION) 1613 const_iv (SK_THAUMATURGY) const_iv (SK_PRAYING) const_iv (SK_CLAWING) const_iv (SK_LEVITATION)
1611 const_iv (SK_SUMMONING) const_iv (SK_PYROMANCY) const_iv (SK_EVOCATION) const_iv (SK_SORCERY) 1614 const_iv (SK_SUMMONING) const_iv (SK_PYROMANCY) const_iv (SK_EVOCATION) const_iv (SK_SORCERY)
1612 const_iv (SK_TWO_HANDED_WEAPON) const_iv (SK_SPARK_TOUCH) const_iv (SK_SHIVER) const_iv (SK_ACID_SPLASH) 1615 const_iv (SK_TWO_HANDED_WEAPON) const_iv (SK_SPARK_TOUCH) const_iv (SK_SHIVER) const_iv (SK_ACID_SPLASH)
1613 const_iv (SK_POISON_NAIL) 1616 const_iv (SK_POISON_NAIL) const_iv (SK_MINING) const_iv (SK_FISHING)
1614 1617
1615 const_iv (SOUND_NEW_PLAYER) const_iv (SOUND_FIRE_ARROW) const_iv (SOUND_LEARN_SPELL) const_iv (SOUND_FUMBLE_SPELL) 1618 const_iv (SOUND_NEW_PLAYER) const_iv (SOUND_FIRE_ARROW) const_iv (SOUND_LEARN_SPELL) const_iv (SOUND_FUMBLE_SPELL)
1616 const_iv (SOUND_WAND_POOF) const_iv (SOUND_OPEN_DOOR) const_iv (SOUND_PUSH_PLAYER) const_iv (SOUND_PLAYER_HITS1) 1619 const_iv (SOUND_WAND_POOF) const_iv (SOUND_OPEN_DOOR) const_iv (SOUND_PUSH_PLAYER) const_iv (SOUND_PLAYER_HITS1)
1617 const_iv (SOUND_PLAYER_HITS2) const_iv (SOUND_PLAYER_HITS3) const_iv (SOUND_PLAYER_HITS4) const_iv (SOUND_PLAYER_IS_HIT1) 1620 const_iv (SOUND_PLAYER_HITS2) const_iv (SOUND_PLAYER_HITS3) const_iv (SOUND_PLAYER_HITS4) const_iv (SOUND_PLAYER_IS_HIT1)
1618 const_iv (SOUND_PLAYER_IS_HIT2) const_iv (SOUND_PLAYER_IS_HIT3) const_iv (SOUND_PLAYER_KILLS) const_iv (SOUND_PET_IS_KILLED) 1621 const_iv (SOUND_PLAYER_IS_HIT2) const_iv (SOUND_PLAYER_IS_HIT3) const_iv (SOUND_PLAYER_KILLS) const_iv (SOUND_PET_IS_KILLED)
1822 } 1825 }
1823 1826
1824void server_tick () 1827void server_tick ()
1825 CODE: 1828 CODE:
1826{ 1829{
1830 ev_now_update (EV_DEFAULT);
1827 NOW = ev_now (EV_DEFAULT); 1831 NOW = ev_now (EV_DEFAULT);
1828 SvNV_set (sv_now, NOW); SvNOK_only (sv_now); 1832 SvNV_set (sv_now, NOW); SvNOK_only (sv_now);
1829 SvNV_set (sv_tick_start, NOW); SvNOK_only (sv_tick_start); 1833 SvNV_set (sv_tick_start, NOW); SvNOK_only (sv_tick_start);
1830 runtime = SvNVX (sv_runtime); 1834 runtime = SvNVX (sv_runtime);
1831 1835
1832 server_tick (); 1836 server_tick ();
1833 1837
1834 NOW = ev_time (); 1838 ev_now_update (EV_DEFAULT);
1839 NOW = ev_now (EV_DEFAULT);
1835 SvNV_set (sv_now, NOW); SvNOK_only (sv_now); 1840 SvNV_set (sv_now, NOW); SvNOK_only (sv_now);
1836 runtime += TICK; 1841 runtime += TICK;
1837 SvNV_set (sv_runtime, runtime); SvNOK_only (sv_runtime); 1842 SvNV_set (sv_runtime, runtime); SvNOK_only (sv_runtime);
1838} 1843}
1839 1844
2218 2223
2219int apply_shop_mat (object *shop_mat, object *op); 2224int apply_shop_mat (object *shop_mat, object *op);
2220 2225
2221int move (object *op, int dir, object *originator = op) 2226int move (object *op, int dir, object *originator = op)
2222 CODE: 2227 CODE:
2223 RETVAL = move_ob (op, dir, originator); 2228 RETVAL = op->move (dir, originator);
2224 OUTPUT: 2229 OUTPUT:
2225 RETVAL 2230 RETVAL
2226 2231
2227void apply (object *applier, object *applied, int flags = 0)
2228 CODE:
2229 manual_apply (applied, applier, flags);
2230
2231void apply_below (object *op) 2232void apply_below (object *op)
2232 CODE: 2233 CODE:
2233 player_apply_below (op); 2234 player_apply_below (op);
2234 2235
2235int cast_heal (object *op, object *caster, object *spell, int dir = 0) 2236int cast_heal (object *op, object *caster, object *spell, int dir = 0)
2295 2296
2296void handle_apply_yield (object *op) 2297void handle_apply_yield (object *op)
2297 2298
2298int convert_item (object *item, object *converter) 2299int convert_item (object *item, object *converter)
2299 2300
2301void fix_generated_item (object *op, object *creator, int difficulty, int max_magic, int flags);
2300 2302
2301MODULE = cf PACKAGE = cf::object PREFIX = cf_ 2303MODULE = cf PACKAGE = cf::object PREFIX = cf_
2302 2304
2303# no clean way to get an object from an archetype - stupid idiotic 2305# no clean way to get an object from an archetype - stupid idiotic
2304# dumb kludgy misdesigned plug-in api slowly gets on my nerves. 2306# dumb kludgy misdesigned plug-in api slowly gets on my nerves.
2308 CODE: 2310 CODE:
2309 RETVAL = archetype ? get_archetype (archetype) : object::create (); 2311 RETVAL = archetype ? get_archetype (archetype) : object::create ();
2310 OUTPUT: 2312 OUTPUT:
2311 RETVAL 2313 RETVAL
2312 2314
2315object *generate (utf8_string arch, object *creator)
2316 CODE:
2317 object *obj = get_archetype (arch);
2318 fix_generated_item (obj, creator, 0, 0, GT_MINIMAL);
2319 RETVAL = obj;
2320 OUTPUT:
2321 RETVAL
2322
2313object *find_object (U32 tag) 2323object *find_object (U32 tag)
2324
2325object *find_object_uuid (UUID i)
2314 2326
2315# TODO: nuke 2327# TODO: nuke
2316object *insert_ob_in_map_at (object *ob, maptile *where, object_ornull *orig, int flag, int x, int y) 2328object *insert_ob_in_map_at (object *ob, maptile *where, object_ornull *orig, int flag, int x, int y)
2317 PROTOTYPE: $$$$$$ 2329 PROTOTYPE: $$$$$$
2318 CODE: 2330 CODE:
2379 CODE: 2391 CODE:
2380 RETVAL = op->contr; 2392 RETVAL = op->contr;
2381 OUTPUT: RETVAL 2393 OUTPUT: RETVAL
2382 2394
2383bool move_player (object *op, int dir) 2395bool move_player (object *op, int dir)
2384
2385void check_score (object *op)
2386 2396
2387void message (object *op, utf8_string txt, int flags = NDI_ORANGE | NDI_UNIQUE) 2397void message (object *op, utf8_string txt, int flags = NDI_ORANGE | NDI_UNIQUE)
2388 CODE: 2398 CODE:
2389 new_draw_info (flags, 0, op, txt); 2399 new_draw_info (flags, 0, op, txt);
2390 2400
2754 utf8_string monsterstyle,\ 2764 utf8_string monsterstyle,\
2755 utf8_string treasurestyle,\ 2765 utf8_string treasurestyle,\
2756 utf8_string layoutstyle,\ 2766 utf8_string layoutstyle,\
2757 utf8_string doorstyle,\ 2767 utf8_string doorstyle,\
2758 utf8_string decorstyle,\ 2768 utf8_string decorstyle,\
2769 utf8_string miningstyle,\
2759 utf8_string origin_map,\ 2770 utf8_string origin_map,\
2760 utf8_string final_map,\ 2771 utf8_string final_map,\
2761 utf8_string exitstyle,\ 2772 utf8_string exitstyle,\
2762 utf8_string this_map,\ 2773 utf8_string this_map,\
2763 utf8_string exit_on_final_map,\ 2774 utf8_string exit_on_final_map,\
2795 assign (rmp.monsterstyle , monsterstyle); 2806 assign (rmp.monsterstyle , monsterstyle);
2796 assign (rmp.treasurestyle , treasurestyle); 2807 assign (rmp.treasurestyle , treasurestyle);
2797 assign (rmp.layoutstyle , layoutstyle); 2808 assign (rmp.layoutstyle , layoutstyle);
2798 assign (rmp.doorstyle , doorstyle); 2809 assign (rmp.doorstyle , doorstyle);
2799 assign (rmp.decorstyle , decorstyle); 2810 assign (rmp.decorstyle , decorstyle);
2811 assign (rmp.miningstyle , miningstyle);
2800 assign (rmp.exitstyle , exitstyle); 2812 assign (rmp.exitstyle , exitstyle);
2801 assign (rmp.exit_on_final_map, exit_on_final_map); 2813 assign (rmp.exit_on_final_map, exit_on_final_map);
2802 2814
2803 rmp.origin_map = origin_map; 2815 rmp.origin_map = origin_map;
2804 rmp.final_map = final_map; 2816 rmp.final_map = final_map;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines