fix(Core/Movement): Fixed the random movement speed of biological pets#24453
fix(Core/Movement): Fixed the random movement speed of biological pets#24453PkllonG wants to merge 8 commits intoazerothcore:masterfrom
Conversation
|
@killerwife can you please take a look at this pr :) |
|
Absolutely not valid fix. Here is the reasoning: SetWalk should eventually be a setting only the scripter manipulates (and is set otherwise only on spawn) The state of a pet running/following should be done with Follow Movement (or formation movement). Reason being that there are cases where specifically a pet stops its follow and is engaged on its own waypoints, and as such stuff cant be automatic to a point where it hinders this functionality. The current code should behave in a way that it sets the walk/run for the current movement, and NOT for any subsequent movements (i.e. state of creature doesnt change). One should look into FollowMovementGenerator. Pets dynamically change their speeds based on the distance they are from their master on official. If far, run quickly, if small adjustment while owner is stationary, walk, etc. |
|
The PR did not change the way pets move; the PR fixed the way pet owners move. |
|
Pet needs to adjust to owner, not owner to pet. (if i understand, u fixed jitter of pets by changing owner, and owner of pet is meant to be scripted by scripter not some automatic logic) |
This comment was marked as spam.
This comment was marked as spam.
|
I am the author of the changes made to it. NPC can be walking and not be in walking state. "Walking" clientside is speed based, not state based. As such movement->m_spline can have speed == 2.5f (walking) but SetWalk == false. Same goes for IsWalking - can be true . SetWalk in Acore sends SMSG_SPLINE_MOVE_SET_WALK_MODE : SMSG_SPLINE_MOVE_SET_RUN_MODE Is sniff versus which you are fixing issue sending this packet? If you give me proof I will gladly change my opinion. |
|
You're right, we don't need to send packets. |
|
You're right, we only need to update MOVEMENTFLAG_WALKING to achieve the goal. |
|
Latest changes |
|
One more insight, that is currently wrong entirely in Acore: You are also not meant to use MOVEMENTFLAG_WALKING for creatures. Clientside creatures do not use this flag, only players. Feel free to check sniffs again to confirm my statement. (movement flags are broadcast in smsg_update_object on spawn) |
|
Also likely this problem is result of this: Feel free to validate. (and that pr is correct vs sniffs, might be a side effect) |
|
I finally had time to test but this change will not fix the SMART_ACTION_FOLLOW issue. |
This PR fixes the error caused by #24410. |
You can use this #1 to fix the error you mentioned. |



Changes Proposed:
This PR proposes changes to:
AI-assisted Pull Requests
Important
While the use of AI tools when preparing pull requests is not prohibited, contributors must clearly disclose when such tools have been used and specify the model involved.
Contributors are also expected to fully understand the changes they are submitting and must be able to explain and justify those changes when requested by maintainers.
Issues Addressed:
SOURCE:
The changes have been validated through:
Tests Performed:
This PR has been:
How to Test the Changes:
.go c id 16345.go c id 669.go c id 458Known Issues and TODO List:
How to Test AzerothCore PRs
When a PR is ready to be tested, it will be marked as [WAITING TO BE TESTED].
You can help by testing PRs and writing your feedback here on the PR's page on GitHub. Follow the instructions here:
http://www.azerothcore.org/wiki/How-to-test-a-PR
REMEMBER: when testing a PR that changes something generic (i.e. a part of code that handles more than one specific thing), the tester should not only check that the PR does its job (e.g. fixing spell XXX) but especially check that the PR does not cause any regression (i.e. introducing new bugs).
For example: if a PR fixes spell X by changing a part of code that handles spells X, Y, and Z, we should not only test X, but we should test Y and Z as well.