Files
gamer147 0d9d8acae0 feat(battle-engine): M1 auto-copy closure (782 battle-logic files)
Compile-driven bulk-copy loop (tools/engine-port/m1_copy_loop.py) pulled the precise reference closure of the battle-core roots, stopping at the classify god-object/View-VFX-UI boundary. 782 files; no re-explosion (M0 had estimated ~order 1000). Residual frontier = 52 shim-classified + 80 external (Unity/BCL) types to author next.
2026-06-05 16:57:20 -04:00

75 lines
1.2 KiB
C#

using System.Collections.Generic;
using System.Linq;
namespace Wizard;
public class SleeveMgr
{
private List<Sleeve> _list = new List<Sleeve>();
public void Add(Sleeve sleeve)
{
_list.Add(sleeve);
}
public List<Sleeve> GetList()
{
return _list;
}
public List<Sleeve> GetAcquiredList()
{
return _list.FindAll((Sleeve x) => x.IsAcquired);
}
public IEnumerable<long> GetFavorites()
{
return from x in _list.FindAll((Sleeve x) => x.IsFavorite)
select x.sleeve_id;
}
public bool IsContainsInMaster(long id)
{
return _list.Find((Sleeve x) => x.sleeve_id == id) != null;
}
public Sleeve Get(long id)
{
Sleeve sleeve = _list.Find((Sleeve x) => x.sleeve_id == id);
if (sleeve == null)
{
sleeve = Get(3000011L);
}
if (!sleeve.IsEnableInCurrentLanguage)
{
sleeve = Get(3000011L);
}
return sleeve;
}
public string GetResourcePath(long id)
{
return Get(id).sleeve_path;
}
public void Acquired(long id)
{
Get(id).Acquired();
}
public void UnsetNew(long id)
{
Get(id).UnsetNew();
}
public void SetNew(long id)
{
Get(id).SetNew();
}
public void SetFavorite(long id, bool b)
{
Get(id).SetFavorite(b);
}
}