Добавлено: Чт июн 05, 2008 1:55 pm
Код был проверен на 6317, если терны кидает сопартиец то атака не отменялась, если выходил из пати то появлялось стандартное сообщение о КС.Click писал(а):комминтим?
Вроде работает )
Клуб любителей пляски с бубном вокруг OpenKore
https://www.ro-fan.ru/
Код был проверен на 6317, если терны кидает сопартиец то атака не отменялась, если выходил из пати то появлялось стандартное сообщение о КС.Click писал(а):комминтим?
Код: Выделить всё
attackAuto 2
attackAuto_party 1
attackAuto_onlyWhenSafe 0
attackAuto_followTarget 1
attackAuto_inLockOnly 1
attackDistance 1.5
attackDistanceAuto 0
attackMaxDistance 2.5
attackMaxRouteDistance 100
attackMaxRouteTime 4
attackMinPlayerDistance 2
attackMinPortalDistance 4
attackUseWeapon 1
attackNoGiveup 0
attackCanSnipe 0
attackCheckLOS 0
attackLooters 0
attackChangeTarget 1
aggressiveAntiKS 0
Код: Выделить всё
Attacking: Monster Condor (1)
[ 86/100] You attack Monster Condor (1) - Dmg: 37 (delay 61.6)
[ 86/100] Monster Condor (1) attacks you - Dmg: 3 (delay 64.8)
[ 86/100] Monster Condor (0) attacks you - Dmg: 5 (delay 64.8)
Target died
Attacking: Monster Willow (3)
[ 72/100] Monster Fabre (2) attacks you - Dmg: 1 (delay 67.2)
[ 72/100] Monster Condor (0) attacks you - Dmg: 5 (delay 45.4)
[ 86/100] You attack Monster Willow (3) - Dmg: 22 (delay 61.6)
Target died
[ 71/100] Monster Condor (0) attacks you - Dmg: 5 (delay 45.4)
[ 64/100] Monster Fabre (2) attacks you - Dmg: Miss! (delay 67.2)
Attacking: Monster Roda frog (5)
[ 64/100] Monster Condor (0) attacks you - Dmg: Miss!! (delay 45.4)
[ 88/100] Monster Fabre (2) attacks you - Dmg: Miss! (delay 67.2)
[ 84/100] You attack Monster Roda frog (5) - Dmg: 38 (delay 61.6)
[ 79/100] Monster Roda frog (5) attacks you - Dmg: 4 (delay 81.6)
Target died
[ 76/100] Monster Condor (0) attacks you - Dmg: Miss! (delay 45.4)
[ 75/100] Monster Fabre (2) attacks you - Dmg: 1 (delay 67.2)
Calculating random route to: Training Ground(new_3-3): 118, 51
Attacking: Monster Super Picky (6)
[ 71/100] Monster Condor (0) attacks you - Dmg: 4 (delay 45.4)
[ 66/100] Monster Fabre (2) attacks you - Dmg: 1 (delay 67.2)
[ 77/100] You attack Monster Super Picky (6) - Dmg: 21 (delay 61.6)
[ 73/100] Monster Super Picky (6) attacks you - Dmg: 1 (delay 28.8)
Код: Выделить всё
teleportAuto {
hp 0
sp 0
idle 0
portal 0
search 0
minAggressives 0
minAggressivesInLock 0
onlyWhenSafe 0
maxDmg 0
maxDmgInLock 0
deadly 0
useSkill 3
useChatCommand
allPlayers 0
atkCount 0
atkMiss 0
unstuck 0
dropTarget 0
dropTargetKS 0
attackedWhenSitting 0
totalDmg 0
totalDmgInLock 0
equip_leftAccessory
equip_rightAccessory
lostHomunculus
lostTarget
useItemForRespawn
}
Код: Выделить всё
teleportAuto_hp 1
teleportAuto_sp 0
teleportAuto_idle 0
teleportAuto_portal 0
teleportAuto_search 0
teleportAuto_minAggressives 5
teleportAuto_minAggressivesInLock 0
teleportAuto_onlyWhenSafe 0
teleportAuto_maxDmg 500
teleportAuto_maxDmgInLock 0
teleportAuto_deadly 1
teleportAuto_useSkill 3
teleportAuto_useChatCommand
teleportAuto_allPlayers 0
teleportAuto_atkCount 0
teleportAuto_atkMiss 10
teleportAuto_unstuck 0
teleportAuto_dropTarget 0
teleportAuto_dropTargetKS 0
teleportAuto_attackedWhenSitting 0
teleportAuto_totalDmg 0
teleportAuto_totalDmgInLock 0
teleportAuto_equip_leftAccessory
teleportAuto_equip_rightAccessory
teleportAuto_lostHomunculus
teleportAuto_lostTarget
Click писал(а):судя по misc.mp должен работать, но и если смотреть глубже, то по коду вроде как будет работать, если в конфиге не будет стоять условия на телепорты от дагами, хп и тп...
Код: Выделить всё
} elsif ($config{attackChangeTarget} && ((AI::action eq "route" && AI::action(1) eq "attack") || (AI::action eq "move" && AI::action(2) eq "attack"))
&& AI::args->{attackID} && AI::args()->{attackID} ne $ID1) {
my $attackTarget = Actor::get(AI::args->{attackID});
my $attackSeq = (AI::action eq "route") ? AI::args(1) : AI::args(2);
if (!$attackTarget->{dmgToYou} && !$attackTarget->{dmgFromYou} && distance($monster->{pos_to}, calcPosition($char)) <= $attackSeq->{attackMethod}{distance}) {
my $ignore = 0;
# Don't attack ignored monsters
if ((my $control = mon_control($monster->{name},$monster->{nameID}))) {
$ignore = 1 if ( ($control->{attack_auto} == -1)
|| ($control->{attack_lvl} ne "" && $control->{attack_lvl} > $char->{lv})
|| ($control->{attack_jlvl} ne "" && $control->{attack_jlvl} > $char->{lv_job})
|| ($control->{attack_hp} ne "" && $control->{attack_hp} > $char->{hp})
|| ($control->{attack_sp} ne "" && $control->{attack_sp} > $char->{sp})
|| ($control->{attack_auto} == 3 && ($monster->{dmgToYou} || $monster->{missedYou} || $monster->{dmgFromYou}))
);
}
if (!$ignore) {
# Change target to closer aggressive monster
message TF("Change target to aggressive : %s (%s)\n", $monster->name, $monster->{binID});
stopAttack();
AI::dequeue;
AI::dequeue if (AI::action eq "route");
AI::dequeue;
attack($ID1);
}
}
Ну да, смена цели на моба который нас бьет.New config options
* attackChangeTarget <boolean flag>
Automatically change target to an aggressive monster if the target monster is not yet reached or damaged.
Код: Выделить всё
teleportAuto_hp 0
teleportAuto_sp 0
teleportAuto_idle 0
teleportAuto_portal 0
teleportAuto_search 0
teleportAuto_minAggressives 0
teleportAuto_minAggressivesInLock 0
teleportAuto_onlyWhenSafe 0
teleportAuto_maxDmg 0
teleportAuto_maxDmgInLock 0
teleportAuto_deadly 0
teleportAuto_useSkill 3
teleportAuto_useChatCommand
teleportAuto_allPlayers 0
teleportAuto_atkCount 0
teleportAuto_atkMiss 0
teleportAuto_unstuck 0
teleportAuto_dropTarget 0
teleportAuto_dropTargetKS 0
teleportAuto_attackedWhenSitting 0
teleportAuto_totalDmg 0
teleportAuto_totalDmgInLock 0
teleportAuto_equip_leftAccessory
teleportAuto_equip_rightAccessory
teleportAuto_lostHomunculus
teleportAuto_lostTarget
Код: Выделить всё
[Jun 11 11:58:39 2008.64] Attacking: Monster Fabre (13)
[Jun 11 11:58:40 2008.13] [ 57/100] Monster Condor (4) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:40 2008.19] Monster Condor (6) is casting Wind Attack on you (time 500ms)
[Jun 11 11:58:40 2008.57] [ 57/100] Monster Condor (3) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:40 2008.63] [ 57/100] Monster Condor (5) attacks you - Dmg: 6 (delay 64.8)
[Jun 11 11:58:40 2008.69] [ 57/100] Monster Condor (6) uses Wind Attack (lvl 3) on you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:40 2008.94] [ 57/100] Monster Condor (6) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:41 2008.26] [ 57/100] Monster Condor (4) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:41 2008.76] [ 55/100] Monster Condor (3) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:41 2008.82] [ 55/100] Monster Condor (5) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:42 2008.13] [ 55/100] Monster Condor (6) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:42 2008.38] [ 55/100] Monster Condor (4) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:42 2008.88] [ 55/100] Monster Condor (3) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:42 2008.95] [ 55/100] Monster Condor (5) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:43 2008.13] [ 55/100] You attack Monster Fabre (13) - Dmg: 32 (delay 33)
[Jun 11 11:58:43 2008.32] [ 55/100] Monster Condor (6) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:43 2008.45] [ 55/100] Monster Fabre (13) attacks you - Dmg: Miss! (delay 67.2)
[Jun 11 11:58:43 2008.57] Monster Condor (4) is casting Adrenaline Rush on itself (time 1500ms)
[Jun 11 11:58:43 2008.82] [ 55/100] You attack Monster Fabre (13) - Dmg: 28 (delay 33)
[Jun 11 11:58:44 2008.12] [ 55/100] Monster Fabre (1) attacks you - Dmg: Miss! (delay 67.2)
[Jun 11 11:58:44 2008.72] [ 55/100] Monster Condor (3) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:44 2008.13] [ 55/100] Monster Condor (5) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:44 2008.38] [ 55/100] Monster Condor (6) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:44 2008.44] [ 55/100] You attack Monster Fabre (13) - Dmg: 39 (delay 33)
[Jun 11 11:58:44 2008.76] Exp gained: 3/2 (0.16%/0.38%)
[Jun 11 11:58:44 2008.77] Target died
[Jun 11 11:58:45 2008.74] Monster Condor (4) uses Adrenaline Rush on itself : Lv 1
[Jun 11 11:58:45 2008.19] [ 56/100] Monster Condor (3) attacks you - Dmg: Miss! (delay 64.8)
[Jun 11 11:58:45 2008.20] Monster Condor (5) is casting Wind Attack on you (time 500ms)
[Jun 11 11:58:45 2008.27] Attacking: Monster Lunatic (8)
[Jun 11 11:58:45 2008.50] [ 56/100] Monster Condor (4) attacks you - Dmg: Miss! (delay 45.3)
[Jun 11 11:58:45 2008.57] [ 56/100] Monster Condor (6) attacks you - Dmg: 6 (delay 64.8)
[Jun 11 11:58:45 2008.69] [ 56/100] Monster Fabre (1) attacks you - Dmg: Miss! (delay 67.2)
[Jun 11 11:58:45 2008.70] [ 56/100] Monster Condor (5) uses Wind Attack (lvl 3) on you - Dmg: Miss! (delay 64.8)
Код: Выделить всё
if ((my $control = mon_control($monster->{name},$monster->{nameID}))) {
$ignore = 1 if ( ($control->{attack_auto} == -1)
|| ($control->{attack_lvl} ne "" && $control->{attack_lvl} > $char->{lv})
|| ($control->{attack_jlvl} ne "" && $control->{attack_jlvl} > $char->{lv_job})
|| ($control->{attack_hp} ne "" && $control->{attack_hp} > $char->{hp})
|| ($control->{attack_sp} ne "" && $control->{attack_sp} > $char->{sp})
|| ($control->{attack_auto} == 3 && ($monster->{dmgToYou} || $monster->{missedYou} || $monster->{dmgFromYou}))
);
}
Код: Выделить всё
- $ignore = 1 if ( ($control->{attack_auto} == -1)
+ if ( ($control->{attack_auto} == -1)
......
- );
+ ){$ignore = 1};
Код: Выделить всё
} elsif ($config{attackChangeTarget}) {
warning TF("Check change Target %s %s %s\n",AI::action,AI::action(1),AI::action(2));
if ($config{attackChangeTarget} && ((AI::action eq "route" && AI::action(1) eq "attack") || (AI::action eq "move" && AI::action(2) eq "attack"))) {
warning TF("Check change Target %d %d \n",AI::args->{attackID},$ID1);
if (AI::args->{attackID} && AI::args()->{attackID} ne $ID1) {
Код: Выделить всё
[Jun 11 13:34:41 2008.74] [attacked] [100/100] Monster Wolf (2) attacks you - Dmg: 1 (delay 50.4)
[Jun 11 13:34:42 2008.30] [console] Attacking: Monster Roda frog (4)
[Jun 11 13:34:42 2008.80] [console] Check change Target route attack
[Jun 11 13:34:42 2008.81] [console] Check change Target 0 0
Мне очень смешно. этого ключа в хэше args вообше нет. ну никогда нет )Click писал(а):оно вообще работает?
Код: Выделить всё
[Jun 19 23:21:34 2008.92] Attacking: Monster Lunatic (0)
[Jun 19 23:21:35 2008.41] ------ AI Sequence ---------------------
[Jun 19 23:21:35 2008.42] 0: route
[Jun 19 23:21:35 2008.42] 1: attack {monsterPos=>{y=>'141',x=>'59'},ID=>'В_В+В_.',missedFromYou_last=>'',dmgFromYou_last=>'',
move_start=>'1213903294.98192',pos_to=>{y=>'141',x=>'59'},unstuck=>{timeout=>'2.75'},lastSkillTime=>'',
dmgToYou_last=>'',attackMethod=>{maxDistance=>'2.5',distance=>'1.5',type=>'weapon'},pos=>{y=>'143',x=>'70'},
missedYou_last=>'',ai_attack_giveup=>{timeout=>'12',time=>'1213903294'}}
[Jun 19 23:21:35 2008.42] 2: route
[Jun 19 23:21:35 2008.42] ------ AI Sequences --------------------
[Jun 19 23:21:39 2008.64] [100/100] You attack Monster Lunatic (0) - Dmg: 14 (delay 26.2)
[Jun 19 23:21:39 2008.95] ------ AI Sequence ---------------------
[Jun 19 23:21:39 2008.95] 0: attack {monsterPos=>{y=>'132',x=>'65'},ID=>'В_В+В_.',missedFromYou_last=>'',dmgFromYou_last=>'14',move_start=>'',
pos_to=>{y=>'141',x=>'59'},unstuck=>{time=>'1213903299.57577',timeout=>'2.75'},lastSkillTime=>'',dmgToYou_last=>'',
attackMethod=>{maxDistance=>'2.5',distance=>'1.5',type=>'weapon'},pos=>{y=>'143',x=>'70'},missedYou_last=>'',firstAttack=>'1',
ai_attack_giveup=>{timeout=>'12',time=>'1213903299.64364'}}
[Jun 19 23:21:39 2008.95] 1: route
[Jun 19 23:21:39 2008.95] ------ AI Sequences --------------------