-
Notifications
You must be signed in to change notification settings - Fork 6.1k
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
Core/UnitAI: Rework creature-controlled player behavior. #16644
Conversation
252e5f9
to
7082e7d
Compare
7bb8b79
to
0c978e4
Compare
This is for creatures that charm players right? Charmed players blow their cooldowns, this should also be implemented in this commit. |
For now I want to merge a basic generic player AI that works. After that, we can iterate easily on this to create smarter charmed player behavior. |
This will be fix on future? #15379 --Edit Treeston you are my hero ! |
Yes, that's what I'm referring to for future iterations. |
@@ -1022,6 +1023,8 @@ class Player : public Unit, public GridObject<Player> | |||
explicit Player(WorldSession* session); | |||
~Player(); | |||
|
|||
PlayerAI* AI() const { return (PlayerAI*)i_AI; } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
bbd9581
to
16ddde4
Compare
Change summary:
|
16ddde4
to
434a894
Compare
Looks good, well done |
125e7f5
to
2f14664
Compare
- Removed hacked control mechanism, use proper PlayerAI instead - Port old hacky code to new SimpleCharmedPlayerAI class - Make adjustments to aforementioned code to fix bugs: - Properly clean up movement after charm ends - Only try to attack a target if charmer is engaged in combat
Core/UnitAI: Rework creature-controlled player behavior.
Spells! We need Spells! 🎯 |
Sure, once we figure out #16687 so it looks less stupid when I make them cast. |
} | ||
} | ||
|
||
std::cout << "Selected " << rangedAttackSpell << std::endl; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Already fixed in 1fbe797
Core/UnitAI: Rework creature-controlled player behavior. (cherry picked from commit 4e4b2b9)
Core/UnitAI: Rework creature-controlled player behavior.
Fixes #4723.