// // 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 TacticEntityEffectFilterExcel : IFlatbufferObject { private Table __p; public ByteBuffer ByteBuffer { get { return __p.bb; } } public static void ValidateVersion() { FlatBufferConstants.FLATBUFFERS_24_3_25(); } public static TacticEntityEffectFilterExcel GetRootAsTacticEntityEffectFilterExcel(ByteBuffer _bb) { return GetRootAsTacticEntityEffectFilterExcel(_bb, new TacticEntityEffectFilterExcel()); } public static TacticEntityEffectFilterExcel GetRootAsTacticEntityEffectFilterExcel(ByteBuffer _bb, TacticEntityEffectFilterExcel obj) { return (obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); } public void __init(int _i, ByteBuffer _bb) { __p = new Table(_i, _bb); } public TacticEntityEffectFilterExcel __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; } public string TargetEffectName { get { int o = __p.__offset(4); return o != 0 ? __p.__string(o + __p.bb_pos) : null; } } #if ENABLE_SPAN_T public Span GetTargetEffectNameBytes() { return __p.__vector_as_span(4, 1); } #else public ArraySegment? GetTargetEffectNameBytes() { return __p.__vector_as_arraysegment(4); } #endif public byte[] GetTargetEffectNameArray() { return __p.__vector_as_array(4); } public bool ShowEffectToVehicle { get { int o = __p.__offset(6); return o != 0 ? 0!=__p.bb.Get(o + __p.bb_pos) : (bool)false; } } public bool ShowEffectToBoss { get { int o = __p.__offset(8); return o != 0 ? 0!=__p.bb.Get(o + __p.bb_pos) : (bool)false; } } public static Offset CreateTacticEntityEffectFilterExcel(FlatBufferBuilder builder, StringOffset TargetEffectNameOffset = default(StringOffset), bool ShowEffectToVehicle = false, bool ShowEffectToBoss = false) { builder.StartTable(3); TacticEntityEffectFilterExcel.AddTargetEffectName(builder, TargetEffectNameOffset); TacticEntityEffectFilterExcel.AddShowEffectToBoss(builder, ShowEffectToBoss); TacticEntityEffectFilterExcel.AddShowEffectToVehicle(builder, ShowEffectToVehicle); return TacticEntityEffectFilterExcel.EndTacticEntityEffectFilterExcel(builder); } public static void StartTacticEntityEffectFilterExcel(FlatBufferBuilder builder) { builder.StartTable(3); } public static void AddTargetEffectName(FlatBufferBuilder builder, StringOffset targetEffectNameOffset) { builder.AddOffset(0, targetEffectNameOffset.Value, 0); } public static void AddShowEffectToVehicle(FlatBufferBuilder builder, bool showEffectToVehicle) { builder.AddBool(1, showEffectToVehicle, false); } public static void AddShowEffectToBoss(FlatBufferBuilder builder, bool showEffectToBoss) { builder.AddBool(2, showEffectToBoss, false); } public static Offset EndTacticEntityEffectFilterExcel(FlatBufferBuilder builder) { int o = builder.EndTable(); return new Offset(o); } public TacticEntityEffectFilterExcelT UnPack() { var _o = new TacticEntityEffectFilterExcelT(); this.UnPackTo(_o); return _o; } public void UnPackTo(TacticEntityEffectFilterExcelT _o) { byte[] key = TableEncryptionService.CreateKey("TacticEntityEffectFilter"); _o.TargetEffectName = TableEncryptionService.Convert(this.TargetEffectName, key); _o.ShowEffectToVehicle = TableEncryptionService.Convert(this.ShowEffectToVehicle, key); _o.ShowEffectToBoss = TableEncryptionService.Convert(this.ShowEffectToBoss, key); } public static Offset Pack(FlatBufferBuilder builder, TacticEntityEffectFilterExcelT _o) { if (_o == null) return default(Offset); var _TargetEffectName = _o.TargetEffectName == null ? default(StringOffset) : builder.CreateString(_o.TargetEffectName); return CreateTacticEntityEffectFilterExcel( builder, _TargetEffectName, _o.ShowEffectToVehicle, _o.ShowEffectToBoss); } } public class TacticEntityEffectFilterExcelT { public string TargetEffectName { get; set; } public bool ShowEffectToVehicle { get; set; } public bool ShowEffectToBoss { get; set; } public TacticEntityEffectFilterExcelT() { this.TargetEffectName = null; this.ShowEffectToVehicle = false; this.ShowEffectToBoss = false; } } static public class TacticEntityEffectFilterExcelVerify { static public bool Verify(Google.FlatBuffers.Verifier verifier, uint tablePos) { return verifier.VerifyTableStart(tablePos) && verifier.VerifyString(tablePos, 4 /*TargetEffectName*/, false) && verifier.VerifyField(tablePos, 6 /*ShowEffectToVehicle*/, 1 /*bool*/, 1, false) && verifier.VerifyField(tablePos, 8 /*ShowEffectToBoss*/, 1 /*bool*/, 1, false) && verifier.VerifyTableEnd(tablePos); } } }