* New roll for item action
* Add general roll command as well.
* Update ChatCommandHandlerStrategy.cpp
Add accidental removal of glyph equip
---------
Co-authored-by: bash <31279994+hermensbas@users.noreply.github.com>
Hello everyone,
I am on a quest to make bot's pets completely functional, focuses on solving issues #1351 , #1230 , and #1137 . This PR achieves the following:
1. Changes the current "pet" chat command to "tame", which is more intuitive that only hunters can use it. The modes are "tame name (name)", "tame id (id)", "tame family (family)", "tame rename (new name)", and "tame abandon". Tame abandon is new - it simply abandons the current pet. Also, now, if you type in "tame family" by itself, it will list the available families. See pictures below for examples.
2. Added new "pet" chat command, with the following modes: "pet passive", "pet aggressive", "pet defensive", "pet stance" (shows current pet stance), "pet attack", "pet follow", and "pet stay". Previously, the pet's stance was not changeable, and there were some less than desired effects from summonable pets - see the issues above.
3. New config option: AiPlayerbot.DefaultPetStance, which changes the stance that all bot's pets are summoned as. This makes sure when feral spirits or treants are summoned by shamans and druids, they are immediately set to this configured stance. Set as 1 as default, which is defensive. (0 = Passive, 1 = Defensive, 2 = Aggressive)
4. New config option: AiPlayerbot.PetChatCommandDebug, which enables debug messages for the "pet" chat command. By default it is set to 0, which is disabled, but if you would like to see when pet's stances are changed, or when you tell the pet to attack/follow/stay, and when pet spells are auto-toggled, this is an option. I made this for myself mainly to test the command - if anyone notices any wierd pet behavior, this will be an option to help them report it as well.
5. Modified FollowActions to not constantly execute the petfollow action, overriding any stay or attack commands issued.
6. Modified GenericActions to have TogglePetSpellAutoCastAction optionally log when spells are toggled based on AiPlayerbot.PetChatCommandDebug.
7. Modified PetAttackAction to not attack if the pet is set to passive, and not override the pet's stance to passive every time it was executed.
8. Modified CombatStrategy.cpp to not constantly issue the petattack command, respecting the "pet stay" and "pet follow" commands. Pets will still automatically attack the enemy if set to aggressive or defensive.
9. Warlocks, Priests, Hunters, Shamans, Mages, Druids, and DKs (all classes that have summons): Added a "new pet" trigger that executes the "set pet stance" action. The "new pet" trigger happens only once, upon summoning a pet. It sets the pet's stance from AiPlayerbot.DefaultPetStance's value.
Hello everyone,
I was working with hunter bots and I feel like I didn't have enough control over their pets. So I started working on a chat command for the hunter pets, and it's been a blast. Below is a description of what the commands do:
pet name <name>
Summons a tameable pet by its creature name (case-insensitive).
The bot checks if the pet is exotic and requires the Beast Mastery talent if so.
If successful, the bot announces the pet's new name and creature ID.
If not found or not tameable, an error message is given.
pet id <id>
Summons a tameable pet by its database creature ID.
The same exotic pet checks apply.
Success is announced with the pet's name and ID.
Errors are given for invalid IDs or untameable pets.
pet family <family>
Randomly selects and summons a tameable pet from the specified family (e.g., "cat", "wolf").
Only families with tameable pets are considered.
Exotic pet checks and talent requirements apply.
Success is announced with the pet's name and ID.
Errors are given if no suitable pet is found.
pet rename <new name>
Renames the hunter's current summoned pet to a new name.
The name must be 1-12 alphabetic characters (A-Z, a-z) and is automatically formatted (first letter capitalized, rest lowercased).
Forbidden or reserved names are disallowed.
After renaming, the bot sets the new name, saves the pet, and updates the client.
The bot dismisses and attempts to recall the pet using "Call Pet" (if the hunter knows it) to update the UI.
If the new name isn't visible immediately, the bot instructs the player to dismiss and recall the pet manually.
Confirmation and guidance messages are provided.
Additional Details:
All commands display errors if requirements are not met (wrong name/id/family, forbidden name, lack of Beast Mastery, or hunter below level 10).
After changing or summoning a pet (except renaming), the bot initializes the pet and its talents, then announces the result.
TLDR:
pet name <name> Summon a tameable pet by name
pet id <id> Summon a tameable pet by database creature ID
pet family <family> Randomly summon a tameable pet of the given family
pet rename <new name> Rename the current pet and refresh its name in the client UI
Description of files changed:
src\strategy\actions\ChatActionContext.h: Added the "pet" action for the whisper command.
src\strategy\actions\PetAction.cpp: New chat actions for all things related to hunter pets.
src\strategy\actions\PetAction.h: New header for the PetAction.cpp.
src\strategy\generic\ChatCommandHandlerStrategy.cpp: Linked the trigger and action in the chatcommandhandlerstrategy, for the bot to take action when whispered "pet" (trigger).
src\strategy\triggers\ChatTriggerContext.h: Added the "pet" trigger.
* CMaNGOS Playerbots "lfg" command implemented
* Remove logging, fix warning, add suggestion
- Remove LOG_INFO's console clutter, since 'lfg' command is working correctly now.
- Warning C26813 fixed for: placeholders["%role"] = (role == BOT_ROLE_TANK ? "tank" : (role == BOT_ROLE_HEALER ? "healer" : "dps"));
- Added suggestion to let bots do autogear & maintenance, so players can instantly start their dungeon or raid activities without manually having to configure the playerbots gear. It could save a lot of time. This is up to discussion for playerbots maintainers.
* New rpg startup speed up and refactor
* New rpg do quest
* Fix invalid height in quest poi
* Add quest accept and reward limitation
* New rpg quest improvement
* Organize quest log, reward quests and fix grind target
* Quest dropped statistic and remove redundant code
* Decrease grind relevance lower than loot
* Fix new rpg drop quest
* Go to reward quest instead of innkeeper when quest completed
* Fix incorrect logic in do quest reward
* Fix reset quests in factory
* Fix crash on grind target value
Co-authored-by: SaW <swerkhoven@outlook.com>
* Fix a minor error in DoCompletedQuest
* Let bots get rid of impossible quests faster
* Increase loot fluency (especially for caster)
* Remove seasonal quests from auto accept
* Enhance quest accept condition check
* Add questgiver check (limit acceptation of quest 7946)
* Questgiver check and localization
* Near npc fix
* Fix quest item report
* Add lowPriorityQuest set for quests can not be done
* Improve gameobjects loot
* Do complete quest
* FIx move far to teleport check
* Accept or reward quest from game objects
* Fix possible crash in rpg game objects
* Fix ChooseNpcOrGameObjectToInteract crash
---------
Co-authored-by: SaW <swerkhoven@outlook.com>
PlayerbotAI::FindOilFor was making the server randomly crashing
ChooseTravelTargetAction::getNewTarget: when active bot groupping was making the server crash as looking for unexisting params
Several bug fixes and tweak to Quest and Group
New fucntionnality:
Bots will now share quests randomly to their party
Bots will try to accomplish group member quest before moving on to new target
Bots will try to sells items only after few levels ( 5 ) when in group
When dropping a quest bots will try to select a new one they are on instead of idling for few time
Bots will no longuer try to invite themselfs to group or if group is full
Bots are now allowed to leave party by themself
Bots in groupe if not leader are forbbiden to tag in bgs
Bots in bot-groups no have a more limited range to look for grind target
Polish logs