2014-01-19 15:38:59 +00:00
|
|
|
|
|
|
|
#pragma once
|
|
|
|
|
2014-01-19 16:52:45 +00:00
|
|
|
class cEnchantments;
|
|
|
|
class cFastNBTWriter;
|
|
|
|
class cParsedNBT;
|
2014-01-19 15:38:59 +00:00
|
|
|
|
2014-01-19 16:52:45 +00:00
|
|
|
namespace EnchantmentSerializer
|
2014-01-19 15:38:59 +00:00
|
|
|
{
|
|
|
|
|
|
|
|
/// Writes the enchantments into the specified NBT writer; begins with the LIST tag of the specified name ("ench" or "StoredEnchantments")
|
2014-01-19 16:52:45 +00:00
|
|
|
void WriteToNBTCompound(cEnchantments const& a_Enchantments, cFastNBTWriter & a_Writer, const AString & a_ListTagName);
|
2014-01-19 15:38:59 +00:00
|
|
|
|
|
|
|
/// Reads the enchantments from the specified NBT list tag (ench or StoredEnchantments)
|
2014-01-19 16:52:45 +00:00
|
|
|
void ParseFromNBT(cEnchantments& a_Enchantments, const cParsedNBT & a_NBT, int a_EnchListTagIdx);
|
2014-01-19 15:38:59 +00:00
|
|
|
|
|
|
|
};
|