diff options
author | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2008-03-07 15:02:32 +0000 |
---|---|---|
committer | skotlex <skotlex@54d463be-8e91-2dee-dedb-b68131a5f0ec> | 2008-03-07 15:02:32 +0000 |
commit | e8ab2885e6c07cdff08e66b55ac6bf5572e39402 (patch) | |
tree | 252a6f6b5d8b5fe93f18041e8b55b543cde956e1 /src/map/battle.c | |
parent | 88d795a036a4f954df1987fe3b241964df182a65 (diff) | |
download | hercules-e8ab2885e6c07cdff08e66b55ac6bf5572e39402.tar.gz hercules-e8ab2885e6c07cdff08e66b55ac6bf5572e39402.tar.bz2 hercules-e8ab2885e6c07cdff08e66b55ac6bf5572e39402.tar.xz hercules-e8ab2885e6c07cdff08e66b55ac6bf5572e39402.zip |
- Added config settings mob_active_time and boss_active_time, what they do is specify a duration during which monsters will keep running their active AI after all players have left their vecinity. Their current defaults are set to 0 (disabled).
- Script induced status changes can now be reduced by stats/cards (but only trigger rate is reduced, not duration)
- Battle delay timers will now check if the target player has the invincible timer active or not.
- Adjusted mob_ai_sub_hard to return a bool indicating whether the AI was executed or not.
- Adjusted clif_damage and clif_skill_damage to set the endure type value based on dmotion and damage, rather than hardchecking for SC_ENDURE.
git-svn-id: https://rathena.svn.sourceforge.net/svnroot/rathena/trunk@12315 54d463be-8e91-2dee-dedb-b68131a5f0ec
Diffstat (limited to 'src/map/battle.c')
-rw-r--r-- | src/map/battle.c | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/map/battle.c b/src/map/battle.c index 3c467ff2e..7b58dd419 100644 --- a/src/map/battle.c +++ b/src/map/battle.c @@ -154,7 +154,9 @@ int battle_delay_damage_sub (int tid, unsigned int tick, int id, int data) struct delay_damage *dat = (struct delay_damage *)data; struct block_list *target = map_id2bl(dat->target); if (target && dat && map_id2bl(id) == dat->src && target->prev != NULL && !status_isdead(target) && - target->m == dat->src->m && check_distance_bl(dat->src, target, dat->distance)) //Check to see if you haven't teleported. [Skotlex] + target->m == dat->src->m && + (target->type != BL_PC || ((TBL_PC*)target)->invincible_timer == -1) && + check_distance_bl(dat->src, target, dat->distance)) //Check to see if you haven't teleported. [Skotlex] { map_freeblock_lock(); status_fix_damage(dat->src, target, dat->damage, dat->delay); @@ -3643,6 +3645,8 @@ static const struct _battle_data { { "day_duration", &battle_config.day_duration, 0, 0, INT_MAX, }, { "night_duration", &battle_config.night_duration, 0, 0, INT_MAX, }, { "mob_remove_delay", &battle_config.mob_remove_delay, 60000, 15000, INT_MAX, }, + { "mob_active_time", &battle_config.mob_active_time, 0, 0, INT_MAX, }, + { "boss_active_time", &battle_config.boss_active_time, 0, 0, INT_MAX, }, { "sg_miracle_skill_duration", &battle_config.sg_miracle_skill_duration, 3600000, 0, INT_MAX, }, { "hvan_explosion_intimate", &battle_config.hvan_explosion_intimate, 45000, 0, 100000, }, { "quest_exp_rate", &battle_config.quest_exp_rate, 100, 0, INT_MAX, }, |