TrinityCore
Loading...
Searching...
No Matches
TotemPackets.cpp
Go to the documentation of this file.
1
/*
2
* This file is part of the TrinityCore Project. See AUTHORS file for Copyright information
3
*
4
* This program is free software; you can redistribute it and/or modify it
5
* under the terms of the GNU General Public License as published by the
6
* Free Software Foundation; either version 2 of the License, or (at your
7
* option) any later version.
8
*
9
* This program is distributed in the hope that it will be useful, but WITHOUT
10
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11
* FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
12
* more details.
13
*
14
* You should have received a copy of the GNU General Public License along
15
* with this program. If not, see <http://www.gnu.org/licenses/>.
16
*/
17
18
#include "
TotemPackets.h
"
19
#include "
PacketOperators.h
"
20
21
namespace
WorldPackets::Totem
22
{
23
void
TotemDestroyed::Read
()
24
{
25
_worldPacket
>>
Slot
;
26
_worldPacket
>>
TotemGUID
;
27
}
28
29
WorldPacket
const
*
TotemCreated::Write
()
30
{
31
_worldPacket
<<
uint8
(
Slot
);
32
_worldPacket
<<
Totem
;
33
_worldPacket
<<
Duration
;
34
_worldPacket
<<
int32
(
SpellID
);
35
_worldPacket
<< float(
TimeMod
);
36
_worldPacket << Bits<1>(
CannotDismiss
);
37
_worldPacket
.
FlushBits
();
38
39
return
&
_worldPacket
;
40
}
41
42
WorldPacket
const
*
TotemMoved::Write
()
43
{
44
_worldPacket
<<
uint8
(
Slot
);
45
_worldPacket
<<
uint8
(
NewSlot
);
46
_worldPacket
<<
Totem
;
47
48
return
&
_worldPacket
;
49
}
50
}
uint8
uint8_t uint8
Definition
Define.h:156
int32
int32_t int32
Definition
Define.h:150
PacketOperators.h
TotemPackets.h
ByteBuffer::FlushBits
void FlushBits()
Definition
ByteBuffer.h:141
WorldPacket
Definition
WorldPacket.h:26
WorldPackets::Packet::_worldPacket
WorldPacket _worldPacket
Definition
Packet.h:43
WorldPackets::Totem::TotemCreated::Slot
uint8 Slot
Definition
TotemPackets.h:50
WorldPackets::Totem::TotemCreated::CannotDismiss
bool CannotDismiss
Definition
TotemPackets.h:52
WorldPackets::Totem::TotemCreated::Duration
WorldPackets::Duration< Milliseconds, int32 > Duration
Definition
TotemPackets.h:49
WorldPackets::Totem::TotemCreated::Write
WorldPacket const * Write() override
Definition
TotemPackets.cpp:29
WorldPackets::Totem::TotemCreated::Totem
ObjectGuid Totem
Definition
TotemPackets.h:47
WorldPackets::Totem::TotemCreated::TimeMod
float TimeMod
Definition
TotemPackets.h:51
WorldPackets::Totem::TotemCreated::SpellID
int32 SpellID
Definition
TotemPackets.h:48
WorldPackets::Totem::TotemDestroyed::Read
void Read() override
Definition
TotemPackets.cpp:23
WorldPackets::Totem::TotemDestroyed::Slot
uint8 Slot
Definition
TotemPackets.h:37
WorldPackets::Totem::TotemDestroyed::TotemGUID
ObjectGuid TotemGUID
Definition
TotemPackets.h:36
WorldPackets::Totem::TotemMoved::Totem
ObjectGuid Totem
Definition
TotemPackets.h:62
WorldPackets::Totem::TotemMoved::NewSlot
uint8 NewSlot
Definition
TotemPackets.h:64
WorldPackets::Totem::TotemMoved::Write
WorldPacket const * Write() override
Definition
TotemPackets.cpp:42
WorldPackets::Totem::TotemMoved::Slot
uint8 Slot
Definition
TotemPackets.h:63
WorldPackets::Totem
Definition
TotemPackets.cpp:22
server
game
Server
Packets
TotemPackets.cpp
Generated on Sun May 10 2026 02:09:03 for TrinityCore by
1.9.8