Move SendCommandHelpWindow to SendBotCommandHelpWindow and simplify

This commit is contained in:
nytmyr
2025-01-22 15:11:13 -06:00
parent 2301b91e77
commit e9d809301c
39 changed files with 620 additions and 1428 deletions
+5 -29
View File
@@ -4,16 +4,14 @@ void bot_command_actionable(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_actionable", sep->arg[0], "actionable")) {
c->Message(Chat::White, "note: Lists actionable command arguments and use descriptions");
return;
}
std::vector<std::string> description =
{
"Lists actionable command arguments and use descriptions."
};
BotCommandHelpParams p;
std::vector<std::string> notes =
{
p.description = { "Lists actionable command arguments and use descriptions." };
p.notes = {
"[target] - uses the command on the target. Some commands will default to target if no actionable is selected.",
"[byname] [name] - selects a bot by name their name.",
"[ownergroup] - selects all bots in the owner's group.",
@@ -32,29 +30,7 @@ void bot_command_actionable(Client* c, const Seperator* sep)
"You may only select your own bots."
};
std::vector<std::string> example_format = { };
std::vector<std::string> examples_one = { };
std::vector<std::string> examples_two = { };
std::vector<std::string> examples_three = { };
std::vector<std::string> actionables = { };
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+19 -50
View File
@@ -3,67 +3,36 @@
void bot_command_behind_mob(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_behind_mob", sep->arg[0], "behindmob")) {
c->Message(Chat::White, "note: Toggles whether or not bots will stay behind the mob during combat.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"-Toggles whether or not bots will stay behind the mob during combat."
BotCommandHelpParams p;
p.description = { "Toggles whether or not bots will stay behind the mob during combat." };
p.example_format = {
fmt::format("{} [value] [actionable]", sep->arg[0])
};
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
{
fmt::format(
"{} [value] [actionable]"
, sep->arg[0]
)
p.examples_one = {
"To set Monks to stay behind the mob:",
fmt::format("{} 1 byclass 7", sep->arg[0])
};
std::vector<std::string> examples_one =
{
"To set Monks to stay behind the mob:",
fmt::format(
"{} 1 byclass 7",
sep->arg[0]
)
p.examples_two = {
"To force all bots to stay behind mobs:",
fmt::format("{} 1 spawned", sep->arg[0])
};
std::vector<std::string> examples_two = { };
std::vector<std::string> examples_three =
{
"To check the behind mob status for all bots:",
fmt::format(
"{} current spawned",
sep->arg[0]
)
p.examples_three = {
"To check the behind mob status of all bots:",
fmt::format("{} current spawned", sep->arg[0])
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
if (RuleB(Bots, SendClassRaceOnHelp)) {
c->Message(
+42 -95
View File
@@ -8,72 +8,35 @@ void bot_command_blocked_buffs(Client* c, const Seperator* sep)
return;
}
if (helper_command_alias_fail(c, "bot_command_blocked_buffs", sep->arg[0], "blockedbuffs")) {
c->Message(Chat::White, "note: Allows you to set, view and wipe blocked buffs for the selected bots.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Allows you to set, view and wipe blocked buffs for the selected bots"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
{
"- You can 'set' spells to be blocked, 'remove' spells from the blocked list, 'list' the current blocked spells or 'wipe' the entire list."
p.description = { "Allows you to set, view and wipe blocked buffs for the selected bots." };
p.notes = { "- You can 'set' spells to be blocked, 'remove' spells from the blocked list, 'list' the current blocked spells or 'wipe' the entire list." };
p.example_format = {
fmt::format("{} [add [ID] | remove [ID] | list | wipe] [actionable, default: target]", sep->arg[0])
};
p.examples_one = {
"To add Courage(Spell ID #202) to the targeted bot's blocked list:",
fmt::format("{} add 202", sep->arg[0])
};
p.examples_two = {
"To view the targeted bot's blocked buff list:",
fmt::format("{} list", sep->arg[0])
};
p.examples_three = {
"To wipe all Warriors bots' blocked buff list:",
fmt::format( "{} wipe byclass {}", sep->arg[0], Class::Warrior)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> example_format =
{
fmt::format(
"{} [add [ID] | remove [ID] | list | wipe] [actionable, default: target]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
{
"To add Courage (Spell ID #202) to the targeted bot's blocked list:",
fmt::format(
"{} add 202",
sep->arg[0],
c->GetSpellTypeShortNameByID(BotSpellTypes::Nuke)
)
};
std::vector<std::string> examples_two =
{
"To view the targeted bot's blocked buff list:",
fmt::format(
"{} list",
sep->arg[0]
)
};
std::vector<std::string> examples_three =
{
"To wipe all Warriors bots' blocked buff list:",
fmt::format(
"{} wipe byclass {}",
sep->arg[0],
Class::Warrior
)
};
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
@@ -265,26 +228,29 @@ void bot_command_blocked_pet_buffs(Client* c, const Seperator* sep)
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Allows you to set, view and wipe blocked pet buffs for the selected bots"
};
if (helper_command_alias_fail(c, "bot_command_blocked_pet_buffs", sep->arg[0], "blockedpetbuffs")) {
c->Message(Chat::White, "note: Allows you to set, view and wipe blocked pet buffs for the selected bots.");
std::vector<std::string> notes =
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
BotCommandHelpParams p;
p.description = { "Allows you to set, view and wipe blocked pet buffs for the selected bots." };
p.notes =
{
"- You can 'set' spells to be blocked, 'remove' spells from the blocked list, 'list' the current blocked spells or 'wipe' the entire list.",
"- This controls whether or not any pet the selected bot(s) own will prevent certain buffs from being cast."
"- This controls whether or not any pet the selected bot(s) own will prevent certain beneficial buffs from landing on them."
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [add [ID] | remove [ID] | list | wipe] [actionable, default: target]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To add Courage (Spell ID #202) to the targeted bot's blocked list:",
fmt::format(
@@ -293,7 +259,7 @@ void bot_command_blocked_pet_buffs(Client* c, const Seperator* sep)
c->GetSpellTypeShortNameByID(BotSpellTypes::Nuke)
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To view the targeted bot's blocked buff list:",
fmt::format(
@@ -301,7 +267,7 @@ void bot_command_blocked_pet_buffs(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To wipe all Warriors bots' blocked buff list:",
fmt::format(
@@ -310,28 +276,9 @@ void bot_command_blocked_pet_buffs(Client* c, const Seperator* sep)
Class::Warrior
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+66 -134
View File
@@ -472,82 +472,43 @@ void bot_command_delete(Client *c, const Seperator *sep)
void bot_command_follow_distance(Client *c, const Seperator *sep)
{
if (helper_command_alias_fail(c, "bot_command_follow_distance", sep->arg[0], "botfollowdistance")) {
c->Message(Chat::White, "note: Sets or resets the follow distance of the selected bots.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Sets or resets the follow distance of the selected bots."
};
BotCommandHelpParams p;
std::vector<std::string> notes =
p.description = { "Sets or resets the follow distance of the selected bots." };
p.notes =
{
fmt::format(
"[Default]: {}",
RuleI(Bots, MaxFollowDistance)
),
fmt::format(
"- You must use a value between 1 and {}.",
RuleI(Bots, MaxFollowDistance)
)
fmt::format("[Default]: {}", RuleI(Bots, MaxFollowDistance)),
fmt::format("- You must use a value between 1 and {}.", RuleI(Bots, MaxFollowDistance))
};
std::vector<std::string> example_format =
{
fmt::format(
"{} [reset]/[set [value]] [actionable]"
, sep->arg[0]
)
p.example_format = {
fmt::format("{} [reset]/[set [value]] [actionable]", sep->arg[0])
};
std::vector<std::string> examples_one =
{
"To set all bots to follow at a distance of 25:",
fmt::format(
"{} set 25 spawned",
sep->arg[0]
)
p.examples_one = {
"To set all bots to follow at a distance of 25:",
fmt::format("{} set 25 spawned", sep->arg[0])
};
std::vector<std::string> examples_two =
{
"To check the curret following distance of all bots:",
fmt::format(
"{} current spawned",
sep->arg[0]
)
p.examples_two = {
"To check the curret following distance of all bots:",
fmt::format("{} current spawned", sep->arg[0])
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To reset the following distance of all Wizards:",
fmt::format(
"{} reset byclass {}",
sep->arg[0],
Class::Wizard
)
)
};
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
@@ -1187,17 +1148,16 @@ void bot_command_spawn(Client *c, const Seperator *sep)
void bot_command_stance(Client *c, const Seperator *sep)
{
if (helper_command_alias_fail(c, "bot_command_stance", sep->arg[0], "botstance")) {
c->Message(Chat::White, "note: Change a bot's stance to control the way it behaves.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Change a bot's stance to control the way it behaves."
};
BotCommandHelpParams p;
std::vector<std::string> notes =
{
p.description = { "Change a bot's stance to control the way it behaves." };
p.notes = {
"- <b>Changing a stance will reset all settings to match that stance type.</b>",
"- Any changes made will only save to that stance for future use.",
fmt::format(
@@ -1225,102 +1185,74 @@ void bot_command_stance(Client *c, const Seperator *sep)
Stance::AEBurn
),
"<br>",
fmt::format(
"- {} (#{}) [Default] - Overall balance and casts most spell types by default.",
Stance::GetName(Stance::Balanced),
Stance::Balanced
),
fmt::format(
"- {} (#{}) - Idle. Does not cast or engage in combat.",
Stance::GetName(Stance::Passive),
Stance::Passive
),
fmt::format(
"- {} (#{}) - More mana and aggro efficient (SKs will still cast hate line). Longer delays between detrimental spells, thresholds adjusted to cast less often.",
Stance::GetName(Stance::Efficient),
Stance::Efficient
),
fmt::format(
"- {} (#{}) - Much more aggressive in their cast times and thresholds. More DPS, debuffs and slow but a higher risk of snagging aggro.",
Stance::GetName(Stance::Aggressive),
Stance::Aggressive
fmt::format(
"- {} (#{}) [Default] - Overall balance and casts most spell types by default.",
Stance::GetName(Stance::Balanced),
Stance::Balanced
),
fmt::format(
"- {} (#{}) - Support role. Most offensive spell types are disabled. Focused on heals, cures, CC, debuffs and slows.",
Stance::GetName(Stance::Assist),
Stance::Assist
"- {} (#{}) - Idle. Does not cast or engage in combat.",
Stance::GetName(Stance::Passive),
Stance::Passive
),
fmt::format(
"- {} (#{}) - Murder. Doesn't care about aggro, just wants to kill. DPS Machine.",
Stance::GetName(Stance::Burn),
Stance::Burn
"- {} (#{}) - More mana and aggro efficient (SKs will still cast hate line). Longer delays between detrimental spells, thresholds adjusted to cast less often.",
Stance::GetName(Stance::Efficient),
Stance::Efficient
),
fmt::format(
"- {} (#{}) - Murder EVERYTHING. Doesn't care about aggro, casts AEs. Everything must die ASAP.",
Stance::GetName(Stance::AEBurn),
Stance::AEBurn
"- {} (#{}) - Much more aggressive in their cast times and thresholds. More DPS, debuffs and slow but a higher risk of snagging aggro.",
Stance::GetName(Stance::Aggressive),
Stance::Aggressive
),
fmt::format(
"- {} (#{}) - Support role. Most offensive spell types are disabled. Focused on heals, cures, CC, debuffs and slows.",
Stance::GetName(Stance::Assist),
Stance::Assist
),
fmt::format(
"- {} (#{}) - Murder. Doesn't care about aggro, just wants to kill. DPS Machine.",
Stance::GetName(Stance::Burn),
Stance::Burn
),
fmt::format(
"- {} (#{}) - Murder EVERYTHING. Doesn't care about aggro, casts AEs. Everything must die ASAP.",
Stance::GetName(Stance::AEBurn),
Stance::AEBurn
)
};
std::vector<std::string> example_format =
{
fmt::format(
"{} [current | value: {}-{}]",
p.example_format = {
fmt::format( "{} [current | value: {}-{}]",
sep->arg[0],
Stance::Passive,
Stance::AEBurn
)
};
std::vector<std::string> examples_one =
{
"To set all bots to BurnAE:",
fmt::format(
"{} {} spawned {}",
p.examples_one = {
"To set all bots to BurnAE:",
fmt::format("{} {} spawned {}",
sep->arg[0],
Stance::Aggressive,
Class::ShadowKnight
)
};
std::vector<std::string> examples_two =
{
"To set all Shadowknights to Aggressive:",
fmt::format(
"{} {} byclass {}",
p.examples_two = {
"To set all Shadowknights to Aggressive:",
fmt::format("{} {} byclass {}",
sep->arg[0],
Stance::Aggressive,
Class::ShadowKnight
)
};
std::vector<std::string> examples_three =
{
"To check the current stances of all bots:",
fmt::format(
"{} current spawned",
sep->arg[0]
)
p.examples_three = {
"To check the current stances of all bots:",
fmt::format("{} current spawned", sep->arg[0])
};
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
-1
View File
@@ -19,7 +19,6 @@ void bot_command_bot_settings(Client* c, const Seperator* sep)
"sithppercent",
"sitincombat",
"sitmanapercent",
"sithppercent",
"spellaggrocheck",
"spelldelays",
"spellengagedpriority",
+24 -40
View File
@@ -2,13 +2,17 @@
void bot_command_cast(Client* c, const Seperator* sep)
{
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Commands bots to force cast a specific spell type, ignoring all settings (holds, delays, thresholds, etc)"
};
if (helper_command_alias_fail(c, "bot_command_cast", sep->arg[0], "cast")) {
c->Message(Chat::White, "note: Commands bots to force cast a specific spell type, ignoring all settings (holds, delays, thresholds, etc).");
std::vector<std::string> notes =
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
BotCommandHelpParams p;
p.description = { "Commands bots to force cast a specific spell type, ignoring all settings (holds, delays, thresholds, etc)." };
p.notes =
{
"- This will interrupt any spell currently being cast by bots told to use the command",
"- Bots will still check to see if they have the spell in their spell list, whether the target is immune, spell is allowed and all other sanity checks for spells",
@@ -19,19 +23,12 @@ void bot_command_cast(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [Type Shortname] [actionable, default: spawned]"
, sep->arg[0]
),
fmt::format(
"{} [Type ID] [actionable, default: spawned]"
, sep->arg[0]
)
fmt::format("{} [Type Shortname] [actionable, default: spawned]", sep->arg[0]),
fmt::format("{} [Type ID] [actionable, default: spawned]", sep->arg[0])
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To tell everyone to Nuke the target:",
fmt::format(
@@ -45,7 +42,7 @@ void bot_command_cast(Client* c, const Seperator* sep)
BotSpellTypes::Nuke
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To tell Skbot to Harm Touch the target:",
fmt::format(
@@ -57,7 +54,7 @@ void bot_command_cast(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To tell all bots to try to cast spell #93 (Burst of Flame)",
fmt::format(
@@ -65,28 +62,10 @@ void bot_command_cast(Client* c, const Seperator* sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
@@ -609,7 +588,12 @@ void bot_command_cast(Client* c, const Seperator* sep)
type = "Forced";
}
else {
type = c->GetSpellTypeNameByID(spell_type);
if (sub_type == UINT16_MAX) {
type = c->GetSpellTypeNameByID(spell_type);
}
else {
type = c->GetSubTypeNameByID(sub_type);
}
}
if (!is_success) {
+17 -38
View File
@@ -3,28 +3,30 @@
void bot_command_copy_settings(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_copy_settings", sep->arg[0], "copysettings")) {
c->Message(Chat::White, "note: Copies settings from one bot to another.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Copies settings from one bot to another bot"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
p.description =
{
"Copies settings from one bot to another."
};
p.notes =
{
"- You can put a spell type ID or shortname after any option except [all], [misc] and [spellsettings] to restore that specifc spell type only"
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [from] [to] [option]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To copy all settings from BotA to BotB:",
fmt::format(
@@ -32,7 +34,7 @@ void bot_command_copy_settings(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To copy only Nuke spelltypesettings from BotA to BotB:",
fmt::format(
@@ -46,45 +48,22 @@ void bot_command_copy_settings(Client* c, const Seperator* sep)
c->GetSpellTypeShortNameByID(BotSpellTypes::Nuke)
),
};
std::vector<std::string> examples_three = { };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options =
{
"[all], [misc], [spellsettings], [spelltypesettings], [spellholds], [spelldelays], [spellminthresholds], [spellmaxthresholds], [spellminmanapct], [spellmaxmanapct], [spellminhppct], [spellmaxhppct], [spellidlepriority], [spellengagedpriority], [spellpursuepriority], [spellaggrochecks], [spelltargetcounts], [sithppercent], [sitmanapercent], [blockedbuffs], [blockedpetbuffs]"
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
p.options = { "[all], [misc], [spellsettings], [spelltypesettings], [spellholds], [spelldelays], [spellminthresholds], [spellmaxthresholds], [spellminmanapct], [spellmaxmanapct], [spellminhppct], [spellmaxhppct], [spellidlepriority], [spellengagedpriority], [spellpursuepriority], [spellaggrochecks], [spelltargetcounts], [sithppercent], [sitmanapercent], [blockedbuffs], [blockedpetbuffs]" };
std::vector<std::string> options_one =
{
"[spellsettings] will copy ^spellsettings options",
"[spelltypesettings] copies all spell type settings",
"[all] copies all settings"
"[all] copies all settings"
};
std::vector<std::string> options_two =
{
"[misc] copies all miscellaneous options such as:",
"- ^showhelm, ^followd, ^stopmeleelevel, ^enforcespellsettings, ^bottoggleranged, ^petsettype, ^behindmob, ^distanceranged, ^illusionblock, ^sitincombat, ^sithppercent, ^sitmanapercent, ^blockedbuffs, ^blockedpetbuffs",
};
std::vector<std::string> options_three =
{
"The remaining options copy that specific type"
"- ^showhelm, ^followd, ^stopmeleelevel, ^enforcespellsettings, ^bottoggleranged, ^petsettype, ^behindmob, ^distanceranged, ^illusionblock, ^sitincombat, ^sithppercent, ^sitmanapercent, ^blockedbuffs, ^blockedpetbuffs"
};
std::vector<std::string> options_three = { "The remaining options copy that specific type" };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+15 -45
View File
@@ -3,28 +3,21 @@
void bot_command_default_settings(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_default_settings", sep->arg[0], "defaultsettings")) {
c->Message(Chat::White, "note: Restores a bot's setting(s) to defaults.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Restores a bot's setting(s) to defaults"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
{
"- You can put a spell type ID or shortname after any option except [all], [misc] and [spellsettings] to restore that specifc spell type only"
};
std::vector<std::string> example_format =
p.description = { "Restores a bot's setting(s) to defaults" };
p.notes = { "- You can put a spell type ID or shortname after any option except [all], [misc] and [spellsettings] to restore that specifc spell type only"};
p.example_format =
{
fmt::format(
"{} [option] [actionable]"
, sep->arg[0]
)
fmt::format("{} [option] [actionable]", sep->arg[0])
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To restore delays for Clerics:",
fmt::format(
@@ -32,7 +25,7 @@ void bot_command_default_settings(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To restore only Snare delays for BotA:",
fmt::format(
@@ -46,48 +39,25 @@ void bot_command_default_settings(Client* c, const Seperator* sep)
BotSpellTypes::Snare
)
};
std::vector<std::string> examples_three = { };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options =
{
"all, misc, spellsettings, spelltypesettings, holds, delays, minthresholds, maxthresholds minmanapct, maxmanapct, minhppct, maxhppct, idlepriority, engagedpriority, pursuepriority, aggrocheck, targetcounts"
};
std::vector<std::string> options_one =
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
p.options = { "all, misc, spellsettings, spelltypesettings, holds, delays, minthresholds, maxthresholds minmanapct, maxmanapct, minhppct, maxhppct, idlepriority, engagedpriority, pursuepriority, aggrocheck, targetcounts" };
p.options_one =
{
"[spellsettings] will restore ^spellsettings options",
"[spelltypesettings] restores all spell type settings",
"[all] restores all settings"
};
std::vector<std::string> options_two =
p.options_two =
{
"[misc] restores all miscellaneous options such as:",
"- ^showhelm, ^followd, ^stopmeleelevel",
"- ^enforcespellsettings, ^bottoggleranged, ^petsettype",
"- ^behindmob, ^distanceranged, ^illusionblock",
"- ^sitincombat, ^sithppercent and ^sitmanapercent",
};
std::vector<std::string> options_three =
{
"The remaining options restore that specific type"
};
p.options_three = { "The remaining options restore that specific type" };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+16 -38
View File
@@ -2,26 +2,23 @@
void bot_command_depart(Client* c, const Seperator* sep)
{
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Tells bots to list their port locations or port to a specific location"
};
if (helper_command_alias_fail(c, "bot_command_depart", sep->arg[0], "depart")) {
c->Message(Chat::White, "note: Tells bots to list their port locations or port to a specific location.");
std::vector<std::string> notes =
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
BotCommandHelpParams p;
p.description = { "Tells bots to list their port locations or port to a specific location." };
p.notes =
{
"- This will interrupt any spell currently being cast by bots told to use the command.",
"- Bots will still check to see if they have the spell in their spell list, whether the target is immune, spell is allowed and all other sanity checks for spells"
};
std::vector<std::string> example_format =
{
fmt::format(
"{} [list | zone shortname] [optional: single | group | ae] [actionable, default: spawned]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.example_format = { fmt::format("{} [list | zone shortname] [optional: single | group | ae] [actionable, default: spawned]", sep->arg[0]) };
p.examples_one =
{
"To tell everyone to list their portable locations:",
fmt::format(
@@ -29,7 +26,7 @@ void bot_command_depart(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To tell all bots to port to Nexus:",
fmt::format(
@@ -37,7 +34,7 @@ void bot_command_depart(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To tell Druidbot to single target port to Butcher:",
fmt::format(
@@ -45,28 +42,9 @@ void bot_command_depart(Client* c, const Seperator* sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+15 -35
View File
@@ -3,25 +3,24 @@
void bot_command_discipline(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_discipline", sep->arg[0], "discipline")) {
c->Message(Chat::White, "note: Tells applicable bots to use the specified disciplines.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Tells applicable bots to use the specified disciplines"
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
p.description =
{
fmt::format(
"{} [aggressive | defensive | spell ID] [actionable, default: spawned]"
, sep->arg[0]
)
"Tells applicable bots to use the specified disciplines."
};
std::vector<std::string> examples_one =
p.notes = { "Aside from Lay On Hands and Harm Touch, you will need to know the spell ID of the discipline to tell a bot to attempt to use it." };
p.example_format =
{
fmt::format("{} [aggressive | defensive | spell ID] [actionable, default: spawned]", sep->arg[0])
};
p.examples_one =
{
"To tell all bots to use an aggressive discipline:",
fmt::format(
@@ -29,7 +28,7 @@ void bot_command_discipline(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To tell Warrior bots to use a defensive discipline:",
fmt::format(
@@ -38,7 +37,7 @@ void bot_command_discipline(Client* c, const Seperator* sep)
Class::Warrior
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To tell all bots to use their Fearless discipline:",
fmt::format(
@@ -46,28 +45,9 @@ void bot_command_discipline(Client* c, const Seperator* sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+55 -1
View File
@@ -3,16 +3,70 @@
void bot_command_distance_ranged(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_distance_ranged", sep->arg[0], "distanceranged")) {
c->Message(Chat::White, "note: Sets the distance bots will attempt to stay away from their target to cast or use ranged items.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
BotCommandHelpParams p;
p.description = { "Sets the distance bots will attempt to stay away from their target to cast or use ranged items." };
p.notes =
{
"- Bots will stay between half the value of the setting and the current value. IE, if set to 60, bots will stay between 30 and 60.",
"- Casters will never go closer than their maximum melee range.",
"- Throwing bots will never get closer than the minimum value for ranged to work, or beyond the range of their items."
};
p.example_format = {
fmt::format("{} [value] [actionable]", sep->arg[0])
};
p.examples_one = {
"To set Wizards to a range of 100:",
fmt::format(
"{} 100 byclass {}",
sep->arg[0],
Class::Wizard
)
};
p.examples_two = {
"To set Rangers to a range of 175:",
fmt::format(
"{} 175 byclass {}",
sep->arg[0],
Class::Ranger
)
};
p.examples_three = {
"To view the current setting of all bots:",
fmt::format(
"{} current spawned",
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
if (RuleB(Bots, SendClassRaceOnHelp)) {
c->Message(
Chat::Yellow,
fmt::format(
"Use {} for information about race/class IDs.",
Saylink::Silent("^classracelist")
).c_str()
);
}
return;
c->Message(Chat::White, "usage: %s [current | value: 0 - 300] ([actionable: target | byname | ownergroup | ownerraid | targetgroup | namesgroup | healrotationtargets | mmr | byclass | byrace | spawned] ([actionable_name]))", sep->arg[0]);
c->Message(Chat::White, "note: Use [current] to check the current setting.");
c->Message(Chat::White, "note: Set the value to the minimum distance you want your bot to try to remain from its target.");
c->Message(Chat::White, "note: If they are too far for a spell, it will be skipped.");
c->Message(Chat::White, "note: This is set to (90) units by default.");
return;
}
const int ab_mask = ActionableBots::ABM_Type1;
+11 -40
View File
@@ -3,28 +3,18 @@
void bot_command_follow(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_follow", sep->arg[0], "follow")) {
c->Message(Chat::White, "note: Sets bots of your choosing to follow your target, view their current following state or reset their following state.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Sets bots of your choosing to follow your target, view their current following state or reset their following state."
};
BotCommandHelpParams p;
std::vector<std::string> notes =
{
"- You can only follow players, bots or mercenaries belonging to your group or raid."
};
std::vector<std::string> example_format =
{
fmt::format(
"{} [optional] [actionable]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.description = { "Sets bots of your choosing to follow your target, view their current following state or reset their following state." };
p.notes = { "- You can only follow players, bots or mercenaries belonging to your group or raid." };
p.example_format = { fmt::format("{} [optional] [actionable]", sep->arg[0]) };
p.examples_one =
{
"To set all Clerics to follow your target:",
fmt::format(
@@ -33,7 +23,7 @@ void bot_command_follow(Client* c, const Seperator* sep)
Class::Cleric
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To check the current state of all bots:",
fmt::format(
@@ -41,7 +31,7 @@ void bot_command_follow(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To reset all bots:",
fmt::format(
@@ -49,28 +39,9 @@ void bot_command_follow(Client* c, const Seperator* sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+17 -37
View File
@@ -3,25 +3,17 @@
void bot_command_illusion_block(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_illusion_block", sep->arg[0], "illusionblock")) {
c->Message(Chat::White, "note: Toggles whether or not bots will block the illusion effects of spells cast by players or bots.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Toggles whether or not bots will block the illusion effects of spells cast by players or bots."
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
{
fmt::format(
"{} [value] [actionable]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.description = { "Toggles whether or not bots will block the illusion effects of spells cast by players or bots." };
p.example_format = { fmt::format("{} [value] [actionable]", sep->arg[0]) };
p.examples_one =
{
"To set BotA to block illusions:",
fmt::format(
@@ -29,8 +21,15 @@ void bot_command_illusion_block(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two = { };
std::vector<std::string> examples_three =
p.examples_two =
{
"To set all bots to block illusions:",
fmt::format(
"{} 1 spawned",
sep->arg[0]
)
};
p.examples_three =
{
"To check the illusion block status for all bots:",
fmt::format(
@@ -38,28 +37,9 @@ void bot_command_illusion_block(Client* c, const Seperator* sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+18 -38
View File
@@ -3,25 +3,17 @@
void bot_command_max_melee_range(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_max_melee_range", sep->arg[0], "maxmeleerange")) {
c->Message(Chat::White, "note: Toggles whether or not bots will stay at max melee range during combat.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Toggles whether or not bots will stay at max melee range during combat."
};
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
{
fmt::format(
"{} [value] [actionable]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
BotCommandHelpParams p;
p.description = { "Toggles whether or not bots will stay at max melee range during combat."};
p.example_format ={ fmt::format("{} [value] [actionable]", sep->arg[0]) };
p.examples_one =
{
"To set BotA to stay at max melee range:",
fmt::format(
@@ -29,8 +21,15 @@ void bot_command_max_melee_range(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two = { };
std::vector<std::string> examples_three =
p.examples_two =
{
"To set all bots to stay at max melee range:",
fmt::format(
"{} 1 spawned",
sep->arg[0]
)
};
p.examples_three =
{
"To check the max melee range status for all bots:",
fmt::format(
@@ -38,28 +37,9 @@ void bot_command_max_melee_range(Client* c, const Seperator* sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+10 -37
View File
@@ -97,25 +97,17 @@ void bot_command_pet_remove(Client *c, const Seperator *sep)
void bot_command_pet_set_type(Client *c, const Seperator *sep)
{
if (helper_command_alias_fail(c, "bot_command_pet_set_type", sep->arg[0], "petsettype")) {
c->Message(Chat::White, "note: Allows you to change the type of pet Magician bots will cast.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Allows you to change the type of pet Magician bots will cast"
};
BotCommandHelpParams p;
std::vector<std::string> notes = {};
std::vector<std::string> example_format =
{
fmt::format(
"{} [current | water | fire | air | earth | monster | epic] [actionable, default: target]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.description = { "Allows you to change the type of pet Magician bots will cast." };
p.example_format = { fmt::format("{} [current | water | fire | air | earth | monster | epic] [actionable, default: target]", sep->arg[0]) };
p.examples_one =
{
"To set all spawned bots to use Water pets:",
fmt::format(
@@ -123,7 +115,7 @@ void bot_command_pet_set_type(Client *c, const Seperator *sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set Magelulz to use Fire pets:",
fmt::format(
@@ -131,7 +123,7 @@ void bot_command_pet_set_type(Client *c, const Seperator *sep)
sep->arg[0]
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current pet type for all bots:",
fmt::format(
@@ -139,28 +131,9 @@ void bot_command_pet_set_type(Client *c, const Seperator *sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+13 -30
View File
@@ -2,41 +2,24 @@
void bot_command_set_assistee(Client* c, const Seperator* sep)
{
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Sets your bots to assist your target in addition to yourself"
};
if (helper_command_alias_fail(c, "bot_command_set_assistee", sep->arg[0], "setassistee")) {
c->Message(Chat::White, "note: Sets your bots to assist your target in addition to yourself.");
std::vector<std::string> notes =
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
BotCommandHelpParams p;
p.description = { "Sets your bots to assist your target in addition to yourself." };
p.notes =
{
"- Your target must be another player in your group or raid.",
"- This needs to be set on every zone/camp you do."
"- This needs to be set on every zone/camp you do.",
"- If a Raid or Group assist is set and you do not want your bots to auto assist that person, set yourself as the assistee."
};
std::vector<std::string> example_format = { };
std::vector<std::string> examples_one = { };
std::vector<std::string> examples_two = { };
std::vector<std::string> examples_three = { };
std::vector<std::string> actionables = { };
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+17 -37
View File
@@ -3,25 +3,17 @@
void bot_command_sit_hp_percent(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_sit_hp_percent", sep->arg[0], "sithppercent")) {
c->Message(Chat::White, "note: HP % threshold when bots will sit in combat if allowed.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"HP % threshold when bots will sit in combat if allowed."
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
{
fmt::format(
"{} [value] [actionable]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.description = { "HP % threshold when bots will sit in combat if allowed." };
p.example_format = { fmt::format("{} [value] [actionable]", sep->arg[0]) };
p.examples_one =
{
"To set Clerics to sit at 45% HP:",
fmt::format(
@@ -29,8 +21,15 @@ void bot_command_sit_hp_percent(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two = { };
std::vector<std::string> examples_three =
p.examples_two =
{
"To set all bots to sit at 50% HP:",
fmt::format(
"{} 50 spawned",
sep->arg[0]
)
};
p.examples_three =
{
"To check the HP threshold for all bots:",
fmt::format(
@@ -38,28 +37,9 @@ void bot_command_sit_hp_percent(Client* c, const Seperator* sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+17 -37
View File
@@ -3,25 +3,17 @@
void bot_command_sit_in_combat(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_sit_in_combat", sep->arg[0], "sitincombat")) {
c->Message(Chat::White, "note: Toggles whether or not bots will sit in combat to heal or med.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Toggles whether or not bots will sit in combat to heal or med."
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
{
fmt::format(
"{} [value] [actionable]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.description = { "Toggles whether or not bots will sit in combat to heal or med." };
p.example_format = { fmt::format("{} [value] [actionable]", sep->arg[0]) };
p.examples_one =
{
"To set Clerics to sit in combat:",
fmt::format(
@@ -29,8 +21,15 @@ void bot_command_sit_in_combat(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two = { };
std::vector<std::string> examples_three =
p.examples_two =
{
"To set all bots to sit/med in combat:",
fmt::format(
"{} 1 spawned",
sep->arg[0]
)
};
p.examples_three =
{
"To check the sit in combat state for all bots:",
fmt::format(
@@ -38,28 +37,9 @@ void bot_command_sit_in_combat(Client* c, const Seperator* sep)
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+19 -39
View File
@@ -3,63 +3,43 @@
void bot_command_sit_mana_percent(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_sit_mana_percent", sep->arg[0], "sitmanapercent")) {
c->Message(Chat::White, "note: Mana % threshold when bots will sit in combat if allowed.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Mana % threshold when bots will sit in combat if allowed."
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
p.description = { "Mana % threshold when bots will sit in combat if allowed." };
p.example_format = { fmt::format("{} [value] [actionable]", sep->arg[0]) };
p.examples_one =
{
fmt::format(
"{} [value] [actionable]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
{
"To set Clerics to sit at 45% mana:",
"To set Clerics to sit at 45% Mana:",
fmt::format(
"{} 45 byclass 2",
sep->arg[0]
)
};
std::vector<std::string> examples_two = { };
std::vector<std::string> examples_three =
p.examples_two =
{
"To check the mana threshold for all bots:",
"To set all bots to sit at 50% Mana:",
fmt::format(
"{} 50 spawned",
sep->arg[0]
)
};
p.examples_three =
{
"To check the Mana threshold for all bots:",
fmt::format(
"{} current spawned",
sep->arg[0]
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+10 -30
View File
@@ -3,18 +3,16 @@
void bot_command_spell_aggro_checks(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_aggro_checks", sep->arg[0], "spellaggrochecks")) {
c->Message(Chat::White, "note: Toggles whether or not bots will cast a spell type if they think it will get them aggro.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Toggles whether or not bots will cast a spell type if they think it will get them aggro"
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
p.description = { "Toggles whether or not bots will cast a spell type if they think it will get them aggro." };
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -25,7 +23,7 @@ void bot_command_spell_aggro_checks(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to check aggro on nukes:",
fmt::format(
@@ -39,7 +37,7 @@ void bot_command_spell_aggro_checks(Client* c, const Seperator* sep)
BotSpellTypes::Nuke
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set Shadowknights to ignore aggro checks on snares:",
fmt::format(
@@ -53,7 +51,7 @@ void bot_command_spell_aggro_checks(Client* c, const Seperator* sep)
BotSpellTypes::Snare
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current DoT aggro check on all bots:",
fmt::format(
@@ -68,27 +66,9 @@ void bot_command_spell_aggro_checks(Client* c, const Seperator* sep)
)
};
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+11 -31
View File
@@ -3,24 +3,23 @@
void bot_command_spell_delays(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_delays", sep->arg[0], "spelldelays")) {
c->Message(Chat::White, "note: Controls how long a bot will wait between casts of different spell types.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Controls how long a bot will wait between casts of different spell types"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
p.description = { "Controls how long a bot will wait between casts of different spell types." };
p.notes =
{
"- All pet types are based off the pet's owner's setting",
"- Any remaining types use the owner's setting when a pet is the target",
"- All Heals, Cures, Buffs (DS and resists included) are based off the target's setting, not the caster",
"- e.g., BotA is healing BotB using BotB's settings",
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -31,7 +30,7 @@ void bot_command_spell_delays(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all Necromancers to an 8s DoT delay:",
fmt::format(
@@ -45,7 +44,7 @@ void bot_command_spell_delays(Client* c, const Seperator* sep)
BotSpellTypes::DOT
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set all Warriors to receive Fast Heals every 2.5s:",
fmt::format(
@@ -59,7 +58,7 @@ void bot_command_spell_delays(Client* c, const Seperator* sep)
BotSpellTypes::FastHeals
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current Nuke delay on all bots:",
fmt::format(
@@ -73,28 +72,9 @@ void bot_command_spell_delays(Client* c, const Seperator* sep)
BotSpellTypes::Nuke
)
};
p.actionables = { "target, byname, ownergroup, ownerraid targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+11 -31
View File
@@ -3,22 +3,21 @@
void bot_command_spell_engaged_priority(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_engaged_priority", sep->arg[0], "spellengagedpriority")) {
c->Message(Chat::White, "note: Sets the order of spell casts when engaged in combat by spell type.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Sets the order of spell casts when engaged in combat by spell type"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
p.description = { "Sets the order of spell casts when engaged in combat by spell type." };
p.notes =
{
"- Setting a spell type to 0 will prevent that type from being cast.",
"- If 2 or more are set to the same priority they will sort by spell type ID."
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -29,7 +28,7 @@ void bot_command_spell_engaged_priority(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all Shaman to cast slows first:",
fmt::format(
@@ -43,7 +42,7 @@ void bot_command_spell_engaged_priority(Client* c, const Seperator* sep)
BotSpellTypes::Slow
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set all bots to not cast snares:",
fmt::format(
@@ -57,7 +56,7 @@ void bot_command_spell_engaged_priority(Client* c, const Seperator* sep)
BotSpellTypes::Snare
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current engaged priority of dispels on all bots:",
fmt::format(
@@ -71,28 +70,9 @@ void bot_command_spell_engaged_priority(Client* c, const Seperator* sep)
BotSpellTypes::Dispel
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+10 -34
View File
@@ -3,21 +3,17 @@
void bot_command_spell_holds(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_holds", sep->arg[0], "spellholds")) {
c->Message(Chat::White, "note: Toggles whether or not bots can cast certain spell types.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Toggles whether or not bots can cast certain spell types"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
{
"- All pet types are based off the pet owner's setting when a pet is the target"
};
std::vector<std::string> example_format =
p.description = { "Toggles whether or not bots can cast certain spell types." };
p.notes = { "- All pet types are based off the pet owner's setting when a pet is the target" };
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -28,7 +24,7 @@ void bot_command_spell_holds(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to hold DoTs:",
fmt::format(
@@ -42,7 +38,7 @@ void bot_command_spell_holds(Client* c, const Seperator* sep)
BotSpellTypes::DOT
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To check the current DoT settings on all bots:",
fmt::format(
@@ -56,29 +52,9 @@ void bot_command_spell_holds(Client* c, const Seperator* sep)
BotSpellTypes::DOT
)
};
std::vector<std::string> examples_three = { };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+11 -31
View File
@@ -3,22 +3,21 @@
void bot_command_spell_idle_priority(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_idle_priority", sep->arg[0], "spellidlepriority")) {
c->Message(Chat::White, "note: Sets the order of spell casts when not in combat by spell type.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Sets the order of spell casts when not in combat by spell type"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
p.description = { "Sets the order of spell casts when not in combat by spell type." };
p.notes =
{
"- Setting a spell type to 0 will prevent that type from being cast.",
"- If 2 or more are set to the same priority they will sort by spell type ID."
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -29,7 +28,7 @@ void bot_command_spell_idle_priority(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all Clerics to cast fast heals third:",
fmt::format(
@@ -43,7 +42,7 @@ void bot_command_spell_idle_priority(Client* c, const Seperator* sep)
BotSpellTypes::FastHeals
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set all bots to not cast cures:",
fmt::format(
@@ -57,7 +56,7 @@ void bot_command_spell_idle_priority(Client* c, const Seperator* sep)
BotSpellTypes::Cure
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current idle priority of buffs on all bots:",
fmt::format(
@@ -71,28 +70,9 @@ void bot_command_spell_idle_priority(Client* c, const Seperator* sep)
BotSpellTypes::Buff
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+12 -33
View File
@@ -3,18 +3,16 @@
void bot_command_spell_max_hp_pct(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_max_hp_pct", sep->arg[0], "spellmaxhppct")) {
c->Message(Chat::White, "note: Controls at what health percentage a bot will start casting different spell types.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Controls at what health percentage a bot will start casting different spell types"
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
p.description = { "Controls at what health percentage a bot will start casting different spell types." };
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -25,9 +23,9 @@ void bot_command_spell_max_hp_pct(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to start snaring when their health is at or below 100% HP:",
"To set all bots to allow snaring when their health is at or below 100% HP:",
fmt::format(
"{} {} 100 spawned",
sep->arg[0],
@@ -39,9 +37,9 @@ void bot_command_spell_max_hp_pct(Client* c, const Seperator* sep)
BotSpellTypes::Snare
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set BotA to start casting fast heals at 30% HP:",
"To set BotA to allow casting of fast heals at 30% HP:",
fmt::format(
"{} {} 30 byname BotA",
sep->arg[0],
@@ -53,7 +51,7 @@ void bot_command_spell_max_hp_pct(Client* c, const Seperator* sep)
BotSpellTypes::FastHeals
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current Stun max HP percent on all bots:",
fmt::format(
@@ -67,28 +65,9 @@ void bot_command_spell_max_hp_pct(Client* c, const Seperator* sep)
BotSpellTypes::Stun
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+14 -35
View File
@@ -3,18 +3,16 @@
void bot_command_spell_max_mana_pct(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_max_mana_pct", sep->arg[0], "spellmaxmanapct")) {
c->Message(Chat::White, "note: Controls at what mana percentage a bot will stop casting different spell types.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Controls at what mana percentage a bot will stop casting different spell types"
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
p.description = { "Controls at what mana percentage a bot will stop casting different spell types." };
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -25,9 +23,9 @@ void bot_command_spell_max_mana_pct(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to start snaring when their mana is at or below 100% HP:",
"To set all bots to allow snaring when their mana is at or below 100% HP:",
fmt::format(
"{} {} 10 spawned",
sep->arg[0],
@@ -39,21 +37,21 @@ void bot_command_spell_max_mana_pct(Client* c, const Seperator* sep)
BotSpellTypes::Snare
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set BotA to start casting fast heals at 30% mana:",
"To set BotA to allow casting of fast heals at 90% mana:",
fmt::format(
"{} {} 30 byname BotA",
"{} {} 90 byname BotA",
sep->arg[0],
c->GetSpellTypeShortNameByID(BotSpellTypes::FastHeals)
),
fmt::format(
"{} {} 30 byname BotA",
"{} {} 90 byname BotA",
sep->arg[0],
BotSpellTypes::FastHeals
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current Stun max mana percent on all bots:",
fmt::format(
@@ -67,28 +65,9 @@ void bot_command_spell_max_mana_pct(Client* c, const Seperator* sep)
BotSpellTypes::Stun
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+11 -31
View File
@@ -3,24 +3,23 @@
void bot_command_spell_max_thresholds(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_max_thresholds", sep->arg[0], "spellmaxthresholds")) {
c->Message(Chat::White, "note: Controls at what target HP % the bot will start casting different spell types.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Controls at what target HP % the bot will start casting different spell types"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
p.description = { "Controls at what target HP % the bot will start casting different spell types." };
p.notes =
{
"- All pet types are based off the pet's owner's setting",
"- Any remaining types use the owner's setting when a pet is the target",
"- All Heals, Cures, Buffs (DS and resists included) are based off the target's setting, not the caster",
"- e.g., BotA is healing BotB using BotB's settings",
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -31,7 +30,7 @@ void bot_command_spell_max_thresholds(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to start snaring at 99%:",
fmt::format(
@@ -45,7 +44,7 @@ void bot_command_spell_max_thresholds(Client* c, const Seperator* sep)
BotSpellTypes::Snare
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set bot Enchbot to start casting Debuffs at 99%:",
fmt::format(
@@ -59,7 +58,7 @@ void bot_command_spell_max_thresholds(Client* c, const Seperator* sep)
BotSpellTypes::Debuff
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current Nuke max threshold on all bots:",
fmt::format(
@@ -73,28 +72,9 @@ void bot_command_spell_max_thresholds(Client* c, const Seperator* sep)
BotSpellTypes::Nuke
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+11 -32
View File
@@ -3,18 +3,16 @@
void bot_command_spell_min_hp_pct(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_min_hp_pct", sep->arg[0], "spellminhppct")) {
c->Message(Chat::White, "note: Controls at what health percentage a bot will stop casting different spell types.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Controls at what health percentage a bot will stop casting different spell types"
};
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
BotCommandHelpParams p;
p.description = { "Controls at what health percentage a bot will stop casting different spell types." };
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -25,7 +23,7 @@ void bot_command_spell_min_hp_pct(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to stop snaring when their health is below 10% HP:",
fmt::format(
@@ -39,7 +37,7 @@ void bot_command_spell_min_hp_pct(Client* c, const Seperator* sep)
BotSpellTypes::Snare
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set BotA to stop casting fast heals at 30% HP:",
fmt::format(
@@ -53,7 +51,7 @@ void bot_command_spell_min_hp_pct(Client* c, const Seperator* sep)
BotSpellTypes::FastHeals
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current Stun min HP percent on all bots:",
fmt::format(
@@ -67,28 +65,9 @@ void bot_command_spell_min_hp_pct(Client* c, const Seperator* sep)
BotSpellTypes::Stun
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+11 -32
View File
@@ -3,18 +3,16 @@
void bot_command_spell_min_mana_pct(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_min_mana_pct", sep->arg[0], "spellminmanapct")) {
c->Message(Chat::White, "note: Controls at what mana percentage a bot will stop casting different spell types.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Controls at what mana percentage a bot will stop casting different spell types"
};
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
BotCommandHelpParams p;
p.description = { "Controls at what mana percentage a bot will stop casting different spell types." };
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -25,7 +23,7 @@ void bot_command_spell_min_mana_pct(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to stop snaring when their mana is below 10% HP:",
fmt::format(
@@ -39,7 +37,7 @@ void bot_command_spell_min_mana_pct(Client* c, const Seperator* sep)
BotSpellTypes::Snare
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set BotA to stop casting fast heals at 30% mana:",
fmt::format(
@@ -53,7 +51,7 @@ void bot_command_spell_min_mana_pct(Client* c, const Seperator* sep)
BotSpellTypes::FastHeals
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current Stun min mana percent on all bots:",
fmt::format(
@@ -67,28 +65,9 @@ void bot_command_spell_min_mana_pct(Client* c, const Seperator* sep)
BotSpellTypes::Stun
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+11 -33
View File
@@ -3,24 +3,23 @@
void bot_command_spell_min_thresholds(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_min_thresholds", sep->arg[0], "spellminthresholds")) {
c->Message(Chat::White, "note: Controls at what target HP % the bot will stop casting different spell types.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Controls at what target HP % the bot will stop casting different spell types"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
p.description = { "Controls at what target HP % the bot will stop casting different spell types." };
p.notes =
{
"- All pet types are based off the pet's owner's setting",
"- Any remaining types use the owner's setting when a pet is the target",
"- All Heals, Cures, Buffs (DS and resists included) are based off the target's setting, not the caster",
"- e.g., BotA is healing BotB using BotB's settings",
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -31,7 +30,7 @@ void bot_command_spell_min_thresholds(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to stop debuffing at 10%:",
fmt::format(
@@ -45,7 +44,7 @@ void bot_command_spell_min_thresholds(Client* c, const Seperator* sep)
BotSpellTypes::Debuff
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set all Druids to stop casting DoTs at 15%:",
fmt::format(
@@ -59,7 +58,7 @@ void bot_command_spell_min_thresholds(Client* c, const Seperator* sep)
BotSpellTypes::DOT
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current Fast Heal min threshold on all bots:",
fmt::format(
@@ -73,30 +72,9 @@ void bot_command_spell_min_thresholds(Client* c, const Seperator* sep)
BotSpellTypes::FastHeals
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid",
"targetgroup, namesgroup, healrotationtargets",
"mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+11 -31
View File
@@ -3,22 +3,21 @@
void bot_command_spell_pursue_priority(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_pursue_priority", sep->arg[0], "spellpursuepriority")) {
c->Message(Chat::White, "note: Sets the order of spell casts when the mob is fleeing in combat by spell type.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Sets the order of spell casts when the mob is fleeing in combat by spell type"
};
BotCommandHelpParams p;
std::vector<std::string> notes =
p.description = { "Sets the order of spell casts when the mob is fleeing in combat by spell type." };
p.notes =
{
"- Setting a spell type to 0 will prevent that type from being cast.",
"- If 2 or more are set to the same priority they will sort by spell type ID."
};
std::vector<std::string> example_format =
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -29,7 +28,7 @@ void bot_command_spell_pursue_priority(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to cast nukes first:",
fmt::format(
@@ -43,7 +42,7 @@ void bot_command_spell_pursue_priority(Client* c, const Seperator* sep)
BotSpellTypes::FastHeals
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set all Shaman to not cast cures:",
fmt::format(
@@ -57,7 +56,7 @@ void bot_command_spell_pursue_priority(Client* c, const Seperator* sep)
BotSpellTypes::Cure
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current pursue priority of buffs on all bots:",
fmt::format(
@@ -71,28 +70,9 @@ void bot_command_spell_pursue_priority(Client* c, const Seperator* sep)
BotSpellTypes::Buff
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+10 -31
View File
@@ -3,18 +3,16 @@
void bot_command_spell_target_count(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_spell_target_count", sep->arg[0], "spelltargetcount")) {
c->Message(Chat::White, "note: Decides how many eligible targets are required for an AE or group spell to cast by spell type.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Decides how many eligible targets are required for an AE or group spell to cast by spell type"
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
p.description = { "Decides how many eligible targets are required for an AE or group spell to cast by spell type." };
p.example_format =
{
fmt::format(
"{} [Type Shortname] [value] [actionable]"
@@ -25,7 +23,7 @@ void bot_command_spell_target_count(Client* c, const Seperator* sep)
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.examples_one =
{
"To set all bots to AEMez with 5 or more targets:",
fmt::format(
@@ -39,7 +37,7 @@ void bot_command_spell_target_count(Client* c, const Seperator* sep)
BotSpellTypes::AEMez
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To set Wizards to require 5 targets for AENukes:",
fmt::format(
@@ -53,7 +51,7 @@ void bot_command_spell_target_count(Client* c, const Seperator* sep)
BotSpellTypes::AENukes
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To check the current AESlow count on all bots:",
fmt::format(
@@ -67,28 +65,9 @@ void bot_command_spell_target_count(Client* c, const Seperator* sep)
BotSpellTypes::AESlow
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());
+10 -37
View File
@@ -3,25 +3,17 @@
void bot_command_taunt(Client* c, const Seperator* sep)
{
if (helper_command_alias_fail(c, "bot_command_taunt", sep->arg[0], "taunt")) {
c->Message(Chat::White, "note: TAllows you to turn on/off the taunting state of your bots and/or their pets.");
return;
}
if (helper_is_help_or_usage(sep->arg[1])) {
std::vector<std::string> description =
{
"Allows you to turn on/off the taunting state of your bots and/or their pets"
};
BotCommandHelpParams p;
std::vector<std::string> notes = { };
std::vector<std::string> example_format =
{
fmt::format(
"{} [on / off / pet] [optional: pet] [actionable, default: target]"
, sep->arg[0]
)
};
std::vector<std::string> examples_one =
p.description = { "Allows you to turn on/off the taunting state of your bots and/or their pets." };
p.example_format = { fmt::format("{} [on / off / pet] [optional: pet] [actionable, default: target]", sep->arg[0]) };
p.examples_one =
{
"To turn off taunt on all bots:",
fmt::format(
@@ -29,7 +21,7 @@ void bot_command_taunt(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_two =
p.examples_two =
{
"To turn on taunt on all bots' pets:",
fmt::format(
@@ -37,7 +29,7 @@ void bot_command_taunt(Client* c, const Seperator* sep)
sep->arg[0]
)
};
std::vector<std::string> examples_three =
p.examples_three =
{
"To turn on taunt for all ShadowKnights:",
fmt::format(
@@ -46,28 +38,9 @@ void bot_command_taunt(Client* c, const Seperator* sep)
Class::ShadowKnight
)
};
p.actionables = { "target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned" };
std::vector<std::string> actionables =
{
"target, byname, ownergroup, ownerraid, targetgroup, namesgroup, healrotationtargets, mmr, byclass, byrace, spawned"
};
std::vector<std::string> options = { };
std::vector<std::string> options_one = { };
std::vector<std::string> options_two = { };
std::vector<std::string> options_three = { };
std::string popup_text = c->SendCommandHelpWindow(
c,
description,
notes,
example_format,
examples_one, examples_two, examples_three,
actionables,
options,
options_one, options_two, options_three
);
std::string popup_text = c->SendBotCommandHelpWindow(p);
popup_text = DialogueWindow::Table(popup_text);
c->SendPopupToClient(sep->arg[0], popup_text.c_str());