#include "xanimparttrans.h"

XAnimPartTrans::XAnimPartTrans()
    : XAsset()
    , mSize(0)
    , mIsSmallTrans(false)
    , mData()
{
    SetName("Animation Part Trans");
}

XAnimPartTrans::XAnimPartTrans(const XAnimPartTrans &aSrc)
    : XAsset()
    , mSize(aSrc.mSize)
    , mIsSmallTrans(aSrc.mIsSmallTrans)
    , mData(aSrc.mData)
{

}

void XAnimPartTrans::ParseData(XDataStream *aStream) {
    if (GetPtr() == -1) {
        mSize = aStream->ParseUInt32(QString("%1 size").arg(GetName()));
        mIsSmallTrans = aStream->ParseUInt8(QString("%1 is small trans").arg(GetName())) != 0;

        // Parse data
        mData.ParseData(aStream);
    }
}

void XAnimPartTrans::Clear()
{
    mSize = 0;
    mIsSmallTrans = false;
    mData.Clear();
}




