From 27540824c018801bfba304a944f7f15dc255ebdd Mon Sep 17 00:00:00 2001 From: Shauren Date: Mon, 18 Nov 2019 12:25:28 +0100 Subject: Core/Misc: Rename AzeriteItem packet namespace to just Azerite --- .../game/Entities/Item/AzeriteItem/AzeriteItem.cpp | 4 +-- src/server/game/Server/Packets/AllPackets.h | 2 +- .../game/Server/Packets/AzeriteItemPackets.cpp | 26 -------------- .../game/Server/Packets/AzeriteItemPackets.h | 41 ---------------------- src/server/game/Server/Packets/AzeritePackets.cpp | 26 ++++++++++++++ src/server/game/Server/Packets/AzeritePackets.h | 41 ++++++++++++++++++++++ 6 files changed, 70 insertions(+), 70 deletions(-) delete mode 100644 src/server/game/Server/Packets/AzeriteItemPackets.cpp delete mode 100644 src/server/game/Server/Packets/AzeriteItemPackets.h create mode 100644 src/server/game/Server/Packets/AzeritePackets.cpp create mode 100644 src/server/game/Server/Packets/AzeritePackets.h (limited to 'src') diff --git a/src/server/game/Entities/Item/AzeriteItem/AzeriteItem.cpp b/src/server/game/Entities/Item/AzeriteItem/AzeriteItem.cpp index 8366b2dadd4..599aadede43 100644 --- a/src/server/game/Entities/Item/AzeriteItem/AzeriteItem.cpp +++ b/src/server/game/Entities/Item/AzeriteItem/AzeriteItem.cpp @@ -16,7 +16,7 @@ */ #include "AzeriteItem.h" -#include "AzeriteItemPackets.h" +#include "AzeritePackets.h" #include "DatabaseEnv.h" #include "DB2Stores.h" #include "GameTime.h" @@ -194,7 +194,7 @@ void AzeriteItem::GiveXP(uint64 xp) SetState(ITEM_CHANGED, owner); } - WorldPackets::AzeriteItem::AzeriteXpGain xpGain; + WorldPackets::Azerite::AzeriteXpGain xpGain; xpGain.ItemGUID = GetGUID(); xpGain.XP = xp; owner->SendDirectMessage(xpGain.Write()); diff --git a/src/server/game/Server/Packets/AllPackets.h b/src/server/game/Server/Packets/AllPackets.h index b4a22e1dd48..e5f67fd1e82 100644 --- a/src/server/game/Server/Packets/AllPackets.h +++ b/src/server/game/Server/Packets/AllPackets.h @@ -23,7 +23,7 @@ #include "ArtifactPackets.h" #include "AuctionHousePackets.h" #include "AuthenticationPackets.h" -#include "AzeriteItemPackets.h" +#include "AzeritePackets.h" #include "BankPackets.h" #include "BlackMarketPackets.h" #include "BattlefieldPackets.h" diff --git a/src/server/game/Server/Packets/AzeriteItemPackets.cpp b/src/server/game/Server/Packets/AzeriteItemPackets.cpp deleted file mode 100644 index d66035a3ab6..00000000000 --- a/src/server/game/Server/Packets/AzeriteItemPackets.cpp +++ /dev/null @@ -1,26 +0,0 @@ -/* - * Copyright (C) 2008-2019 TrinityCore - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation; either version 2 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see . - */ - -#include "AzeriteItemPackets.h" - -WorldPacket const* WorldPackets::AzeriteItem::AzeriteXpGain::Write() -{ - _worldPacket << ItemGUID; - _worldPacket << uint64(XP); - - return &_worldPacket; -} diff --git a/src/server/game/Server/Packets/AzeriteItemPackets.h b/src/server/game/Server/Packets/AzeriteItemPackets.h deleted file mode 100644 index d8862f707bd..00000000000 --- a/src/server/game/Server/Packets/AzeriteItemPackets.h +++ /dev/null @@ -1,41 +0,0 @@ -/* - * Copyright (C) 2008-2019 TrinityCore - * - * This program is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License as published by the - * Free Software Foundation; either version 2 of the License, or (at your - * option) any later version. - * - * This program is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for - * more details. - * - * You should have received a copy of the GNU General Public License along - * with this program. If not, see . - */ - -#ifndef AzeriteItemPackets_h__ -#define AzeriteItemPackets_h__ - -#include "Packet.h" -#include "ObjectGuid.h" - -namespace WorldPackets -{ - namespace AzeriteItem - { - class AzeriteXpGain final : public ServerPacket - { - public: - AzeriteXpGain() : ServerPacket(SMSG_AZERITE_XP_GAIN, 16 + 8) { } - - WorldPacket const* Write() override; - - ObjectGuid ItemGUID; - uint64 XP = 0; - }; - } -} - -#endif // AzeriteItemPackets_h__ diff --git a/src/server/game/Server/Packets/AzeritePackets.cpp b/src/server/game/Server/Packets/AzeritePackets.cpp new file mode 100644 index 00000000000..97e8bcc81ff --- /dev/null +++ b/src/server/game/Server/Packets/AzeritePackets.cpp @@ -0,0 +1,26 @@ +/* + * Copyright (C) 2008-2019 TrinityCore + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation; either version 2 of the License, or (at your + * option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . + */ + +#include "AzeritePackets.h" + +WorldPacket const* WorldPackets::Azerite::AzeriteXpGain::Write() +{ + _worldPacket << ItemGUID; + _worldPacket << uint64(XP); + + return &_worldPacket; +} diff --git a/src/server/game/Server/Packets/AzeritePackets.h b/src/server/game/Server/Packets/AzeritePackets.h new file mode 100644 index 00000000000..31ca4cdb13a --- /dev/null +++ b/src/server/game/Server/Packets/AzeritePackets.h @@ -0,0 +1,41 @@ +/* + * Copyright (C) 2008-2019 TrinityCore + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation; either version 2 of the License, or (at your + * option) any later version. + * + * This program is distributed in the hope that it will be useful, but WITHOUT + * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or + * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for + * more details. + * + * You should have received a copy of the GNU General Public License along + * with this program. If not, see . + */ + +#ifndef AzeriteItemPackets_h__ +#define AzeriteItemPackets_h__ + +#include "Packet.h" +#include "ObjectGuid.h" + +namespace WorldPackets +{ + namespace Azerite + { + class AzeriteXpGain final : public ServerPacket + { + public: + AzeriteXpGain() : ServerPacket(SMSG_AZERITE_XP_GAIN, 16 + 8) { } + + WorldPacket const* Write() override; + + ObjectGuid ItemGUID; + uint64 XP = 0; + }; + } +} + +#endif // AzeriteItemPackets_h__ -- cgit v1.2.3