forked from project-redbud/FunGame-Core
* 抽象 ActionQueue,方便继承扩展;RoundRecord 添加了记录发动技能的字典;特效添加 IsSubsidiary 属性 * 修改包名 * modify --------- Co-authored-by: yeziuku <yezi@wrss.org>
31 lines
923 B
C#
31 lines
923 B
C#
using Milimoe.FunGame.Core.Entity;
|
|
using Milimoe.FunGame.Core.Library.Constant;
|
|
|
|
namespace Milimoe.FunGame.Core.Model
|
|
{
|
|
/// <summary>
|
|
/// 行动顺序表管理器,对 <see cref="GamingQueue"/> 的封装
|
|
/// </summary>
|
|
public class ActionQueue : GamingQueue
|
|
{
|
|
private ActionQueue() { }
|
|
|
|
/// <summary>
|
|
/// 按房间类型创建行动顺序表
|
|
/// </summary>
|
|
/// <param name="type"></param>
|
|
/// <param name="characters"></param>
|
|
/// <param name="writer"></param>
|
|
/// <returns></returns>
|
|
public static GamingQueue NewGame(RoomType type, List<Character>? characters = null, Action<string>? writer = null)
|
|
{
|
|
characters ??= [];
|
|
return type switch
|
|
{
|
|
RoomType.Team => new TeamGamingQueue(writer),
|
|
_ => new MixGamingQueue(writer)
|
|
};
|
|
}
|
|
}
|
|
}
|