123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657 |
- // Generate By EToy
- // Don't Edit It!!
- using XGame.Framework.Database;
- using XGame.Framework.Serialization;
- namespace XGame.Database
- {
- /// <summary> Map </summary>
- public sealed class MapTable : ITable
- {
- long ITable.Key => Id;
- /// <summary> 主键 </summary>
- public int Id { get; private set; }
- /// <summary> 地图名字 </summary>
- public string Name { get; private set; }
- /// <summary> 资源名字 </summary>
- public string AssetName { get; private set; } // c
- /// <summary> 玩家出生点 </summary>
- public Vec3 PlayerBirth { get; private set; }
- /// <summary> 初始战斗地点,Chapter.part==1的位置 </summary>
- public Vec3 BattleFirst { get; private set; }
- /// <summary> 怪物出生点,一个取中间,2个左右对称偏移 </summary>
- public Vec3 MonsterBirth { get; private set; }
- /// <summary> 每个章节向前移动的距离 </summary>
- public Vec3 PartMove { get; private set; }
- void ISerializable.Deserialize(IReader reader)
- {
- Id = reader.ReadInt();
- Name = reader.ReadString();
- AssetName = reader.ReadString();
- PlayerBirth = reader.ReadSerializable<Vec3>();
- BattleFirst = reader.ReadSerializable<Vec3>();
- MonsterBirth = reader.ReadSerializable<Vec3>();
- PartMove = reader.ReadSerializable<Vec3>();
- }
- void ISerializable.Serialize(IWriter writer)
- {
- writer.Write(Id);
- writer.Write(Name);
- writer.Write(AssetName);
- writer.Write(PlayerBirth);
- writer.Write(BattleFirst);
- writer.Write(MonsterBirth);
- writer.Write(PartMove);
- }
- }
- }
|