From e9129d00278edc75a45a1d5d47345c9d9f2460c3 Mon Sep 17 00:00:00 2001 From: Jedzkie Date: Wed, 23 Dec 2015 16:02:13 +0800 Subject: Update: - Rename BLUE_CRYST and PINK_CRYST to BLUE_CRYSTAL and PINK_CRYSTAL - Rename FOOD_STOR to FOOD_STORAGE - Rename TREAS01, TREAS40, TREAS41, TREAS49 to TREASURE_01, TREASURE_40, TREASURE_41, TREASURE_49 --- src/map/battle.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/map/battle.c') diff --git a/src/map/battle.c b/src/map/battle.c index 88037b042..96289fcc8 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -3327,16 +3327,16 @@ int64 battle_calc_damage(struct block_list *src,struct block_list *bl,struct Dam * Calculates BG related damage adjustments. *------------------------------------------*/ // FIXME: flag is undocumented -int64 battle_calc_bg_damage(struct block_list *src, struct block_list *bl, int64 damage, int div_, uint16 skill_id, uint16 skill_lv, int flag) -{ - if( !damage ) +int64 battle_calc_bg_damage(struct block_list *src, struct block_list *bl, int64 damage, int div_, uint16 skill_id, uint16 skill_lv, int flag) { + + if (!damage) return 0; nullpo_retr(damage, bl); - if( bl->type == BL_MOB ) { + if (bl->type == BL_MOB) { struct mob_data* md = BL_CAST(BL_MOB, bl); - if( flag&BF_SKILL && (md->class_ == MOBID_BLUE_CRYST || md->class_ == MOBID_PINK_CRYST) ) + if (flag&BF_SKILL && (md->class_ == MOBID_BLUE_CRYSTAL || md->class_ == MOBID_PINK_CRYSTAL)) return 0; // Crystal cannot receive skill damage on battlegrounds } -- cgit v1.2.3-70-g09d2