summaryrefslogtreecommitdiff
path: root/src/map/unit.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/map/unit.c')
-rw-r--r--src/map/unit.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/src/map/unit.c b/src/map/unit.c
index 7d68bef66..79abb8c6a 100644
--- a/src/map/unit.c
+++ b/src/map/unit.c
@@ -1667,6 +1667,9 @@ int unit_skilluse_id2(struct block_list *src, int target_id, uint16 skill_id, ui
} else
skill->castend_id(ud->skilltimer,tick,src->id,0);
+ if (sd != NULL && battle_config.prevent_logout_trigger & PLT_SKILL)
+ sd->canlog_tick = timer->gettick();
+
return 1;
}
@@ -1813,6 +1816,10 @@ int unit_skilluse_pos2( struct block_list *src, short skill_x, short skill_y, ui
ud->skilltimer = INVALID_TIMER;
skill->castend_pos(ud->skilltimer,tick,src->id,0);
}
+
+ if (sd != NULL && battle_config.prevent_logout_trigger & PLT_SKILL)
+ sd->canlog_tick = timer->gettick();
+
return 1;
}
@@ -2253,6 +2260,9 @@ int unit_attack_timer_sub(struct block_list* src, int tid, int64 tick)
ud->attacktimer = timer->add(ud->attackabletime,unit->attack_timer,src->id,0);
}
+ if (sd != NULL && battle_config.prevent_logout_trigger & PLT_ATTACK)
+ sd->canlog_tick = timer->gettick();
+
return 1;
}