summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/map/battle.c24
1 files changed, 17 insertions, 7 deletions
diff --git a/src/map/battle.c b/src/map/battle.c
index 113d82fbf..961bb3244 100644
--- a/src/map/battle.c
+++ b/src/map/battle.c
@@ -328,13 +328,23 @@ int battle_attr_fix(struct block_list *src, struct block_list *target, int damag
sg->limit = DIFF_TICK(gettick(),sg->tick)+300;
}
}
- }
- if( atk_elem == ELE_FIRE && tsc && tsc->count && tsc->data[SC_SPIDERWEB] ){
- tsc->data[SC_SPIDERWEB]->val1 = 0; // free to move now
- if( tsc->data[SC_SPIDERWEB]->val2-- > 0 )
- damage <<= 1; // double damage
- if( tsc->data[SC_SPIDERWEB]->val2 == 0 )
- status_change_end(target, SC_SPIDERWEB, INVALID_TIMER);
+ }
+ if( tsc && tsc->count ) {
+ if( tsc->data[SC_SPIDERWEB] && atk_elem == ELE_FIRE ){
+ tsc->data[SC_SPIDERWEB]->val1 = 0; // free to move now
+ if( tsc->data[SC_SPIDERWEB]->val2-- > 0 )
+ damage <<= 1; // double damage
+ if( tsc->data[SC_SPIDERWEB]->val2 == 0 )
+ status_change_end(target, SC_SPIDERWEB, INVALID_TIMER);
+ }
+ if( tsc->data[SC_ORATIO] && atk_elem == ELE_HOLY )
+ ratio += tsc->data[SC_ORATIO]->val1 * 2;
+ if( tsc->data[SC_VENOMIMPRESS] && atk_elem == ELE_POISON )
+ ratio += tsc->data[SC_VENOMIMPRESS]->val2;
+ if( tsc->data[SC_THORNSTRAP] && atk_elem == ELE_FIRE )
+ status_change_end(target, SC_THORNSTRAP, -1);
+ if( tsc->data[SC_FIRE_CLOAK_OPTION] && atk_elem == ELE_FIRE )
+ damage -= damage * tsc->data[SC_FIRE_CLOAK_OPTION]->val2 / 100;
}
return damage*ratio/100;
}