// // automatically generated by the FlatBuffers compiler, do not modify // namespace SCHALE.Common.FlatData { using global::System; using global::System.Collections.Generic; using global::SCHALE.Common.Crypto; using global::Google.FlatBuffers; public struct MiniGameDreamParameterExcel : IFlatbufferObject { private Table __p; public ByteBuffer ByteBuffer { get { return __p.bb; } } public static void ValidateVersion() { FlatBufferConstants.FLATBUFFERS_24_3_25(); } public static MiniGameDreamParameterExcel GetRootAsMiniGameDreamParameterExcel(ByteBuffer _bb) { return GetRootAsMiniGameDreamParameterExcel(_bb, new MiniGameDreamParameterExcel()); } public static MiniGameDreamParameterExcel GetRootAsMiniGameDreamParameterExcel(ByteBuffer _bb, MiniGameDreamParameterExcel obj) { return (obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); } public void __init(int _i, ByteBuffer _bb) { __p = new Table(_i, _bb); } public MiniGameDreamParameterExcel __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; } public long Id { get { int o = __p.__offset(4); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public long EventContentId { get { int o = __p.__offset(6); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public SCHALE.Common.FlatData.DreamMakerParameterType ParameterType { get { int o = __p.__offset(8); return o != 0 ? (SCHALE.Common.FlatData.DreamMakerParameterType)__p.bb.GetInt(o + __p.bb_pos) : SCHALE.Common.FlatData.DreamMakerParameterType.None; } } public uint LocalizeEtcId { get { int o = __p.__offset(10); return o != 0 ? __p.bb.GetUint(o + __p.bb_pos) : (uint)0; } } public string IconPath { get { int o = __p.__offset(12); return o != 0 ? __p.__string(o + __p.bb_pos) : null; } } #if ENABLE_SPAN_T public Span GetIconPathBytes() { return __p.__vector_as_span(12, 1); } #else public ArraySegment? GetIconPathBytes() { return __p.__vector_as_arraysegment(12); } #endif public byte[] GetIconPathArray() { return __p.__vector_as_array(12); } public long ParameterBase { get { int o = __p.__offset(14); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public long ParameterBaseMax { get { int o = __p.__offset(16); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public long ParameterMin { get { int o = __p.__offset(18); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public long ParameterMax { get { int o = __p.__offset(20); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } } public static Offset CreateMiniGameDreamParameterExcel(FlatBufferBuilder builder, long Id = 0, long EventContentId = 0, SCHALE.Common.FlatData.DreamMakerParameterType ParameterType = SCHALE.Common.FlatData.DreamMakerParameterType.None, uint LocalizeEtcId = 0, StringOffset IconPathOffset = default(StringOffset), long ParameterBase = 0, long ParameterBaseMax = 0, long ParameterMin = 0, long ParameterMax = 0) { builder.StartTable(9); MiniGameDreamParameterExcel.AddParameterMax(builder, ParameterMax); MiniGameDreamParameterExcel.AddParameterMin(builder, ParameterMin); MiniGameDreamParameterExcel.AddParameterBaseMax(builder, ParameterBaseMax); MiniGameDreamParameterExcel.AddParameterBase(builder, ParameterBase); MiniGameDreamParameterExcel.AddEventContentId(builder, EventContentId); MiniGameDreamParameterExcel.AddId(builder, Id); MiniGameDreamParameterExcel.AddIconPath(builder, IconPathOffset); MiniGameDreamParameterExcel.AddLocalizeEtcId(builder, LocalizeEtcId); MiniGameDreamParameterExcel.AddParameterType(builder, ParameterType); return MiniGameDreamParameterExcel.EndMiniGameDreamParameterExcel(builder); } public static void StartMiniGameDreamParameterExcel(FlatBufferBuilder builder) { builder.StartTable(9); } public static void AddId(FlatBufferBuilder builder, long id) { builder.AddLong(0, id, 0); } public static void AddEventContentId(FlatBufferBuilder builder, long eventContentId) { builder.AddLong(1, eventContentId, 0); } public static void AddParameterType(FlatBufferBuilder builder, SCHALE.Common.FlatData.DreamMakerParameterType parameterType) { builder.AddInt(2, (int)parameterType, 0); } public static void AddLocalizeEtcId(FlatBufferBuilder builder, uint localizeEtcId) { builder.AddUint(3, localizeEtcId, 0); } public static void AddIconPath(FlatBufferBuilder builder, StringOffset iconPathOffset) { builder.AddOffset(4, iconPathOffset.Value, 0); } public static void AddParameterBase(FlatBufferBuilder builder, long parameterBase) { builder.AddLong(5, parameterBase, 0); } public static void AddParameterBaseMax(FlatBufferBuilder builder, long parameterBaseMax) { builder.AddLong(6, parameterBaseMax, 0); } public static void AddParameterMin(FlatBufferBuilder builder, long parameterMin) { builder.AddLong(7, parameterMin, 0); } public static void AddParameterMax(FlatBufferBuilder builder, long parameterMax) { builder.AddLong(8, parameterMax, 0); } public static Offset EndMiniGameDreamParameterExcel(FlatBufferBuilder builder) { int o = builder.EndTable(); return new Offset(o); } public MiniGameDreamParameterExcelT UnPack() { var _o = new MiniGameDreamParameterExcelT(); this.UnPackTo(_o); return _o; } public void UnPackTo(MiniGameDreamParameterExcelT _o) { byte[] key = TableEncryptionService.CreateKey("MiniGameDreamParameter"); _o.Id = TableEncryptionService.Convert(this.Id, key); _o.EventContentId = TableEncryptionService.Convert(this.EventContentId, key); _o.ParameterType = TableEncryptionService.Convert(this.ParameterType, key); _o.LocalizeEtcId = TableEncryptionService.Convert(this.LocalizeEtcId, key); _o.IconPath = TableEncryptionService.Convert(this.IconPath, key); _o.ParameterBase = TableEncryptionService.Convert(this.ParameterBase, key); _o.ParameterBaseMax = TableEncryptionService.Convert(this.ParameterBaseMax, key); _o.ParameterMin = TableEncryptionService.Convert(this.ParameterMin, key); _o.ParameterMax = TableEncryptionService.Convert(this.ParameterMax, key); } public static Offset Pack(FlatBufferBuilder builder, MiniGameDreamParameterExcelT _o) { if (_o == null) return default(Offset); var _IconPath = _o.IconPath == null ? default(StringOffset) : builder.CreateString(_o.IconPath); return CreateMiniGameDreamParameterExcel( builder, _o.Id, _o.EventContentId, _o.ParameterType, _o.LocalizeEtcId, _IconPath, _o.ParameterBase, _o.ParameterBaseMax, _o.ParameterMin, _o.ParameterMax); } } public class MiniGameDreamParameterExcelT { public long Id { get; set; } public long EventContentId { get; set; } public SCHALE.Common.FlatData.DreamMakerParameterType ParameterType { get; set; } public uint LocalizeEtcId { get; set; } public string IconPath { get; set; } public long ParameterBase { get; set; } public long ParameterBaseMax { get; set; } public long ParameterMin { get; set; } public long ParameterMax { get; set; } public MiniGameDreamParameterExcelT() { this.Id = 0; this.EventContentId = 0; this.ParameterType = SCHALE.Common.FlatData.DreamMakerParameterType.None; this.LocalizeEtcId = 0; this.IconPath = null; this.ParameterBase = 0; this.ParameterBaseMax = 0; this.ParameterMin = 0; this.ParameterMax = 0; } } static public class MiniGameDreamParameterExcelVerify { static public bool Verify(Google.FlatBuffers.Verifier verifier, uint tablePos) { return verifier.VerifyTableStart(tablePos) && verifier.VerifyField(tablePos, 4 /*Id*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 6 /*EventContentId*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 8 /*ParameterType*/, 4 /*SCHALE.Common.FlatData.DreamMakerParameterType*/, 4, false) && verifier.VerifyField(tablePos, 10 /*LocalizeEtcId*/, 4 /*uint*/, 4, false) && verifier.VerifyString(tablePos, 12 /*IconPath*/, false) && verifier.VerifyField(tablePos, 14 /*ParameterBase*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 16 /*ParameterBaseMax*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 18 /*ParameterMin*/, 8 /*long*/, 8, false) && verifier.VerifyField(tablePos, 20 /*ParameterMax*/, 8 /*long*/, 8, false) && verifier.VerifyTableEnd(tablePos); } } }