blob: e62fb2eb9b8b7369a213edd7dd3805efbb6a080c (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
|
#include "stdafx.h"
#include <iostream>
#include "InputOutputStream.h"
#include "net.minecraft.world.item.h"
#include "PacketListener.h"
#include "DebugOptionsPacket.h"
DebugOptionsPacket::~DebugOptionsPacket()
{
}
DebugOptionsPacket::DebugOptionsPacket()
{
m_uiVal = 0L;
}
DebugOptionsPacket::DebugOptionsPacket(unsigned int uiVal)
{
this->m_uiVal = uiVal;
}
void DebugOptionsPacket::handle(PacketListener *listener)
{
listener->handleDebugOptions(shared_from_this());
}
void DebugOptionsPacket::read(DataInputStream *dis) //throws IOException
{
m_uiVal = static_cast<unsigned int>(dis->readInt());
}
void DebugOptionsPacket::write(DataOutputStream *dos) // throws IOException
{
dos->writeInt(static_cast<int>(m_uiVal));
}
int DebugOptionsPacket::getEstimatedSize()
{
return sizeof(int);
}
|