84 lines
2.3 KiB
C#
84 lines
2.3 KiB
C#
|
|
//------------------------------------------------------------------------------
|
|
// <auto-generated>
|
|
// This code was generated by a tool.
|
|
// Changes to this file may cause incorrect behavior and will be lost if
|
|
// the code is regenerated.
|
|
// </auto-generated>
|
|
//------------------------------------------------------------------------------
|
|
|
|
using Luban;
|
|
|
|
|
|
namespace SepCore.Definition
|
|
{
|
|
public sealed partial class BattleActionConfig : Luban.BeanBase
|
|
{
|
|
public BattleActionConfig(ByteBuf _buf)
|
|
{
|
|
Id = _buf.ReadInt();
|
|
Name = _buf.ReadString();
|
|
ActionType = (BattleActionType)_buf.ReadInt();
|
|
TargetType = (BattleTargetType)_buf.ReadInt();
|
|
MpCost = _buf.ReadInt();
|
|
{int n0 = System.Math.Min(_buf.ReadSize(), _buf.Size);Effects = new System.Collections.Generic.List<BattleEffect>(n0);for(var i0 = 0 ; i0 < n0 ; i0++) { BattleEffect _e0; _e0 = BattleEffect.DeserializeBattleEffect(_buf); Effects.Add(_e0);}}
|
|
}
|
|
|
|
public static BattleActionConfig DeserializeBattleActionConfig(ByteBuf _buf)
|
|
{
|
|
return new BattleActionConfig(_buf);
|
|
}
|
|
|
|
/// <summary>
|
|
/// 行动ID
|
|
/// </summary>
|
|
public readonly int Id;
|
|
/// <summary>
|
|
/// 显示名
|
|
/// </summary>
|
|
public readonly string Name;
|
|
/// <summary>
|
|
/// 行动类型
|
|
/// </summary>
|
|
public readonly BattleActionType ActionType;
|
|
/// <summary>
|
|
/// 目标选择方式
|
|
/// </summary>
|
|
public readonly BattleTargetType TargetType;
|
|
/// <summary>
|
|
/// MP消耗
|
|
/// </summary>
|
|
public readonly int MpCost;
|
|
/// <summary>
|
|
/// 简单数值效果列表
|
|
/// </summary>
|
|
public readonly System.Collections.Generic.List<BattleEffect> Effects;
|
|
|
|
public const int __ID__ = -690357744;
|
|
public override int GetTypeId() => __ID__;
|
|
|
|
public void ResolveRef(Tables tables)
|
|
{
|
|
|
|
|
|
|
|
|
|
|
|
foreach (var _e in Effects) { _e?.ResolveRef(tables); }
|
|
}
|
|
|
|
public override string ToString()
|
|
{
|
|
return "{ "
|
|
+ "id:" + Id + ","
|
|
+ "name:" + Name + ","
|
|
+ "actionType:" + ActionType + ","
|
|
+ "targetType:" + TargetType + ","
|
|
+ "mpCost:" + MpCost + ","
|
|
+ "effects:" + Luban.StringUtil.CollectionToString(Effects) + ","
|
|
+ "}";
|
|
}
|
|
}
|
|
|
|
}
|