AzerothCore 3.3.5a
OpenSource WoW Emulator
Loading...
Searching...
No Matches
WorldPackets::Misc::Weather Class Referencefinal

#include "MiscPackets.h"

Inheritance diagram for WorldPackets::Misc::Weather:
WorldPackets::ServerPacket WorldPackets::Packet

Public Member Functions

 Weather ()
 
 Weather (WeatherState weatherID, float intensity=0.0f, bool abrupt=false)
 
WorldPacket const * Write () override
 
- Public Member Functions inherited from WorldPackets::ServerPacket
 ServerPacket (OpcodeServer opcode, std::size_t initialSize=200)
 
void Read () final
 
void Clear ()
 
WorldPacket && Move ()
 
void ShrinkToFit ()
 
OpcodeServer GetOpcode () const
 
- Public Member Functions inherited from WorldPackets::Packet
 Packet (WorldPacket &&worldPacket)
 
virtual ~Packet ()=default
 
 Packet (Packet const &right)=delete
 
Packetoperator= (Packet const &right)=delete
 
virtual WorldPacket const * Write ()=0
 
virtual void Read ()=0
 
WorldPacket const * GetRawPacket () const
 
std::size_t GetSize () const
 

Public Attributes

bool Abrupt = false
 
float Intensity = 0.0f
 
WeatherState WeatherID = WeatherState(0)
 

Additional Inherited Members

- Protected Attributes inherited from WorldPackets::Packet
WorldPacket _worldPacket
 

Detailed Description

Constructor & Destructor Documentation

◆ Weather() [1/2]

Weather::Weather ( )
20: ServerPacket(SMSG_WEATHER, 4 + 4 + 1) { }
@ SMSG_WEATHER
Definition: Opcodes.h:786
ServerPacket(OpcodeServer opcode, std::size_t initialSize=200)
Definition: Packet.cpp:25

◆ Weather() [2/2]

Weather::Weather ( WeatherState  weatherID,
float  intensity = 0.0f,
bool  abrupt = false 
)
23 : ServerPacket(SMSG_WEATHER, 4 + 4 + 1), Abrupt(abrupt), Intensity(intensity), WeatherID(weatherID) { }
bool Abrupt
Definition: MiscPackets.h:39
WeatherState WeatherID
Definition: MiscPackets.h:41
float Intensity
Definition: MiscPackets.h:40

Member Function Documentation

◆ Write()

WorldPacket const * Weather::Write ( )
overridevirtual

Implements WorldPackets::Packet.

26{
28 _worldPacket << float(Intensity);
30
31 return &_worldPacket;
32}
std::uint8_t uint8
Definition: Define.h:109
std::uint32_t uint32
Definition: Define.h:107
WorldPacket _worldPacket
Definition: Packet.h:42

Referenced by boss_ossirian::JustEngagedWith(), WeatherMgr::SendFineWeatherUpdateToPlayer(), Weather::SendWeatherUpdateToPlayer(), Map::SendZoneDynamicInfo(), Map::SetZoneWeather(), and Weather::UpdateWeather().

Member Data Documentation

◆ Abrupt

bool WorldPackets::Misc::Weather::Abrupt = false

◆ Intensity

float WorldPackets::Misc::Weather::Intensity = 0.0f

◆ WeatherID

WeatherState WorldPackets::Misc::Weather::WeatherID = WeatherState(0)