2022-01-28 20:49:07 -08:00
|
|
|
|
using Cysharp.Threading.Tasks;
|
|
|
|
|
using QSB.JellyfishSync.WorldObjects;
|
2022-01-25 02:13:48 -08:00
|
|
|
|
using QSB.Utility;
|
2021-12-02 15:03:38 +00:00
|
|
|
|
using QSB.WorldSync;
|
2021-12-23 17:07:29 -08:00
|
|
|
|
using System.Collections.Generic;
|
2022-01-28 20:49:07 -08:00
|
|
|
|
using System.Threading;
|
2021-12-02 15:03:38 +00:00
|
|
|
|
|
2022-03-02 19:46:33 -08:00
|
|
|
|
namespace QSB.JellyfishSync;
|
|
|
|
|
|
|
|
|
|
public class JellyfishManager : WorldObjectManager
|
2021-12-02 15:03:38 +00:00
|
|
|
|
{
|
2022-03-02 19:46:33 -08:00
|
|
|
|
public override WorldObjectScene WorldObjectScene => WorldObjectScene.SolarSystem;
|
2021-12-20 18:41:12 -08:00
|
|
|
|
|
2022-03-02 19:46:33 -08:00
|
|
|
|
public static readonly List<JellyfishController> Jellyfish = new();
|
2021-12-13 23:37:21 -08:00
|
|
|
|
|
2022-03-02 19:46:33 -08:00
|
|
|
|
public override async UniTask BuildWorldObjects(OWScene scene, CancellationToken ct)
|
|
|
|
|
{
|
|
|
|
|
Jellyfish.Clear();
|
|
|
|
|
Jellyfish.AddRange(QSBWorldSync.GetUnityObjects<JellyfishController>().SortDeterministic());
|
|
|
|
|
QSBWorldSync.Init<QSBJellyfish, JellyfishController>(Jellyfish);
|
2021-12-02 15:03:38 +00:00
|
|
|
|
}
|
2022-02-24 22:04:54 -08:00
|
|
|
|
}
|