Files
GabsPuNs-Project_Zenith_Main/Minecraft.World/ContainerClosePacket.cpp
GabsPuNs bc6c09146a New File System and Cleanup some code Part 3
* Remove stdafx.h and some <unordered_set> includes
* Update Minecraft Server Defines and remove more unused folders/files
* Unbloat stdafx.h from Minecraft.World
2026-05-24 22:21:41 -04:00

37 lines
689 B
C++

#include <iostream>
#include "InputOutputStream.h"
#include "PacketListener.h"
#include "ContainerClosePacket.h"
ContainerClosePacket::ContainerClosePacket()
{
containerId = 0;
}
ContainerClosePacket::ContainerClosePacket(int containerId)
{
this->containerId = containerId;
}
void ContainerClosePacket::handle(PacketListener *listener)
{
listener->handleContainerClose(shared_from_this());
}
void ContainerClosePacket::read(DataInputStream *dis) //throws IOException
{
containerId = dis->readByte();
}
void ContainerClosePacket::write(DataOutputStream *dos) //throws IOException
{
dos->writeByte(containerId);
}
int ContainerClosePacket::getEstimatedSize()
{
return 1;
}