Skip to content

Commit

Permalink
feat: Pathfinding v3 + Attack rework (#3676)
Browse files Browse the repository at this point in the history
  • Loading branch information
Henrybk authored Dec 28, 2024
1 parent 97f1657 commit 435ddcd
Show file tree
Hide file tree
Showing 29 changed files with 3,489 additions and 1,661 deletions.
Binary file modified NetRedirect.dll
Binary file not shown.
Binary file modified XSTools.dll
Binary file not shown.
48 changes: 36 additions & 12 deletions control/config.txt
Original file line number Diff line number Diff line change
Expand Up @@ -72,9 +72,8 @@ attackAuto_notWhile_storageAuto 1
attackAuto_notWhile_buyAuto 1
attackAuto_notWhile_sellAuto 1
attackAuto_considerDamagedAggressive 0
attackBeyondMaxDistance_waitForAgressive 1
attackDistance 1
attackDistanceAuto 0
attackDistanceAuto 1
attackMaxDistance 1
attackMaxRouteDistance 50
attackMaxRouteTime 4
Expand All @@ -83,15 +82,20 @@ attackMinPortalDistance 4
attackUseWeapon 1
attackNoGiveup 0
attackCanSnipe 0
attackCheckLOS 0
attackRouteMaxPathDistance 13
attackCheckLOS 1
attackRouteMaxPathDistance 20
attackLooters 0
attackLooters_dist 1
attackChangeTarget 1
aggressiveAntiKS 0

attackUpdateMonsterPos 1

attackBeyondMaxDistance_waitForAgressive 1
attackBeyondMaxDistance_sendAttackWhileWaiting 1
attackSendAttackWithMove 1
attackWaitApproachFinish 1

autoMoveOnDeath 0
autoMoveOnDeath_x
autoMoveOnDeath_y
Expand Down Expand Up @@ -225,12 +229,16 @@ route_removeMissingPortals_NPC 1
route_removeMissingPortals 0
route_tryToGuessMissingPortalByDistance 1
route_reAddMissingPortals 1
route_randomFactor 0

runFromTarget 0
runFromTarget_inAdvance 0
runFromTarget_dist 5
runFromTarget_minStep 7
runFromTarget_maxPathDistance 13
runFromTarget_noAttackMethodFallback 0
runFromTarget_noAttackMethodFallback_attackMaxDist 14
runFromTarget_noAttackMethodFallback_minStep 8

saveMap
saveMap_warpToBuyOrSell 1
Expand Down Expand Up @@ -386,22 +394,27 @@ mercenary_attackAuto_notWhile_storageAuto 1
mercenary_attackAuto_notWhile_buyAuto 1
mercenary_attackAuto_notWhile_sellAuto 1
mercenary_attackAuto_considerDamagedAggressive 0
mercenary_attackBeyondMaxDistance_waitForAgressive 1
mercenary_attackAuto_onlyWhenSafe 0
mercenary_attackAuto_duringRandomWalk 0
mercenary_attackAuto_duringItemsTake 0
mercenary_attackDistance 1
mercenary_attackMaxDistance 1
mercenary_attackDistanceAuto 0
mercenary_attackDistanceAuto 1
mercenary_attackMaxRouteTime 4
mercenary_attackCanSnipe 0
mercenary_attackCheckLOS 1
mercenary_attackRouteMaxPathDistance 20
mercenary_attackUseWeapon 1
mercenary_attackNoGiveup 0
mercenary_attackChangeTarget 1
mercenary_attack_dance_melee 0
mercenary_attack_dance_ranged 0

mercenary_attackBeyondMaxDistance_waitForAgressive 1
mercenary_attackBeyondMaxDistance_sendAttackWhileWaiting 1
mercenary_attackSendAttackWithMove 1
mercenary_attackWaitApproachFinish 1

mercenary_lost_teleportToMaster_maxTries 6

mercenary_route_randomWalk_rescueWhenLost 0
Expand All @@ -413,13 +426,16 @@ mercenary_runFromTarget_inAdvance 0
mercenary_runFromTarget_dist 5
mercenary_runFromTarget_minStep 7
mercenary_runFromTarget_maxPathDistance 20
mercenary_runFromTarget_noAttackMethodFallback 0
mercenary_runFromTarget_noAttackMethodFallback_attackMaxDist 14
mercenary_runFromTarget_noAttackMethodFallback_minStep 8

mercenary_followDistanceMax 12
mercenary_followDistanceMin 3

mercenary_moveNearWhenIdle 1
mercenary_moveNearWhenIdle_minDistance 2
mercenary_moveNearWhenIdle_maxDistance 12
mercenary_moveNearWhenIdle_minDistance 3
mercenary_moveNearWhenIdle_maxDistance 8

mercenary_idleWalkType 1

Expand Down Expand Up @@ -449,21 +465,26 @@ homunculus_attackAuto_notWhile_storageAuto 1
homunculus_attackAuto_notWhile_buyAuto 1
homunculus_attackAuto_notWhile_sellAuto 1
homunculus_attackAuto_considerDamagedAggressive 0
homunculus_attackBeyondMaxDistance_waitForAgressive 1
homunculus_attackAuto_onlyWhenSafe 0
homunculus_attackAuto_duringRandomWalk 0
homunculus_attackAuto_duringItemsTake 0
homunculus_attackDistance 1
homunculus_attackMaxDistance 1
homunculus_attackDistanceAuto 0
homunculus_attackDistanceAuto 1
homunculus_attackMaxRouteTime 4
homunculus_attackCanSnipe 0
homunculus_attackCheckLOS 1
homunculus_attackRouteMaxPathDistance 20
homunculus_attackUseWeapon 1
homunculus_attackNoGiveup 0
homunculus_attackChangeTarget 1
homunculus_attack_dance_melee 0

homunculus_attackBeyondMaxDistance_waitForAgressive 1
homunculus_attackBeyondMaxDistance_sendAttackWhileWaiting 1
homunculus_attackSendAttackWithMove 1
homunculus_attackWaitApproachFinish 1

homunculus_lost_teleportToMaster_maxTries 6

homunculus_route_randomWalk_rescueWhenLost 0
Expand All @@ -474,13 +495,16 @@ homunculus_runFromTarget 0
homunculus_runFromTarget_dist 5
homunculus_runFromTarget_minStep 7
homunculus_runFromTarget_maxPathDistance 20
homunculus_runFromTarget_noAttackMethodFallback 0
homunculus_runFromTarget_noAttackMethodFallback_attackMaxDist 14
homunculus_runFromTarget_noAttackMethodFallback_minStep 8

homunculus_followDistanceMax 12
homunculus_followDistanceMin 3

homunculus_moveNearWhenIdle 1
homunculus_moveNearWhenIdle_minDistance 2
homunculus_moveNearWhenIdle_maxDistance 12
homunculus_moveNearWhenIdle_minDistance 3
homunculus_moveNearWhenIdle_maxDistance 8

homunculus_idleWalkType 1

Expand Down
7 changes: 7 additions & 0 deletions control/timeouts.txt
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,8 @@ ai_attack 1
ai_homunculus_attack 1
ai_mercenary_attack 1

ai_attack_after_skill 0.5

ai_homunculus_dance_attack_melee 0.2

ai_mercenary_dance_attack_melee 0.2
Expand Down Expand Up @@ -67,6 +69,11 @@ ai_attack_waitAfterKill 0.3
ai_homunculus_attack_waitAfterKill 0.3
ai_mercenary_attack_waitAfterKill 0.3

# Every x seconds loop the attack logic routine (send move, attack, skill, avoid, etc)
ai_attack_main 0.1
ai_homunculus_attack_main 0.1
ai_mercenary_attack_main 0.1

ai_attack_unstuck 2.75
ai_attack_unfail 12

Expand Down
Loading

0 comments on commit 435ddcd

Please sign in to comment.