SCHALE.GameServer/SCHALE.Common/FlatData/ScenarioBGNameExcel.cs

109 lines
6.9 KiB
C#
Raw Normal View History

2024-04-21 00:21:57 +00:00
// <auto-generated>
// automatically generated by the FlatBuffers compiler, do not modify
// </auto-generated>
namespace SCHALE.Common.FlatData
{
using global::System;
using global::System.Collections.Generic;
using global::Google.FlatBuffers;
public struct ScenarioBGNameExcel : IFlatbufferObject
{
private Table __p;
public ByteBuffer ByteBuffer { get { return __p.bb; } }
public static void ValidateVersion() { FlatBufferConstants.FLATBUFFERS_24_3_25(); }
public static ScenarioBGNameExcel GetRootAsScenarioBGNameExcel(ByteBuffer _bb) { return GetRootAsScenarioBGNameExcel(_bb, new ScenarioBGNameExcel()); }
public static ScenarioBGNameExcel GetRootAsScenarioBGNameExcel(ByteBuffer _bb, ScenarioBGNameExcel obj) { return (obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); }
public void __init(int _i, ByteBuffer _bb) { __p = new Table(_i, _bb); }
public ScenarioBGNameExcel __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; }
public uint Name { get { int o = __p.__offset(4); return o != 0 ? __p.bb.GetUint(o + __p.bb_pos) : (uint)0; } }
public SCHALE.Common.FlatData.ProductionStep ProductionStep { get { int o = __p.__offset(6); return o != 0 ? (SCHALE.Common.FlatData.ProductionStep)__p.bb.GetInt(o + __p.bb_pos) : SCHALE.Common.FlatData.ProductionStep.ToDo; } }
public string BGFileName { get { int o = __p.__offset(8); return o != 0 ? __p.__string(o + __p.bb_pos) : null; } }
#if ENABLE_SPAN_T
public Span<byte> GetBGFileNameBytes() { return __p.__vector_as_span<byte>(8, 1); }
#else
public ArraySegment<byte>? GetBGFileNameBytes() { return __p.__vector_as_arraysegment(8); }
#endif
public byte[] GetBGFileNameArray() { return __p.__vector_as_array<byte>(8); }
public SCHALE.Common.FlatData.ScenarioBGType BGType { get { int o = __p.__offset(10); return o != 0 ? (SCHALE.Common.FlatData.ScenarioBGType)__p.bb.GetInt(o + __p.bb_pos) : SCHALE.Common.FlatData.ScenarioBGType.None; } }
public string AnimationRoot { get { int o = __p.__offset(12); return o != 0 ? __p.__string(o + __p.bb_pos) : null; } }
#if ENABLE_SPAN_T
public Span<byte> GetAnimationRootBytes() { return __p.__vector_as_span<byte>(12, 1); }
#else
public ArraySegment<byte>? GetAnimationRootBytes() { return __p.__vector_as_arraysegment(12); }
#endif
public byte[] GetAnimationRootArray() { return __p.__vector_as_array<byte>(12); }
public string AnimationName { get { int o = __p.__offset(14); return o != 0 ? __p.__string(o + __p.bb_pos) : null; } }
#if ENABLE_SPAN_T
public Span<byte> GetAnimationNameBytes() { return __p.__vector_as_span<byte>(14, 1); }
#else
public ArraySegment<byte>? GetAnimationNameBytes() { return __p.__vector_as_arraysegment(14); }
#endif
public byte[] GetAnimationNameArray() { return __p.__vector_as_array<byte>(14); }
public float SpineScale { get { int o = __p.__offset(16); return o != 0 ? __p.bb.GetFloat(o + __p.bb_pos) : (float)0.0f; } }
public int SpineLocalPosX { get { int o = __p.__offset(18); return o != 0 ? __p.bb.GetInt(o + __p.bb_pos) : (int)0; } }
public int SpineLocalPosY { get { int o = __p.__offset(20); return o != 0 ? __p.bb.GetInt(o + __p.bb_pos) : (int)0; } }
public static Offset<SCHALE.Common.FlatData.ScenarioBGNameExcel> CreateScenarioBGNameExcel(FlatBufferBuilder builder,
uint Name = 0,
SCHALE.Common.FlatData.ProductionStep ProductionStep = SCHALE.Common.FlatData.ProductionStep.ToDo,
StringOffset BGFileNameOffset = default(StringOffset),
SCHALE.Common.FlatData.ScenarioBGType BGType = SCHALE.Common.FlatData.ScenarioBGType.None,
StringOffset AnimationRootOffset = default(StringOffset),
StringOffset AnimationNameOffset = default(StringOffset),
float SpineScale = 0.0f,
int SpineLocalPosX = 0,
int SpineLocalPosY = 0) {
builder.StartTable(9);
ScenarioBGNameExcel.AddSpineLocalPosY(builder, SpineLocalPosY);
ScenarioBGNameExcel.AddSpineLocalPosX(builder, SpineLocalPosX);
ScenarioBGNameExcel.AddSpineScale(builder, SpineScale);
ScenarioBGNameExcel.AddAnimationName(builder, AnimationNameOffset);
ScenarioBGNameExcel.AddAnimationRoot(builder, AnimationRootOffset);
ScenarioBGNameExcel.AddBGType(builder, BGType);
ScenarioBGNameExcel.AddBGFileName(builder, BGFileNameOffset);
ScenarioBGNameExcel.AddProductionStep(builder, ProductionStep);
ScenarioBGNameExcel.AddName(builder, Name);
return ScenarioBGNameExcel.EndScenarioBGNameExcel(builder);
}
public static void StartScenarioBGNameExcel(FlatBufferBuilder builder) { builder.StartTable(9); }
public static void AddName(FlatBufferBuilder builder, uint name) { builder.AddUint(0, name, 0); }
public static void AddProductionStep(FlatBufferBuilder builder, SCHALE.Common.FlatData.ProductionStep productionStep) { builder.AddInt(1, (int)productionStep, 0); }
public static void AddBGFileName(FlatBufferBuilder builder, StringOffset bGFileNameOffset) { builder.AddOffset(2, bGFileNameOffset.Value, 0); }
public static void AddBGType(FlatBufferBuilder builder, SCHALE.Common.FlatData.ScenarioBGType bGType) { builder.AddInt(3, (int)bGType, 0); }
public static void AddAnimationRoot(FlatBufferBuilder builder, StringOffset animationRootOffset) { builder.AddOffset(4, animationRootOffset.Value, 0); }
public static void AddAnimationName(FlatBufferBuilder builder, StringOffset animationNameOffset) { builder.AddOffset(5, animationNameOffset.Value, 0); }
public static void AddSpineScale(FlatBufferBuilder builder, float spineScale) { builder.AddFloat(6, spineScale, 0.0f); }
public static void AddSpineLocalPosX(FlatBufferBuilder builder, int spineLocalPosX) { builder.AddInt(7, spineLocalPosX, 0); }
public static void AddSpineLocalPosY(FlatBufferBuilder builder, int spineLocalPosY) { builder.AddInt(8, spineLocalPosY, 0); }
public static Offset<SCHALE.Common.FlatData.ScenarioBGNameExcel> EndScenarioBGNameExcel(FlatBufferBuilder builder) {
int o = builder.EndTable();
return new Offset<SCHALE.Common.FlatData.ScenarioBGNameExcel>(o);
}
}
static public class ScenarioBGNameExcelVerify
{
static public bool Verify(Google.FlatBuffers.Verifier verifier, uint tablePos)
{
return verifier.VerifyTableStart(tablePos)
&& verifier.VerifyField(tablePos, 4 /*Name*/, 4 /*uint*/, 4, false)
&& verifier.VerifyField(tablePos, 6 /*ProductionStep*/, 4 /*SCHALE.Common.FlatData.ProductionStep*/, 4, false)
&& verifier.VerifyString(tablePos, 8 /*BGFileName*/, false)
&& verifier.VerifyField(tablePos, 10 /*BGType*/, 4 /*SCHALE.Common.FlatData.ScenarioBGType*/, 4, false)
&& verifier.VerifyString(tablePos, 12 /*AnimationRoot*/, false)
&& verifier.VerifyString(tablePos, 14 /*AnimationName*/, false)
&& verifier.VerifyField(tablePos, 16 /*SpineScale*/, 4 /*float*/, 4, false)
&& verifier.VerifyField(tablePos, 18 /*SpineLocalPosX*/, 4 /*int*/, 4, false)
&& verifier.VerifyField(tablePos, 20 /*SpineLocalPosY*/, 4 /*int*/, 4, false)
&& verifier.VerifyTableEnd(tablePos);
}
}
}