//
// 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 CharacterWeaponExpBonusExcel : IFlatbufferObject
{
private Table __p;
public ByteBuffer ByteBuffer { get { return __p.bb; } }
public static void ValidateVersion() { FlatBufferConstants.FLATBUFFERS_24_3_25(); }
public static CharacterWeaponExpBonusExcel GetRootAsCharacterWeaponExpBonusExcel(ByteBuffer _bb) { return GetRootAsCharacterWeaponExpBonusExcel(_bb, new CharacterWeaponExpBonusExcel()); }
public static CharacterWeaponExpBonusExcel GetRootAsCharacterWeaponExpBonusExcel(ByteBuffer _bb, CharacterWeaponExpBonusExcel obj) { return (obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); }
public void __init(int _i, ByteBuffer _bb) { __p = new Table(_i, _bb); }
public CharacterWeaponExpBonusExcel __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; }
public SCHALE.Common.FlatData.WeaponType WeaponType_ { get { int o = __p.__offset(4); return o != 0 ? (SCHALE.Common.FlatData.WeaponType)__p.bb.GetInt(o + __p.bb_pos) : SCHALE.Common.FlatData.WeaponType.None; } }
public int WeaponExpGrowthA { get { int o = __p.__offset(6); return o != 0 ? __p.bb.GetInt(o + __p.bb_pos) : (int)0; } }
public int WeaponExpGrowthB { get { int o = __p.__offset(8); return o != 0 ? __p.bb.GetInt(o + __p.bb_pos) : (int)0; } }
public int WeaponExpGrowthC { get { int o = __p.__offset(10); return o != 0 ? __p.bb.GetInt(o + __p.bb_pos) : (int)0; } }
public int WeaponExpGrowthZ { get { int o = __p.__offset(12); return o != 0 ? __p.bb.GetInt(o + __p.bb_pos) : (int)0; } }
public static Offset CreateCharacterWeaponExpBonusExcel(FlatBufferBuilder builder,
SCHALE.Common.FlatData.WeaponType WeaponType_ = SCHALE.Common.FlatData.WeaponType.None,
int WeaponExpGrowthA = 0,
int WeaponExpGrowthB = 0,
int WeaponExpGrowthC = 0,
int WeaponExpGrowthZ = 0) {
builder.StartTable(5);
CharacterWeaponExpBonusExcel.AddWeaponExpGrowthZ(builder, WeaponExpGrowthZ);
CharacterWeaponExpBonusExcel.AddWeaponExpGrowthC(builder, WeaponExpGrowthC);
CharacterWeaponExpBonusExcel.AddWeaponExpGrowthB(builder, WeaponExpGrowthB);
CharacterWeaponExpBonusExcel.AddWeaponExpGrowthA(builder, WeaponExpGrowthA);
CharacterWeaponExpBonusExcel.AddWeaponType_(builder, WeaponType_);
return CharacterWeaponExpBonusExcel.EndCharacterWeaponExpBonusExcel(builder);
}
public static void StartCharacterWeaponExpBonusExcel(FlatBufferBuilder builder) { builder.StartTable(5); }
public static void AddWeaponType_(FlatBufferBuilder builder, SCHALE.Common.FlatData.WeaponType weaponType_) { builder.AddInt(0, (int)weaponType_, 0); }
public static void AddWeaponExpGrowthA(FlatBufferBuilder builder, int weaponExpGrowthA) { builder.AddInt(1, weaponExpGrowthA, 0); }
public static void AddWeaponExpGrowthB(FlatBufferBuilder builder, int weaponExpGrowthB) { builder.AddInt(2, weaponExpGrowthB, 0); }
public static void AddWeaponExpGrowthC(FlatBufferBuilder builder, int weaponExpGrowthC) { builder.AddInt(3, weaponExpGrowthC, 0); }
public static void AddWeaponExpGrowthZ(FlatBufferBuilder builder, int weaponExpGrowthZ) { builder.AddInt(4, weaponExpGrowthZ, 0); }
public static Offset EndCharacterWeaponExpBonusExcel(FlatBufferBuilder builder) {
int o = builder.EndTable();
return new Offset(o);
}
public CharacterWeaponExpBonusExcelT UnPack() {
var _o = new CharacterWeaponExpBonusExcelT();
this.UnPackTo(_o);
return _o;
}
public void UnPackTo(CharacterWeaponExpBonusExcelT _o) {
byte[] key = TableEncryptionService.CreateKey("CharacterWeaponExpBonus");
_o.WeaponType_ = TableEncryptionService.Convert(this.WeaponType_, key);
_o.WeaponExpGrowthA = TableEncryptionService.Convert(this.WeaponExpGrowthA, key);
_o.WeaponExpGrowthB = TableEncryptionService.Convert(this.WeaponExpGrowthB, key);
_o.WeaponExpGrowthC = TableEncryptionService.Convert(this.WeaponExpGrowthC, key);
_o.WeaponExpGrowthZ = TableEncryptionService.Convert(this.WeaponExpGrowthZ, key);
}
public static Offset Pack(FlatBufferBuilder builder, CharacterWeaponExpBonusExcelT _o) {
if (_o == null) return default(Offset);
return CreateCharacterWeaponExpBonusExcel(
builder,
_o.WeaponType_,
_o.WeaponExpGrowthA,
_o.WeaponExpGrowthB,
_o.WeaponExpGrowthC,
_o.WeaponExpGrowthZ);
}
}
public class CharacterWeaponExpBonusExcelT
{
public SCHALE.Common.FlatData.WeaponType WeaponType_ { get; set; }
public int WeaponExpGrowthA { get; set; }
public int WeaponExpGrowthB { get; set; }
public int WeaponExpGrowthC { get; set; }
public int WeaponExpGrowthZ { get; set; }
public CharacterWeaponExpBonusExcelT() {
this.WeaponType_ = SCHALE.Common.FlatData.WeaponType.None;
this.WeaponExpGrowthA = 0;
this.WeaponExpGrowthB = 0;
this.WeaponExpGrowthC = 0;
this.WeaponExpGrowthZ = 0;
}
}
static public class CharacterWeaponExpBonusExcelVerify
{
static public bool Verify(Google.FlatBuffers.Verifier verifier, uint tablePos)
{
return verifier.VerifyTableStart(tablePos)
&& verifier.VerifyField(tablePos, 4 /*WeaponType_*/, 4 /*SCHALE.Common.FlatData.WeaponType*/, 4, false)
&& verifier.VerifyField(tablePos, 6 /*WeaponExpGrowthA*/, 4 /*int*/, 4, false)
&& verifier.VerifyField(tablePos, 8 /*WeaponExpGrowthB*/, 4 /*int*/, 4, false)
&& verifier.VerifyField(tablePos, 10 /*WeaponExpGrowthC*/, 4 /*int*/, 4, false)
&& verifier.VerifyField(tablePos, 12 /*WeaponExpGrowthZ*/, 4 /*int*/, 4, false)
&& verifier.VerifyTableEnd(tablePos);
}
}
}