mirror of
https://github.com/mod-playerbots/mod-playerbots.git
synced 2026-02-14 15:53:45 +00:00
Run clang-format
This commit is contained in:
@@ -1,5 +1,6 @@
|
||||
/*
|
||||
* Copyright (C) 2016+ AzerothCore <www.azerothcore.org>, released under GNU GPL v2 license, you may redistribute it and/or modify it under version 2 of the License, or (at your option), any later version.
|
||||
* Copyright (C) 2016+ AzerothCore <www.azerothcore.org>, released under GNU GPL v2 license, you may redistribute it
|
||||
* and/or modify it under version 2 of the License, or (at your option), any later version.
|
||||
*/
|
||||
|
||||
#ifndef _PLAYERBOT_GUILDMAMANEGEMENTACTION_H
|
||||
@@ -14,85 +15,100 @@ class WorldPacket;
|
||||
|
||||
class GuidManageAction : public Action
|
||||
{
|
||||
public:
|
||||
GuidManageAction(PlayerbotAI* botAI, std::string const name = "guild manage", uint16 opcode = CMSG_GUILD_INVITE) : Action(botAI, name), opcode(opcode) { }
|
||||
public:
|
||||
GuidManageAction(PlayerbotAI* botAI, std::string const name = "guild manage", uint16 opcode = CMSG_GUILD_INVITE)
|
||||
: Action(botAI, name), opcode(opcode)
|
||||
{
|
||||
}
|
||||
|
||||
bool Execute(Event event) override;
|
||||
bool isUseful() override { return false; }
|
||||
bool Execute(Event event) override;
|
||||
bool isUseful() override { return false; }
|
||||
|
||||
protected:
|
||||
virtual void SendPacket(WorldPacket data) { };
|
||||
virtual Player* GetPlayer(Event event);
|
||||
virtual bool PlayerIsValid(Player* member);
|
||||
virtual uint8 GetRankId(Player* member);
|
||||
protected:
|
||||
virtual void SendPacket(WorldPacket data){};
|
||||
virtual Player* GetPlayer(Event event);
|
||||
virtual bool PlayerIsValid(Player* member);
|
||||
virtual uint8 GetRankId(Player* member);
|
||||
|
||||
uint16 opcode;
|
||||
uint16 opcode;
|
||||
};
|
||||
|
||||
class GuildInviteAction : public GuidManageAction
|
||||
{
|
||||
public:
|
||||
GuildInviteAction(PlayerbotAI* botAI, std::string const name = "guild invite", uint16 opcode = CMSG_GUILD_INVITE) : GuidManageAction(botAI, name, opcode) { }
|
||||
public:
|
||||
GuildInviteAction(PlayerbotAI* botAI, std::string const name = "guild invite", uint16 opcode = CMSG_GUILD_INVITE)
|
||||
: GuidManageAction(botAI, name, opcode)
|
||||
{
|
||||
}
|
||||
|
||||
bool isUseful() override;
|
||||
bool isUseful() override;
|
||||
|
||||
protected:
|
||||
void SendPacket(WorldPacket data) override;
|
||||
bool PlayerIsValid(Player* member) override;
|
||||
protected:
|
||||
void SendPacket(WorldPacket data) override;
|
||||
bool PlayerIsValid(Player* member) override;
|
||||
};
|
||||
|
||||
class GuildPromoteAction : public GuidManageAction
|
||||
{
|
||||
public:
|
||||
GuildPromoteAction(PlayerbotAI* botAI, std::string const name = "guild promote", uint16 opcode = CMSG_GUILD_PROMOTE) : GuidManageAction(botAI, name, opcode) { }
|
||||
public:
|
||||
GuildPromoteAction(PlayerbotAI* botAI, std::string const name = "guild promote", uint16 opcode = CMSG_GUILD_PROMOTE)
|
||||
: GuidManageAction(botAI, name, opcode)
|
||||
{
|
||||
}
|
||||
|
||||
bool isUseful() override;
|
||||
bool isUseful() override;
|
||||
|
||||
protected:
|
||||
void SendPacket(WorldPacket data) override;
|
||||
bool PlayerIsValid(Player* member) override;
|
||||
protected:
|
||||
void SendPacket(WorldPacket data) override;
|
||||
bool PlayerIsValid(Player* member) override;
|
||||
};
|
||||
|
||||
class GuildDemoteAction : public GuidManageAction
|
||||
{
|
||||
public:
|
||||
GuildDemoteAction(PlayerbotAI* botAI, std::string const name = "guild demote", uint16 opcode = CMSG_GUILD_DEMOTE) : GuidManageAction(botAI, name, opcode) { }
|
||||
public:
|
||||
GuildDemoteAction(PlayerbotAI* botAI, std::string const name = "guild demote", uint16 opcode = CMSG_GUILD_DEMOTE)
|
||||
: GuidManageAction(botAI, name, opcode)
|
||||
{
|
||||
}
|
||||
|
||||
bool isUseful() override;
|
||||
bool isUseful() override;
|
||||
|
||||
protected:
|
||||
void SendPacket(WorldPacket data) override;
|
||||
bool PlayerIsValid(Player* member) override;
|
||||
protected:
|
||||
void SendPacket(WorldPacket data) override;
|
||||
bool PlayerIsValid(Player* member) override;
|
||||
};
|
||||
|
||||
class GuildRemoveAction : public GuidManageAction
|
||||
{
|
||||
public:
|
||||
GuildRemoveAction(PlayerbotAI* botAI, std::string const name = "guild remove", uint16 opcode = CMSG_GUILD_REMOVE) : GuidManageAction(botAI, name, opcode) { }
|
||||
public:
|
||||
GuildRemoveAction(PlayerbotAI* botAI, std::string const name = "guild remove", uint16 opcode = CMSG_GUILD_REMOVE)
|
||||
: GuidManageAction(botAI, name, opcode)
|
||||
{
|
||||
}
|
||||
|
||||
bool isUseful() override;
|
||||
bool isUseful() override;
|
||||
|
||||
protected:
|
||||
void SendPacket(WorldPacket data) override;
|
||||
bool PlayerIsValid(Player* member) override;
|
||||
protected:
|
||||
void SendPacket(WorldPacket data) override;
|
||||
bool PlayerIsValid(Player* member) override;
|
||||
};
|
||||
|
||||
class GuildManageNearbyAction : public Action
|
||||
{
|
||||
public:
|
||||
GuildManageNearbyAction(PlayerbotAI* botAI) : Action(botAI, "guild manage nearby") { }
|
||||
public:
|
||||
GuildManageNearbyAction(PlayerbotAI* botAI) : Action(botAI, "guild manage nearby") {}
|
||||
|
||||
bool Execute(Event event) override;
|
||||
bool isUseful() override;
|
||||
bool Execute(Event event) override;
|
||||
bool isUseful() override;
|
||||
};
|
||||
|
||||
class GuildLeaveAction : public Action
|
||||
{
|
||||
public:
|
||||
GuildLeaveAction(PlayerbotAI* botAI) : Action(botAI, "guild leave") { }
|
||||
public:
|
||||
GuildLeaveAction(PlayerbotAI* botAI) : Action(botAI, "guild leave") {}
|
||||
|
||||
bool Execute(Event event) override;
|
||||
bool isUseful() override;
|
||||
bool Execute(Event event) override;
|
||||
bool isUseful() override;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user