This repository has been archived on 2025-04-28. You can view files and clone it, but cannot push or open issues or pull requests.
Files
Blue-Archive---Asset-Downlo…/FlatData/ProtocolSettingExcel.py
K0lb3 16d6d3f877 flatbuf decoder added
integrated into extract_tables
2021-11-12 23:14:45 +01:00

100 lines
4.2 KiB
Python

# automatically generated by the FlatBuffers compiler, do not modify
# namespace: FlatData
import flatbuffers
from flatbuffers.compat import import_numpy
np = import_numpy()
class ProtocolSettingExcel(object):
__slots__ = ['_tab']
@classmethod
def GetRootAs(cls, buf, offset=0):
n = flatbuffers.encode.Get(flatbuffers.packer.uoffset, buf, offset)
x = ProtocolSettingExcel()
x.Init(buf, n + offset)
return x
@classmethod
def GetRootAsProtocolSettingExcel(cls, buf, offset=0):
"""This method is deprecated. Please switch to GetRootAs."""
return cls.GetRootAs(buf, offset)
# ProtocolSettingExcel
def Init(self, buf, pos):
self._tab = flatbuffers.table.Table(buf, pos)
# ProtocolSettingExcel
def Protocol(self):
o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(4))
if o != 0:
return self._tab.String(o + self._tab.Pos)
return None
# ProtocolSettingExcel
def ContentLockType_(self):
o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(6))
if o != 0:
return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
return 0
# ProtocolSettingExcel
def OpenConditionContent_(self):
o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(8))
if o != 0:
return self._tab.Get(flatbuffers.number_types.Int32Flags, o + self._tab.Pos)
return 0
# ProtocolSettingExcel
def Currency(self):
o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(10))
if o != 0:
return bool(self._tab.Get(flatbuffers.number_types.BoolFlags, o + self._tab.Pos))
return False
# ProtocolSettingExcel
def Inventory(self):
o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(12))
if o != 0:
return bool(self._tab.Get(flatbuffers.number_types.BoolFlags, o + self._tab.Pos))
return False
# ProtocolSettingExcel
def Mail(self):
o = flatbuffers.number_types.UOffsetTFlags.py_type(self._tab.Offset(14))
if o != 0:
return bool(self._tab.Get(flatbuffers.number_types.BoolFlags, o + self._tab.Pos))
return False
def Start(builder): builder.StartObject(6)
def ProtocolSettingExcelStart(builder):
"""This method is deprecated. Please switch to Start."""
return Start(builder)
def AddProtocol(builder, Protocol): builder.PrependUOffsetTRelativeSlot(0, flatbuffers.number_types.UOffsetTFlags.py_type(Protocol), 0)
def ProtocolSettingExcelAddProtocol(builder, Protocol):
"""This method is deprecated. Please switch to AddProtocol."""
return AddProtocol(builder, Protocol)
def AddContentLockType_(builder, ContentLockType_): builder.PrependInt32Slot(1, ContentLockType_, 0)
def ProtocolSettingExcelAddContentLockType_(builder, ContentLockType_):
"""This method is deprecated. Please switch to AddContentLockType_."""
return AddContentLockType_(builder, ContentLockType_)
def AddOpenConditionContent_(builder, OpenConditionContent_): builder.PrependInt32Slot(2, OpenConditionContent_, 0)
def ProtocolSettingExcelAddOpenConditionContent_(builder, OpenConditionContent_):
"""This method is deprecated. Please switch to AddOpenConditionContent_."""
return AddOpenConditionContent_(builder, OpenConditionContent_)
def AddCurrency(builder, Currency): builder.PrependBoolSlot(3, Currency, 0)
def ProtocolSettingExcelAddCurrency(builder, Currency):
"""This method is deprecated. Please switch to AddCurrency."""
return AddCurrency(builder, Currency)
def AddInventory(builder, Inventory): builder.PrependBoolSlot(4, Inventory, 0)
def ProtocolSettingExcelAddInventory(builder, Inventory):
"""This method is deprecated. Please switch to AddInventory."""
return AddInventory(builder, Inventory)
def AddMail(builder, Mail): builder.PrependBoolSlot(5, Mail, 0)
def ProtocolSettingExcelAddMail(builder, Mail):
"""This method is deprecated. Please switch to AddMail."""
return AddMail(builder, Mail)
def End(builder): return builder.EndObject()
def ProtocolSettingExcelEnd(builder):
"""This method is deprecated. Please switch to End."""
return End(builder)