summaryrefslogtreecommitdiff
path: root/src/map/pc.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/pc.c')
-rw-r--r--src/map/pc.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 0557708cb..a5cea128d 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -5082,9 +5082,9 @@ int pc_dead(struct map_session_data *sd,struct block_list *src)
// activate Steel body if a super novice dies at 99+% exp [celest]
if ((sd->class_&MAPID_UPPERMASK) == MAPID_SUPER_NOVICE && !sd->state.snovice_dead_flag)
{
- if ((i=pc_nextbaseexp(sd))<=0)
- i=sd->status.base_exp;
- if (i>0 && (j=sd->status.base_exp*1000/i)>=990 && j<1000 && !map_flag_gvg(sd->bl.m))
+ unsigned int next = pc_nextbaseexp(sd);
+ if( next == 0 ) next = pc_thisbaseexp(sd);
+ if( percent(sd->status.base_exp,next) >= 99 && !map_flag_gvg(sd->bl.m) )
sd->state.snovice_dead_flag = 1;
}