the whole game

This commit is contained in:
2026-03-02 22:04:18 +03:00
parent 816e9060b4
commit f0617a5d22
2069 changed files with 581500 additions and 0 deletions

26
src/nbt/NbtIo.h Executable file
View File

@@ -0,0 +1,26 @@
#ifndef COM_MOJANG_NBT__NbtIo_H__
#define COM_MOJANG_NBT__NbtIo_H__
//package com.mojang.nbt;
#include "CompoundTag.h"
#include "../util/DataIO.h"
class NbtIo
{
public:
static CompoundTag* read(IDataInput* dis) {
Tag *tag = Tag::readNamedTag(dis);
if (tag && tag->getId() == Tag::TAG_Compound)
return (CompoundTag*) tag;
return NULL;
}
static bool write(CompoundTag* tag, IDataOutput* dos) {
if (!tag) return false;
Tag::writeNamedTag(tag, dos);
return false;
}
};
#endif /*COM_MOJANG_NBT__NbtIo_H__*/