Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Pathfinding v3 + Attack rework #3676

Merged
merged 61 commits into from
Dec 28, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
61 commits
Select commit Hold shift + click to select a range
eb8b6a0
xs
Henrybk Oct 1, 2022
1434e98
New pathfinding
Henrybk Oct 1, 2022
73af4b6
route_randomFactor
Henrybk Oct 1, 2022
8eaed2d
remove comments
Henrybk Oct 1, 2022
6a7d1e3
dlls
Henrybk Oct 6, 2022
e893f18
Rework attack approach logic
Henrybk Oct 6, 2022
d5c5d52
Attack rework
Henrybk Oct 8, 2022
41be6c8
Merge branch 'master' into pathing
Henrybk Oct 8, 2022
43c69c8
slave update
Henrybk Oct 8, 2022
6b5eb29
Slave cleaning
Henrybk Oct 8, 2022
88a3022
Comments, exports, TODOs
Henrybk Oct 8, 2022
03b2464
more comments
Henrybk Oct 8, 2022
f09c2b1
more cleaning
Henrybk Oct 8, 2022
3d0f1b1
add NewAStarAvoid
Henrybk Oct 8, 2022
a496b14
dll
Henrybk Oct 8, 2022
ff1ffb9
clean dll remake
Henrybk Oct 8, 2022
8f38862
remove compile
Henrybk Oct 8, 2022
c13a2e6
remove print
Henrybk Oct 8, 2022
74bf32d
clean meetingPosition
Henrybk Oct 8, 2022
490c6fa
white space cleaning
Henrybk Oct 9, 2022
9c33fb9
Merge branch 'master' into pr/3676
alisonrag Feb 22, 2023
99b49f9
fix: increase max path distance
alisonrag Feb 24, 2023
07a219b
fix: add checklos when distance is less then 2 blocks
alisonrag Feb 24, 2023
142ec44
Merge branch 'master' into pathing
Henrybk Sep 17, 2023
cb24bdc
Removed time Optimization in route and added retry counter to maproute
Henrybk Sep 17, 2023
1098efd
Add same cell check to canmove in field pm
Henrybk Sep 17, 2023
3d92100
Fix attackmethod approach
Henrybk Sep 19, 2023
4fc8a3e
Merge branch 'master' into pathing
Henrybk Dec 17, 2024
615a237
Fix typo in Utils and adjust line order in config
Henrybk Dec 17, 2024
553389a
Remove whiteline in config and set LOS to 1
Henrybk Dec 17, 2024
6aab390
Added many comments to Attack.pm
Henrybk Dec 17, 2024
b1ec5d0
Remove needreadjust from attack logic
Henrybk Dec 17, 2024
eb36752
Reworked a few TODOs in Attack PM
Henrybk Dec 18, 2024
7fed561
Update client dist according to rathena
Henrybk Dec 18, 2024
538e4b0
Add temporary_extra_range logic to fix BUG 1 and abuse rathena extra …
Henrybk Dec 19, 2024
38ebadb
Comment
Henrybk Dec 19, 2024
2b896ce
Simplified meetposition a bit and organized checks
Henrybk Dec 19, 2024
6c8c890
add runFromTarget_noAttackMethodFallback
Henrybk Dec 20, 2024
6ffb6f7
update comment
Henrybk Dec 20, 2024
cb7f483
Reorganize attack process and add timeouts
Henrybk Dec 21, 2024
b8e3f08
Port changes to slave attack
Henrybk Dec 21, 2024
84e5d1d
ass avoid hidden to slaves, add TODOs and clean messages
Henrybk Dec 22, 2024
729a974
Merge branch 'master' into pathing
Henrybk Dec 22, 2024
6a929e0
Fix slave skills
Henrybk Dec 23, 2024
6414c6b
Add workaround for homunculus resurrect range bug
Henrybk Dec 23, 2024
9eb68fe
Move skills to slave AI-
Henrybk Dec 23, 2024
1a176a0
Merge branch 'Fixslaveskills' into pathing
Henrybk Dec 23, 2024
a8b7bb5
Test move functions to XS
Henrybk Dec 24, 2024
d2cb675
Fix typos
Henrybk Dec 24, 2024
711e489
Fix unsigned long in wrong operation
Henrybk Dec 24, 2024
ef441b1
Merge branch 'master' into pathing
Henrybk Dec 26, 2024
0320dc3
Fix conflicts with new PR and add comments TODO
Henrybk Dec 26, 2024
6c87d50
add slave attackUseWeapon
Henrybk Dec 27, 2024
1efc74c
Change warning to debugs
Henrybk Dec 27, 2024
7361775
Fix TF messages
Henrybk Dec 27, 2024
6be731d
chore: update xstools dll
alisonrag Dec 28, 2024
fb55a2b
Merge branch 'pathing' of https://github.com/Henrybk/openkore into pr…
alisonrag Dec 28, 2024
528767f
feat: enable auto attack distance
alisonrag Dec 28, 2024
09a853f
Merge branch 'master' into pr/3676
alisonrag Dec 28, 2024
fa54506
Add timeout for using attacks after skills
Henrybk Dec 28, 2024
e36397f
chore: update dlls
alisonrag Dec 28, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
Loading