Skip to content

Commit

Permalink
chore: move skill target time to ai_v temp
Browse files Browse the repository at this point in the history
now this key is deleted on map change
  • Loading branch information
alisonrag committed Jan 16, 2025
1 parent 174131c commit 5c85c58
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 5 deletions.
4 changes: 2 additions & 2 deletions src/AI/Attack.pm
Original file line number Diff line number Diff line change
Expand Up @@ -727,7 +727,7 @@ sub main {
delete $args->{attackMethod};

$ai_v{"attackSkillSlot_${slot}_time"} = time;
$ai_v{"attackSkillSlot_${slot}_target_time"}{$ID} = time;
$ai_v{temp}{"attackSkillSlot_${slot}_target_time"}{$ID} = time;

ai_setSuspend(0);
my $skill = new Skill(auto => $config{"attackSkillSlot_$slot"});
Expand Down Expand Up @@ -759,7 +759,7 @@ sub main {
delete $args->{attackMethod};

$ai_v{"attackComboSlot_${slot}_time"} = time;
$ai_v{"attackComboSlot_${slot}_target_time"}{$ID} = time;
$ai_v{temp}{"attackComboSlot_${slot}_target_time"}{$ID} = time;

ai_skillUse2(
$skill,
Expand Down
2 changes: 1 addition & 1 deletion src/AI/CoreLogic.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3027,7 +3027,7 @@ sub processMonsterSkillUse {
my $target = $config{"${prefix}_isSelfSkill"} ? $char : $monster;
ai_skillUse2($skill, $lvl, $maxCastTime, $minCastTime, $target, $prefix);
$ai_v{$prefix . "_time"} = time;
$ai_v{$prefix . "_target_time"}{$monsterID} = time;
$ai_v{temp}{$prefix . "_target_time"}{$monsterID} = time;
last;
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/AI/SlaveAttack.pm
Original file line number Diff line number Diff line change
Expand Up @@ -687,7 +687,7 @@ sub main {
delete $args->{attackMethod};

$ai_v{"attackSkillSlot_${slot}_time"} = time;
$ai_v{"attackSkillSlot_${slot}_target_time"}{$ID} = time;
$ai_v{temp}{"attackSkillSlot_${slot}_target_time"}{$ID} = time;

ai_setSuspend(0);
my $skill = new Skill(auto => $config{"attackSkillSlot_$slot"});
Expand Down
2 changes: 1 addition & 1 deletion src/Misc.pm
Original file line number Diff line number Diff line change
Expand Up @@ -3072,7 +3072,7 @@ sub setPartySkillTimer {
# set partySkill target_time
my $i = $targetTimeout{$targetID}{$handle};
$ai_v{"partySkill_${i}_time"} = time if $i ne "";
$ai_v{"partySkill_${i}_target_time"}{$targetID} = time if $i ne "";
$ai_v{temp}{"partySkill_${i}_target_time"}{$targetID} = time if $i ne "";
}

##
Expand Down

0 comments on commit 5c85c58

Please sign in to comment.