This commit is contained in:
Matthew Silvia 2021-01-02 23:24:28 -05:00
parent 0456bef903
commit e13346560e
2 changed files with 12 additions and 0 deletions

View File

@ -438,6 +438,7 @@ int command_init(void)
command_add("wp", "[add/delete] [grid_num] [pause] [wp_num] [-h] - Add/delete a waypoint to/from a wandering grid", 170, command_wp) ||
command_add("wpadd", "[pause] [-h] - Add your current location as a waypoint to your NPC target's AI path", 170, command_wpadd) ||
command_add("wpinfo", "- Show waypoint info about your NPC target", 170, command_wpinfo) ||
command_add("ww", "Casts the provided spell ID to all players currently online. Use caution with this!", 250, command_ww) ||
command_add("xtargets", "Show your targets Extended Targets and optionally set how many xtargets they can have.", 250, command_xtargets) ||
command_add("zclip", "[min] [max] - modifies and resends zhdr packet", 80, command_zclip) ||
command_add("zcolor", "[red] [green] [blue] - Change sky color", 80, command_zcolor) ||
@ -737,6 +738,16 @@ void command_logcommand(Client *c, const char *message)
/*
* commands go below here
*/
void command_ww(Client *c, const Seperator *sep)
{
if (sep->arg[1][0] && Seperator::IsNumber(sep->arg[1])) {
int spell_id = atoi(sep->arg[1]);
quest_manager.WorldWideCastSpell(spell_id, 0, 0);
worldserver.SendEmoteMessage(0, 0, 15, fmt::format("<SYSTEMWIDE MESSAGE> A GM has cast {} world-wide!", GetSpellName(spell_id)).c_str());
}
else
c->Message(Chat::Yellow, "Usage: #ww <spellid>");
}
void command_setstat(Client* c, const Seperator* sep){
if(sep->arg[1][0] && sep->arg[2][0] && c->GetTarget()!=0 && c->GetTarget()->IsClient()){
c->GetTarget()->CastToClient()->SetStats(atoi(sep->arg[1]),atoi(sep->arg[2]));

View File

@ -344,6 +344,7 @@ void command_worldshutdown(Client *c, const Seperator *sep);
void command_wp(Client *c, const Seperator *sep);
void command_wpadd(Client *c, const Seperator *sep);
void command_wpinfo(Client *c, const Seperator *sep);
void command_ww(Client *c, const Seperator *sep);
void command_xtargets(Client *c, const Seperator *sep);
void command_zclip(Client *c, const Seperator *sep);
void command_zcolor(Client *c, const Seperator *sep);