summaryrefslogtreecommitdiff
path: root/src/map
diff options
context:
space:
mode:
Diffstat (limited to 'src/map')
-rw-r--r--src/map/pc.c10
-rw-r--r--src/map/status.c13
2 files changed, 9 insertions, 14 deletions
diff --git a/src/map/pc.c b/src/map/pc.c
index 216d9cfd2..48f2977ad 100644
--- a/src/map/pc.c
+++ b/src/map/pc.c
@@ -7491,7 +7491,7 @@ struct map_session_data *pc_get_child (struct map_session_data *sd)
* SP‰ñ•œ—ÊŒvŽZ
*------------------------------------------
*/
-static int natural_heal_tick,natural_heal_prev_tick,natural_heal_diff_tick;
+static unsigned int natural_heal_prev_tick,natural_heal_diff_tick;
static int pc_spheal(struct map_session_data *sd)
{
int a = natural_heal_diff_tick;
@@ -7886,8 +7886,7 @@ static int pc_natural_heal_sub(struct map_session_data *sd,va_list ap) {
*/
int pc_natural_heal(int tid,unsigned int tick,int id,int data)
{
- natural_heal_tick = tick;
- natural_heal_diff_tick = DIFF_TICK(natural_heal_tick,natural_heal_prev_tick);
+ natural_heal_diff_tick = DIFF_TICK(tick,natural_heal_prev_tick);
clif_foreachclient(pc_natural_heal_sub, tick);
natural_heal_prev_tick = tick;
@@ -8398,8 +8397,9 @@ int do_init_pc(void) {
add_timer_func_list(pc_autosave, "pc_autosave");
add_timer_func_list(pc_spiritball_timer, "pc_spiritball_timer");
add_timer_func_list(pc_blockskill_end, "pc_blockskill_end");
- add_timer_func_list(pc_follow_timer, "pc_follow_timer");
- add_timer_interval((natural_heal_prev_tick = gettick() + NATURAL_HEAL_INTERVAL), pc_natural_heal, 0, 0, NATURAL_HEAL_INTERVAL);
+ add_timer_func_list(pc_follow_timer, "pc_follow_timer");
+ natural_heal_prev_tick = gettick();
+ add_timer_interval(natural_heal_prev_tick + NATURAL_HEAL_INTERVAL, pc_natural_heal, 0, 0, NATURAL_HEAL_INTERVAL);
add_timer(gettick() + autosave_interval, pc_autosave, 0, 0);
#ifndef TXT_ONLY
pc_read_gm_account(0);
diff --git a/src/map/status.c b/src/map/status.c
index 6c1350a0f..d9f958f1e 100644
--- a/src/map/status.c
+++ b/src/map/status.c
@@ -3305,31 +3305,26 @@ int status_get_sc_def(struct block_list *bl, int type)
switch (type)
{
//Note that stats that are *100/3 were simplified to *33
- case SP_MDEF1: // mdef
case SC_STONE:
case SC_FREEZE:
case SC_DECREASEAGI:
case SC_COMA:
sc_def = 300 +100*status_get_mdef(bl) +33*status_get_luk(bl);
break;
- case SP_MDEF2: // int
case SC_SLEEP:
case SC_CONFUSION:
sc_def = 300 +100*status_get_int(bl) +33*status_get_luk(bl);
break;
- case SP_DEF1: // def
- sc_def = 300 +100*status_get_def(bl) +33*status_get_luk(bl);
- break;
- case SP_DEF2: // vit
+// Removed since it collides with normal sc.
+// case SP_DEF1: // def
+// sc_def = 300 +100*status_get_def(bl) +33*status_get_luk(bl);
+// break;
case SC_STUN:
case SC_POISON:
case SC_SILENCE:
case SC_STOP:
sc_def = 300 +100*status_get_vit(bl) +33*status_get_luk(bl);
break;
- case SP_LUK: // luck
- sc_def = 300 +100*status_get_luk(bl);
- break;
case SC_BLIND:
sc_def = 300 +100*status_get_int(bl) +33*status_get_vit(bl);
break;