mirror of
https://github.com/4jcraft/4jcraft.git
synced 2026-07-26 07:07:05 +00:00
refactor: unglob std::enable_shared_from_this
This commit is contained in:
parent
6260238f5e
commit
4516cf2e30
|
|
@ -10,7 +10,7 @@ class CompoundTag;
|
||||||
|
|
||||||
typedef TileEntity *(*tileEntityCreateFn)();
|
typedef TileEntity *(*tileEntityCreateFn)();
|
||||||
|
|
||||||
class TileEntity : public enable_shared_from_this<TileEntity>
|
class TileEntity : public std::enable_shared_from_this<TileEntity>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static void staticCtor();
|
static void staticCtor();
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ class MerchantContainer;
|
||||||
class MerchantRecipeList;
|
class MerchantRecipeList;
|
||||||
class MerchantRecipe;
|
class MerchantRecipe;
|
||||||
|
|
||||||
class ClientSideMerchant : public Merchant, public enable_shared_from_this<ClientSideMerchant>
|
class ClientSideMerchant : public Merchant, public std::enable_shared_from_this<ClientSideMerchant>
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
MerchantContainer *container;
|
MerchantContainer *container;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
class RepairMenu;
|
class RepairMenu;
|
||||||
|
|
||||||
class RepairContainer : public SimpleContainer, public enable_shared_from_this<RepairContainer>
|
class RepairContainer : public SimpleContainer, public std::enable_shared_from_this<RepairContainer>
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
RepairMenu *m_menu;
|
RepairMenu *m_menu;
|
||||||
|
|
|
||||||
|
|
@ -32,7 +32,7 @@ enum EEntityDamageType
|
||||||
eEntityDamageType_Cactus,
|
eEntityDamageType_Cactus,
|
||||||
};
|
};
|
||||||
|
|
||||||
class Entity : public enable_shared_from_this<Entity>
|
class Entity : public std::enable_shared_from_this<Entity>
|
||||||
{
|
{
|
||||||
friend class Gui; // 4J Stu - Added to be able to access the shared flag functions and constants, without making them publicly available to everything
|
friend class Gui; // 4J Stu - Added to be able to access the shared flag functions and constants, without making them publicly available to everything
|
||||||
public:
|
public:
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@ class EnchantedBookItem;
|
||||||
#define ITEM_ICON_COLUMNS 16
|
#define ITEM_ICON_COLUMNS 16
|
||||||
|
|
||||||
|
|
||||||
class Item : public enable_shared_from_this<Item>
|
class Item : public std::enable_shared_from_this<Item>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int ITEM_NUM_COUNT = 32000;
|
static const int ITEM_NUM_COUNT = 32000;
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ class Icon;
|
||||||
|
|
||||||
// 4J Stu - While this is not really an abstract class, we don't want to make new instances of it,
|
// 4J Stu - While this is not really an abstract class, we don't want to make new instances of it,
|
||||||
// mainly because there are too many ctors and that doesn't fit well into out macroisation setup
|
// mainly because there are too many ctors and that doesn't fit well into out macroisation setup
|
||||||
class ItemInstance: public enable_shared_from_this<ItemInstance>
|
class ItemInstance: public std::enable_shared_from_this<ItemInstance>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const wchar_t *TAG_ENCH_ID;
|
static const wchar_t *TAG_ENCH_ID;
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ using namespace std;
|
||||||
|
|
||||||
class CompoundTag;
|
class CompoundTag;
|
||||||
|
|
||||||
class SavedData : public enable_shared_from_this<SavedData>
|
class SavedData : public std::enable_shared_from_this<SavedData>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
const std::wstring id;
|
const std::wstring id;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class AddEntityPacket : public Packet, public enable_shared_from_this<AddEntityPacket>
|
class AddEntityPacket : public Packet, public std::enable_shared_from_this<AddEntityPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int BOAT = 1;
|
static const int BOAT = 1;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
class ExperienceOrb;
|
class ExperienceOrb;
|
||||||
|
|
||||||
class AddExperienceOrbPacket : public Packet, public enable_shared_from_this<AddExperienceOrbPacket>
|
class AddExperienceOrbPacket : public Packet, public std::enable_shared_from_this<AddExperienceOrbPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class AddGlobalEntityPacket : public Packet, public enable_shared_from_this<AddGlobalEntityPacket>
|
class AddGlobalEntityPacket : public Packet, public std::enable_shared_from_this<AddGlobalEntityPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int LIGHTNING;
|
static const int LIGHTNING;
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ using namespace std;
|
||||||
|
|
||||||
class Mob;
|
class Mob;
|
||||||
|
|
||||||
class AddMobPacket : public Packet, public enable_shared_from_this<AddMobPacket>
|
class AddMobPacket : public Packet, public std::enable_shared_from_this<AddMobPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ using namespace std;
|
||||||
|
|
||||||
class Painting;
|
class Painting;
|
||||||
|
|
||||||
class AddPaintingPacket : public Packet, public enable_shared_from_this<AddPaintingPacket>
|
class AddPaintingPacket : public Packet, public std::enable_shared_from_this<AddPaintingPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ using namespace std;
|
||||||
|
|
||||||
class Player;
|
class Player;
|
||||||
|
|
||||||
class AddPlayerPacket : public Packet, public enable_shared_from_this<AddPlayerPacket>
|
class AddPlayerPacket : public Packet, public std::enable_shared_from_this<AddPlayerPacket>
|
||||||
{
|
{
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class AnimatePacket : public Packet, public enable_shared_from_this<AnimatePacket>
|
class AnimatePacket : public Packet, public std::enable_shared_from_this<AnimatePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int SWING = 1;
|
static const int SWING = 1;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class AwardStatPacket : public Packet, public enable_shared_from_this<AwardStatPacket>
|
class AwardStatPacket : public Packet, public std::enable_shared_from_this<AwardStatPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int statId;
|
int statId;
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ using namespace std;
|
||||||
|
|
||||||
class Level;
|
class Level;
|
||||||
|
|
||||||
class BlockRegionUpdatePacket : public Packet, public enable_shared_from_this<BlockRegionUpdatePacket>
|
class BlockRegionUpdatePacket : public Packet, public std::enable_shared_from_this<BlockRegionUpdatePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int x, y, z;
|
int x, y, z;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ChatPacket : public Packet, public enable_shared_from_this<ChatPacket>
|
class ChatPacket : public Packet, public std::enable_shared_from_this<ChatPacket>
|
||||||
{
|
{
|
||||||
// longest allowed string is "<" + name + "> " + message
|
// longest allowed string is "<" + name + "> " + message
|
||||||
private:
|
private:
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ using namespace std;
|
||||||
|
|
||||||
class Level;
|
class Level;
|
||||||
|
|
||||||
class ChunkTilesUpdatePacket : public Packet, public enable_shared_from_this<ChunkTilesUpdatePacket>
|
class ChunkTilesUpdatePacket : public Packet, public std::enable_shared_from_this<ChunkTilesUpdatePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int xc, zc;
|
int xc, zc;
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ class Level;
|
||||||
|
|
||||||
// 4J Added this packet so that when a player initially joins the game we just need to send them the area of chunks
|
// 4J Added this packet so that when a player initially joins the game we just need to send them the area of chunks
|
||||||
// around them rather than one packet for each chunk
|
// around them rather than one packet for each chunk
|
||||||
class ChunkVisibilityAreaPacket : public Packet, public enable_shared_from_this<ChunkVisibilityAreaPacket>
|
class ChunkVisibilityAreaPacket : public Packet, public std::enable_shared_from_this<ChunkVisibilityAreaPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int m_minX, m_maxX, m_minZ, m_maxZ;
|
int m_minX, m_maxX, m_minZ, m_maxZ;
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ using namespace std;
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include "PacketListener.h"
|
#include "PacketListener.h"
|
||||||
|
|
||||||
class ChunkVisibilityPacket : public Packet, public enable_shared_from_this<ChunkVisibilityPacket>
|
class ChunkVisibilityPacket : public Packet, public std::enable_shared_from_this<ChunkVisibilityPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int x, z;
|
int x, z;
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ClientCommandPacket : public Packet, public enable_shared_from_this<ClientCommandPacket>
|
class ClientCommandPacket : public Packet, public std::enable_shared_from_this<ClientCommandPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int LOGIN_COMPLETE = 0;
|
static const int LOGIN_COMPLETE = 0;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ComplexItemDataPacket : public Packet, public enable_shared_from_this<ComplexItemDataPacket>
|
class ComplexItemDataPacket : public Packet, public std::enable_shared_from_this<ComplexItemDataPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
short itemType;
|
short itemType;
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ using namespace std;
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include "PacketListener.h"
|
#include "PacketListener.h"
|
||||||
|
|
||||||
class ContainerAckPacket : public Packet, public enable_shared_from_this<ContainerAckPacket>
|
class ContainerAckPacket : public Packet, public std::enable_shared_from_this<ContainerAckPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int containerId;
|
int containerId;
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ContainerButtonClickPacket : public Packet, public enable_shared_from_this<ContainerButtonClickPacket>
|
class ContainerButtonClickPacket : public Packet, public std::enable_shared_from_this<ContainerButtonClickPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int containerId;
|
int containerId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ContainerClickPacket : public Packet, public enable_shared_from_this<ContainerClickPacket>
|
class ContainerClickPacket : public Packet, public std::enable_shared_from_this<ContainerClickPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int containerId;
|
int containerId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ContainerClosePacket : public Packet, public enable_shared_from_this<ContainerClosePacket>
|
class ContainerClosePacket : public Packet, public std::enable_shared_from_this<ContainerClosePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int containerId;
|
int containerId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ContainerOpenPacket : public Packet, public enable_shared_from_this<ContainerOpenPacket>
|
class ContainerOpenPacket : public Packet, public std::enable_shared_from_this<ContainerOpenPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int CONTAINER = 0;
|
static const int CONTAINER = 0;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ContainerSetContentPacket : public Packet, public enable_shared_from_this<ContainerSetContentPacket>
|
class ContainerSetContentPacket : public Packet, public std::enable_shared_from_this<ContainerSetContentPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int containerId;
|
int containerId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ContainerSetDataPacket : public Packet, public enable_shared_from_this<ContainerSetDataPacket>
|
class ContainerSetDataPacket : public Packet, public std::enable_shared_from_this<ContainerSetDataPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int containerId;
|
int containerId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ContainerSetSlotPacket : public Packet, public enable_shared_from_this<ContainerSetSlotPacket>
|
class ContainerSetSlotPacket : public Packet, public std::enable_shared_from_this<ContainerSetSlotPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int CONTAINER;
|
static const int CONTAINER;
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class CraftItemPacket : public Packet, public enable_shared_from_this<CraftItemPacket>
|
class CraftItemPacket : public Packet, public std::enable_shared_from_this<CraftItemPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int recipe;
|
int recipe;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class CustomPayloadPacket : public Packet, public enable_shared_from_this<CustomPayloadPacket>
|
class CustomPayloadPacket : public Packet, public std::enable_shared_from_this<CustomPayloadPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class DebugOptionsPacket : public Packet, public enable_shared_from_this<DebugOptionsPacket>
|
class DebugOptionsPacket : public Packet, public std::enable_shared_from_this<DebugOptionsPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
unsigned int m_uiVal;
|
unsigned int m_uiVal;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class DisconnectPacket : public Packet, public enable_shared_from_this<DisconnectPacket>
|
class DisconnectPacket : public Packet, public std::enable_shared_from_this<DisconnectPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class EntityActionAtPositionPacket : public Packet, public enable_shared_from_this<EntityActionAtPositionPacket>
|
class EntityActionAtPositionPacket : public Packet, public std::enable_shared_from_this<EntityActionAtPositionPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int START_SLEEP;
|
static const int START_SLEEP;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class EntityEventPacket : public Packet, public enable_shared_from_this<EntityEventPacket>
|
class EntityEventPacket : public Packet, public std::enable_shared_from_this<EntityEventPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int entityId;
|
int entityId;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ using namespace std;
|
||||||
#include "../../Level/TilePos.h"
|
#include "../../Level/TilePos.h"
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ExplodePacket : public Packet, public enable_shared_from_this<ExplodePacket>
|
class ExplodePacket : public Packet, public std::enable_shared_from_this<ExplodePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
double x, y, z;
|
double x, y, z;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ using namespace std;
|
||||||
#include "../../Commands/CommandsEnum.h"
|
#include "../../Commands/CommandsEnum.h"
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class GameCommandPacket : public Packet, public enable_shared_from_this<GameCommandPacket>
|
class GameCommandPacket : public Packet, public std::enable_shared_from_this<GameCommandPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
EGameCommand command;
|
EGameCommand command;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class GameEventPacket : public Packet, public enable_shared_from_this<GameEventPacket>
|
class GameEventPacket : public Packet, public std::enable_shared_from_this<GameEventPacket>
|
||||||
{
|
{
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class GetInfoPacket : public Packet, public enable_shared_from_this<GetInfoPacket>
|
class GetInfoPacket : public Packet, public std::enable_shared_from_this<GetInfoPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
virtual void read(DataInputStream *dis);
|
virtual void read(DataInputStream *dis);
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class InteractPacket : public Packet, public enable_shared_from_this<InteractPacket>
|
class InteractPacket : public Packet, public std::enable_shared_from_this<InteractPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int INTERACT;
|
static const int INTERACT;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class KeepAlivePacket : public Packet, public enable_shared_from_this<KeepAlivePacket>
|
class KeepAlivePacket : public Packet, public std::enable_shared_from_this<KeepAlivePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class KickPlayerPacket : public Packet, public enable_shared_from_this<KickPlayerPacket>
|
class KickPlayerPacket : public Packet, public std::enable_shared_from_this<KickPlayerPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
BYTE m_networkSmallId;
|
BYTE m_networkSmallId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class LevelEventPacket : public Packet, public enable_shared_from_this<LevelEventPacket>
|
class LevelEventPacket : public Packet, public std::enable_shared_from_this<LevelEventPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int type;
|
int type;
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class LevelSoundPacket : public Packet, public enable_shared_from_this<LevelSoundPacket>
|
class LevelSoundPacket : public Packet, public std::enable_shared_from_this<LevelSoundPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const float PITCH_ACCURACY;
|
static const float PITCH_ACCURACY;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ using namespace std;
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
class LevelType;
|
class LevelType;
|
||||||
|
|
||||||
class LoginPacket : public Packet, public enable_shared_from_this<LoginPacket>
|
class LoginPacket : public Packet, public std::enable_shared_from_this<LoginPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int clientVersion;
|
int clientVersion;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class MoveEntityPacket : public Packet, public enable_shared_from_this<MoveEntityPacket>
|
class MoveEntityPacket : public Packet, public std::enable_shared_from_this<MoveEntityPacket>
|
||||||
{
|
{
|
||||||
|
|
||||||
// 4J JEV, static inner/sub classes
|
// 4J JEV, static inner/sub classes
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class MoveEntityPacketSmall : public Packet, public enable_shared_from_this<MoveEntityPacketSmall>
|
class MoveEntityPacketSmall : public Packet, public std::enable_shared_from_this<MoveEntityPacketSmall>
|
||||||
{
|
{
|
||||||
|
|
||||||
// 4J JEV, static inner/sub classes
|
// 4J JEV, static inner/sub classes
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class MovePlayerPacket : public Packet, public enable_shared_from_this<MovePlayerPacket>
|
class MovePlayerPacket : public Packet, public std::enable_shared_from_this<MovePlayerPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
class PosRot;
|
class PosRot;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
class Abilities;
|
class Abilities;
|
||||||
|
|
||||||
class PlayerAbilitiesPacket : public Packet, public enable_shared_from_this<PlayerAbilitiesPacket>
|
class PlayerAbilitiesPacket : public Packet, public std::enable_shared_from_this<PlayerAbilitiesPacket>
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
static const int FLAG_INVULNERABLE = 1 << 0;
|
static const int FLAG_INVULNERABLE = 1 << 0;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class PlayerActionPacket : public Packet, public enable_shared_from_this<PlayerActionPacket>
|
class PlayerActionPacket : public Packet, public std::enable_shared_from_this<PlayerActionPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int START_DESTROY_BLOCK;
|
static const int START_DESTROY_BLOCK;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class PlayerCommandPacket : public Packet, public enable_shared_from_this<PlayerCommandPacket>
|
class PlayerCommandPacket : public Packet, public std::enable_shared_from_this<PlayerCommandPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int START_SNEAKING;
|
static const int START_SNEAKING;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ using namespace std;
|
||||||
|
|
||||||
class ServerPlayer;
|
class ServerPlayer;
|
||||||
|
|
||||||
class PlayerInfoPacket : public Packet, public enable_shared_from_this<PlayerInfoPacket>
|
class PlayerInfoPacket : public Packet, public std::enable_shared_from_this<PlayerInfoPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
// 4J Stu - I have re-purposed this packet for our uses
|
// 4J Stu - I have re-purposed this packet for our uses
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class PlayerInputPacket : public Packet, public enable_shared_from_this<PlayerInputPacket>
|
class PlayerInputPacket : public Packet, public std::enable_shared_from_this<PlayerInputPacket>
|
||||||
{
|
{
|
||||||
|
|
||||||
private:
|
private:
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class PreLoginPacket : public Packet, public enable_shared_from_this<PreLoginPacket>
|
class PreLoginPacket : public Packet, public std::enable_shared_from_this<PreLoginPacket>
|
||||||
{
|
{
|
||||||
// the login key is username client->server and sessionid server->client
|
// the login key is username client->server and sessionid server->client
|
||||||
public:
|
public:
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ using namespace std;
|
||||||
#include "../../Util/BasicTypeContainers.h"
|
#include "../../Util/BasicTypeContainers.h"
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class RemoveEntitiesPacket : public Packet, public enable_shared_from_this<RemoveEntitiesPacket>
|
class RemoveEntitiesPacket : public Packet, public std::enable_shared_from_this<RemoveEntitiesPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int MAX_PER_PACKET = Byte::MAX_VALUE;
|
static const int MAX_PER_PACKET = Byte::MAX_VALUE;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ class MobEffectInstance;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class RemoveMobEffectPacket : public Packet, public enable_shared_from_this<RemoveMobEffectPacket>
|
class RemoveMobEffectPacket : public Packet, public std::enable_shared_from_this<RemoveMobEffectPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int entityId;
|
int entityId;
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ using namespace std;
|
||||||
class LevelType;
|
class LevelType;
|
||||||
class GameType;
|
class GameType;
|
||||||
|
|
||||||
class RespawnPacket : public Packet, public enable_shared_from_this<RespawnPacket>
|
class RespawnPacket : public Packet, public std::enable_shared_from_this<RespawnPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
char dimension;
|
char dimension;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
#include "PacketListener.h"
|
#include "PacketListener.h"
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class RotateHeadPacket : public Packet, public enable_shared_from_this<RotateHeadPacket>
|
class RotateHeadPacket : public Packet, public std::enable_shared_from_this<RotateHeadPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class ServerSettingsChangedPacket : public Packet, public enable_shared_from_this<ServerSettingsChangedPacket>
|
class ServerSettingsChangedPacket : public Packet, public std::enable_shared_from_this<ServerSettingsChangedPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int HOST_DIFFICULTY;
|
static const int HOST_DIFFICULTY;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetCarriedItemPacket : public Packet, public enable_shared_from_this<SetCarriedItemPacket>
|
class SetCarriedItemPacket : public Packet, public std::enable_shared_from_this<SetCarriedItemPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int slot;
|
int slot;
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetCreativeModeSlotPacket : public Packet, public enable_shared_from_this<SetCreativeModeSlotPacket>
|
class SetCreativeModeSlotPacket : public Packet, public std::enable_shared_from_this<SetCreativeModeSlotPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int slotNum;
|
int slotNum;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ using namespace std;
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
#include "../../Entities/SyncedEntityData.h"
|
#include "../../Entities/SyncedEntityData.h"
|
||||||
|
|
||||||
class SetEntityDataPacket : public Packet, public enable_shared_from_this<SetEntityDataPacket>
|
class SetEntityDataPacket : public Packet, public std::enable_shared_from_this<SetEntityDataPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetEntityMotionPacket : public Packet, public enable_shared_from_this<SetEntityMotionPacket>
|
class SetEntityMotionPacket : public Packet, public std::enable_shared_from_this<SetEntityMotionPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetEquippedItemPacket : public Packet, public enable_shared_from_this<SetEquippedItemPacket>
|
class SetEquippedItemPacket : public Packet, public std::enable_shared_from_this<SetEquippedItemPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int entity;
|
int entity;
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetExperiencePacket : public Packet, public enable_shared_from_this<SetExperiencePacket>
|
class SetExperiencePacket : public Packet, public std::enable_shared_from_this<SetExperiencePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
float experienceProgress;
|
float experienceProgress;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetHealthPacket : public Packet, public enable_shared_from_this<SetHealthPacket>
|
class SetHealthPacket : public Packet, public std::enable_shared_from_this<SetHealthPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int health;
|
int health;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetRidingPacket : public Packet, public enable_shared_from_this<SetRidingPacket>
|
class SetRidingPacket : public Packet, public std::enable_shared_from_this<SetRidingPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int riderId, riddenId;
|
int riderId, riddenId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetSpawnPositionPacket : public Packet, public enable_shared_from_this<SetSpawnPositionPacket>
|
class SetSpawnPositionPacket : public Packet, public std::enable_shared_from_this<SetSpawnPositionPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int x, y, z;
|
int x, y, z;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SetTimePacket : public Packet, public enable_shared_from_this<SetTimePacket>
|
class SetTimePacket : public Packet, public std::enable_shared_from_this<SetTimePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
__int64 time;
|
__int64 time;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class SignUpdatePacket : public Packet, public enable_shared_from_this<SignUpdatePacket>
|
class SignUpdatePacket : public Packet, public std::enable_shared_from_this<SignUpdatePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int x, y, z;
|
int x, y, z;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class TakeItemEntityPacket : public Packet, public enable_shared_from_this<TakeItemEntityPacket>
|
class TakeItemEntityPacket : public Packet, public std::enable_shared_from_this<TakeItemEntityPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int itemId, playerId;
|
int itemId, playerId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class TeleportEntityPacket : public Packet, public enable_shared_from_this<TeleportEntityPacket>
|
class TeleportEntityPacket : public Packet, public std::enable_shared_from_this<TeleportEntityPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class TextureAndGeometryChangePacket : public Packet, public enable_shared_from_this<TextureAndGeometryChangePacket>
|
class TextureAndGeometryChangePacket : public Packet, public std::enable_shared_from_this<TextureAndGeometryChangePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -7,7 +7,7 @@ using namespace std;
|
||||||
|
|
||||||
class DLCSkinFile;
|
class DLCSkinFile;
|
||||||
|
|
||||||
class TextureAndGeometryPacket : public Packet, public enable_shared_from_this<TextureAndGeometryPacket>
|
class TextureAndGeometryPacket : public Packet, public std::enable_shared_from_this<TextureAndGeometryPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
std::wstring textureName;
|
std::wstring textureName;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class TextureChangePacket : public Packet, public enable_shared_from_this<TextureChangePacket>
|
class TextureChangePacket : public Packet, public std::enable_shared_from_this<TextureChangePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
enum ETextureChangeType
|
enum ETextureChangeType
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class TexturePacket : public Packet, public enable_shared_from_this<TexturePacket>
|
class TexturePacket : public Packet, public std::enable_shared_from_this<TexturePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
std::wstring textureName;
|
std::wstring textureName;
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class TileDestructionPacket : public Packet, public enable_shared_from_this<TileDestructionPacket>
|
class TileDestructionPacket : public Packet, public std::enable_shared_from_this<TileDestructionPacket>
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
int id;
|
int id;
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ using namespace std;
|
||||||
|
|
||||||
class CompoundTag;
|
class CompoundTag;
|
||||||
|
|
||||||
class TileEntityDataPacket : public Packet, public enable_shared_from_this<TileEntityDataPacket>
|
class TileEntityDataPacket : public Packet, public std::enable_shared_from_this<TileEntityDataPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int TYPE_MOB_SPAWNER = 1;
|
static const int TYPE_MOB_SPAWNER = 1;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class TileEventPacket : public Packet, public enable_shared_from_this<TileEventPacket>
|
class TileEventPacket : public Packet, public std::enable_shared_from_this<TileEventPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int x, y, z, b0, b1, tile;
|
int x, y, z, b0, b1, tile;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class TileUpdatePacket : public Packet, public enable_shared_from_this<TileUpdatePacket>
|
class TileUpdatePacket : public Packet, public std::enable_shared_from_this<TileUpdatePacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int x, y, z;
|
int x, y, z;
|
||||||
|
|
|
||||||
|
|
@ -10,7 +10,7 @@ using namespace std;
|
||||||
#include <iostream>
|
#include <iostream>
|
||||||
#include "PacketListener.h"
|
#include "PacketListener.h"
|
||||||
|
|
||||||
class TradeItemPacket : public Packet, public enable_shared_from_this<TradeItemPacket>
|
class TradeItemPacket : public Packet, public std::enable_shared_from_this<TradeItemPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int containerId;
|
int containerId;
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class UpdateGameRuleProgressPacket : public Packet, public enable_shared_from_this<UpdateGameRuleProgressPacket>
|
class UpdateGameRuleProgressPacket : public Packet, public std::enable_shared_from_this<UpdateGameRuleProgressPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
ConsoleGameRules::EGameRuleType m_definitionType;
|
ConsoleGameRules::EGameRuleType m_definitionType;
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@
|
||||||
|
|
||||||
class MobEffectInstance;
|
class MobEffectInstance;
|
||||||
|
|
||||||
class UpdateMobEffectPacket : public Packet, public enable_shared_from_this<UpdateMobEffectPacket>
|
class UpdateMobEffectPacket : public Packet, public std::enable_shared_from_this<UpdateMobEffectPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
int entityId;
|
int entityId;
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@ using namespace std;
|
||||||
|
|
||||||
// 4J Added packet to update clients on the time for the host to finish doing something
|
// 4J Added packet to update clients on the time for the host to finish doing something
|
||||||
|
|
||||||
class UpdateProgressPacket : public Packet, public enable_shared_from_this<UpdateProgressPacket>
|
class UpdateProgressPacket : public Packet, public std::enable_shared_from_this<UpdateProgressPacket>
|
||||||
{
|
{
|
||||||
|
|
||||||
public:
|
public:
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class UseItemPacket : public Packet, public enable_shared_from_this<UseItemPacket>
|
class UseItemPacket : public Packet, public std::enable_shared_from_this<UseItemPacket>
|
||||||
{
|
{
|
||||||
private:
|
private:
|
||||||
static const float CLICK_ACCURACY;
|
static const float CLICK_ACCURACY;
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@ using namespace std;
|
||||||
|
|
||||||
#include "Packet.h"
|
#include "Packet.h"
|
||||||
|
|
||||||
class XZPacket : public Packet, public enable_shared_from_this<XZPacket>
|
class XZPacket : public Packet, public std::enable_shared_from_this<XZPacket>
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
static const int STRONGHOLD;
|
static const int STRONGHOLD;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue