diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-02-18 21:44:27 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2006-02-18 21:44:27 +0000 |
commit | cba78be11327390da594bf212497e088cc42d8f6 (patch) | |
tree | a0ead4f053d3e7d47a7f8fd16e4c7b2f85b2483a /src/map/pc.c | |
parent | 05e220f3b8c69fc3ed7a420c6fd68b7bccada9f2 (diff) | |
download | hercules-cba78be11327390da594bf212497e088cc42d8f6.tar.gz hercules-cba78be11327390da594bf212497e088cc42d8f6.tar.bz2 hercules-cba78be11327390da594bf212497e088cc42d8f6.tar.xz hercules-cba78be11327390da594bf212497e088cc42d8f6.zip |
- Removed the SP_<stat> cases from status_get_sc_def as they were colliding with some status changes.
- Some cleanup of the pc natural regen functions.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@5326 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/pc.c')
-rw-r--r-- | src/map/pc.c | 10 |
1 files changed, 5 insertions, 5 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);
|