summaryrefslogtreecommitdiff
path: root/src/map/skill.c
diff options
context:
space:
mode:
authorHaru <haru@dotalux.com>2015-05-19 02:33:27 +0200
committerHaru <haru@dotalux.com>2015-05-19 03:07:38 +0200
commit0c1ce8e1c427d665c207512a0e858872ef80672d (patch)
tree9e5a29d39875fe0cf74d93400b2a815fa92c3733 /src/map/skill.c
parent46c6e66222cc3aaf1b1ea08794a6b818d7065b67 (diff)
downloadhercules-0c1ce8e1c427d665c207512a0e858872ef80672d.tar.gz
hercules-0c1ce8e1c427d665c207512a0e858872ef80672d.tar.bz2
hercules-0c1ce8e1c427d665c207512a0e858872ef80672d.tar.xz
hercules-0c1ce8e1c427d665c207512a0e858872ef80672d.zip
Fixed some issues reported by coverity scan [1/3]
Signed-off-by: Haru <haru@dotalux.com>
Diffstat (limited to 'src/map/skill.c')
-rw-r--r--src/map/skill.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/map/skill.c b/src/map/skill.c
index 41d872b77..77e9f24aa 100644
--- a/src/map/skill.c
+++ b/src/map/skill.c
@@ -2320,9 +2320,8 @@ int skill_attack(int attack_type, struct block_list* src, struct block_list *dsr
if( damage && sc && sc->data[SC_GENSOU] && dmg.flag&BF_MAGIC ){
struct block_list *nbl;
nbl = battle->get_enemy_area(bl,bl->x,bl->y,2,BL_CHAR,bl->id);
- if( nbl ){ // Only one target is chosen.
- int temp = (int)(damage / (float)(10 / skill_lv));
- clif->skill_damage(bl, nbl, tick, status_get_amotion(src), 0, status_fix_damage(bl,nbl,temp,0), 1, OB_OBOROGENSOU_TRANSITION_ATK, -1, 6);
+ if (nbl) { // Only one target is chosen.
+ clif->skill_damage(bl, nbl, tick, status_get_amotion(src), 0, status_fix_damage(bl,nbl,damage * skill_lv / 10,0), 1, OB_OBOROGENSOU_TRANSITION_ATK, -1, 6);
}
}