//
// 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 WorldRaidFavorBuffExcel : IFlatbufferObject
{
private Table __p;
public ByteBuffer ByteBuffer { get { return __p.bb; } }
public static void ValidateVersion() { FlatBufferConstants.FLATBUFFERS_24_3_25(); }
public static WorldRaidFavorBuffExcel GetRootAsWorldRaidFavorBuffExcel(ByteBuffer _bb) { return GetRootAsWorldRaidFavorBuffExcel(_bb, new WorldRaidFavorBuffExcel()); }
public static WorldRaidFavorBuffExcel GetRootAsWorldRaidFavorBuffExcel(ByteBuffer _bb, WorldRaidFavorBuffExcel obj) { return (obj.__assign(_bb.GetInt(_bb.Position) + _bb.Position, _bb)); }
public void __init(int _i, ByteBuffer _bb) { __p = new Table(_i, _bb); }
public WorldRaidFavorBuffExcel __assign(int _i, ByteBuffer _bb) { __init(_i, _bb); return this; }
public long WorldRaidFavorRank { get { int o = __p.__offset(4); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } }
public long WorldRaidFavorRankBonus { get { int o = __p.__offset(6); return o != 0 ? __p.bb.GetLong(o + __p.bb_pos) : (long)0; } }
public static Offset CreateWorldRaidFavorBuffExcel(FlatBufferBuilder builder,
long WorldRaidFavorRank = 0,
long WorldRaidFavorRankBonus = 0) {
builder.StartTable(2);
WorldRaidFavorBuffExcel.AddWorldRaidFavorRankBonus(builder, WorldRaidFavorRankBonus);
WorldRaidFavorBuffExcel.AddWorldRaidFavorRank(builder, WorldRaidFavorRank);
return WorldRaidFavorBuffExcel.EndWorldRaidFavorBuffExcel(builder);
}
public static void StartWorldRaidFavorBuffExcel(FlatBufferBuilder builder) { builder.StartTable(2); }
public static void AddWorldRaidFavorRank(FlatBufferBuilder builder, long worldRaidFavorRank) { builder.AddLong(0, worldRaidFavorRank, 0); }
public static void AddWorldRaidFavorRankBonus(FlatBufferBuilder builder, long worldRaidFavorRankBonus) { builder.AddLong(1, worldRaidFavorRankBonus, 0); }
public static Offset EndWorldRaidFavorBuffExcel(FlatBufferBuilder builder) {
int o = builder.EndTable();
return new Offset(o);
}
public WorldRaidFavorBuffExcelT UnPack() {
var _o = new WorldRaidFavorBuffExcelT();
this.UnPackTo(_o);
return _o;
}
public void UnPackTo(WorldRaidFavorBuffExcelT _o) {
byte[] key = TableEncryptionService.CreateKey("WorldRaidFavorBuff");
_o.WorldRaidFavorRank = TableEncryptionService.Convert(this.WorldRaidFavorRank, key);
_o.WorldRaidFavorRankBonus = TableEncryptionService.Convert(this.WorldRaidFavorRankBonus, key);
}
public static Offset Pack(FlatBufferBuilder builder, WorldRaidFavorBuffExcelT _o) {
if (_o == null) return default(Offset);
return CreateWorldRaidFavorBuffExcel(
builder,
_o.WorldRaidFavorRank,
_o.WorldRaidFavorRankBonus);
}
}
public class WorldRaidFavorBuffExcelT
{
public long WorldRaidFavorRank { get; set; }
public long WorldRaidFavorRankBonus { get; set; }
public WorldRaidFavorBuffExcelT() {
this.WorldRaidFavorRank = 0;
this.WorldRaidFavorRankBonus = 0;
}
}
static public class WorldRaidFavorBuffExcelVerify
{
static public bool Verify(Google.FlatBuffers.Verifier verifier, uint tablePos)
{
return verifier.VerifyTableStart(tablePos)
&& verifier.VerifyField(tablePos, 4 /*WorldRaidFavorRank*/, 8 /*long*/, 8, false)
&& verifier.VerifyField(tablePos, 6 /*WorldRaidFavorRankBonus*/, 8 /*long*/, 8, false)
&& verifier.VerifyTableEnd(tablePos);
}
}
}