# automatically generated by the FlatBuffers compiler, do not modify

# namespace: AOC

import flatbuffers

class StateChange(object):
    __slots__ = ['_tab']

    # StateChange
    def Init(self, buf, pos):
        self._tab = flatbuffers.table.Table(buf, pos)

    # StateChange
    def Id(self): return self._tab.Get(flatbuffers.number_types.Int32Flags, self._tab.Pos + flatbuffers.number_types.UOffsetTFlags.py_type(0))
    # StateChange
    def State(self): return self._tab.Get(flatbuffers.number_types.Int8Flags, self._tab.Pos + flatbuffers.number_types.UOffsetTFlags.py_type(4))
    # StateChange
    def Time(self): return self._tab.Get(flatbuffers.number_types.Uint32Flags, self._tab.Pos + flatbuffers.number_types.UOffsetTFlags.py_type(8))

def CreateStateChange(builder, id, state, time):
    builder.Prep(4, 12)
    builder.PrependUint32(time)
    builder.Pad(3)
    builder.PrependInt8(state)
    builder.PrependInt32(id)
    return builder.Offset()
