From 1d0e18a186f67844ccd873eabb56ebdaa3f47f11 Mon Sep 17 00:00:00 2001 From: Ben Longbons Date: Sat, 25 May 2013 13:49:50 -0700 Subject: Switch block_list and subclasses to dumb_ptr Now we're well-defined, since we're actually calling ctors and dtors. Most of this code will not survive long ... --- src/map/battle.hpp | 82 +++++++++++++++++++++++++++--------------------------- 1 file changed, 41 insertions(+), 41 deletions(-) (limited to 'src/map/battle.hpp') diff --git a/src/map/battle.hpp b/src/map/battle.hpp index 6d9d8dd..8b7c1bd 100644 --- a/src/map/battle.hpp +++ b/src/map/battle.hpp @@ -27,66 +27,66 @@ struct block_list; // ダメージ計算 struct Damage battle_calc_attack(BF attack_type, - struct block_list *bl, struct block_list *target, + dumb_ptr bl, dumb_ptr target, SkillID skill_num, int skill_lv, int flag); // 実際にHPを増減 -int battle_damage(struct block_list *bl, struct block_list *target, +int battle_damage(dumb_ptr bl, dumb_ptr target, int damage, int flag); -int battle_heal(struct block_list *bl, struct block_list *target, int hp, +int battle_heal(dumb_ptr bl, dumb_ptr target, int hp, int sp, int flag); // 攻撃や移動を止める -int battle_stopattack(struct block_list *bl); -int battle_stopwalking(struct block_list *bl, int type); +int battle_stopattack(dumb_ptr bl); +int battle_stopwalking(dumb_ptr bl, int type); // 通常攻撃処理まとめ -ATK battle_weapon_attack(struct block_list *bl, struct block_list *target, +ATK battle_weapon_attack(dumb_ptr bl, dumb_ptr target, tick_t tick); -int battle_is_unarmed(struct block_list *bl); -int battle_get_class(struct block_list *bl); -DIR battle_get_dir(struct block_list *bl); -int battle_get_lv(struct block_list *bl); -int battle_get_range(struct block_list *bl); -int battle_get_hp(struct block_list *bl); -int battle_get_max_hp(struct block_list *bl); -int battle_get_str(struct block_list *bl); -int battle_get_agi(struct block_list *bl); -int battle_get_vit(struct block_list *bl); -int battle_get_int(struct block_list *bl); -int battle_get_dex(struct block_list *bl); -int battle_get_luk(struct block_list *bl); -int battle_get_def(struct block_list *bl); -int battle_get_mdef(struct block_list *bl); -int battle_get_def2(struct block_list *bl); -int battle_get_mdef2(struct block_list *bl); -interval_t battle_get_speed(struct block_list *bl); -interval_t battle_get_adelay(struct block_list *bl); -interval_t battle_get_amotion(struct block_list *bl); -interval_t battle_get_dmotion(struct block_list *bl); -LevelElement battle_get_element(struct block_list *bl); +int battle_is_unarmed(dumb_ptr bl); +int battle_get_class(dumb_ptr bl); +DIR battle_get_dir(dumb_ptr bl); +int battle_get_lv(dumb_ptr bl); +int battle_get_range(dumb_ptr bl); +int battle_get_hp(dumb_ptr bl); +int battle_get_max_hp(dumb_ptr bl); +int battle_get_str(dumb_ptr bl); +int battle_get_agi(dumb_ptr bl); +int battle_get_vit(dumb_ptr bl); +int battle_get_int(dumb_ptr bl); +int battle_get_dex(dumb_ptr bl); +int battle_get_luk(dumb_ptr bl); +int battle_get_def(dumb_ptr bl); +int battle_get_mdef(dumb_ptr bl); +int battle_get_def2(dumb_ptr bl); +int battle_get_mdef2(dumb_ptr bl); +interval_t battle_get_speed(dumb_ptr bl); +interval_t battle_get_adelay(dumb_ptr bl); +interval_t battle_get_amotion(dumb_ptr bl); +interval_t battle_get_dmotion(dumb_ptr bl); +LevelElement battle_get_element(dumb_ptr bl); inline -Element battle_get_elem_type(struct block_list *bl) +Element battle_get_elem_type(dumb_ptr bl) { return battle_get_element(bl).element; } -int battle_get_party_id(struct block_list *bl); -Race battle_get_race(struct block_list *bl); -MobMode battle_get_mode(struct block_list *bl); -int battle_get_stat(SP stat_id, struct block_list *bl); +int battle_get_party_id(dumb_ptr bl); +Race battle_get_race(dumb_ptr bl); +MobMode battle_get_mode(dumb_ptr bl); +int battle_get_stat(SP stat_id, dumb_ptr bl); -eptr battle_get_sc_data(struct block_list *bl); -short *battle_get_sc_count(struct block_list *bl); -Opt1 *battle_get_opt1(struct block_list *bl); -Opt2 *battle_get_opt2(struct block_list *bl); -Opt3 *battle_get_opt3(struct block_list *bl); -Option *battle_get_option(struct block_list *bl); +eptr battle_get_sc_data(dumb_ptr bl); +short *battle_get_sc_count(dumb_ptr bl); +Opt1 *battle_get_opt1(dumb_ptr bl); +Opt2 *battle_get_opt2(dumb_ptr bl); +Opt3 *battle_get_opt3(dumb_ptr bl); +Option *battle_get_option(dumb_ptr bl); bool battle_check_undead(Race race, Element element); -int battle_check_target(struct block_list *src, struct block_list *target, +int battle_check_target(dumb_ptr src, dumb_ptr target, BCT flag); -int battle_check_range(struct block_list *src, struct block_list *bl, +int battle_check_range(dumb_ptr src, dumb_ptr bl, int range); extern struct Battle_Config -- cgit v1.2.3-60-g2f50