(client) chore: Rearrange script structures

This commit is contained in:
2025-07-12 21:35:58 +08:00
parent 31a63b1c8c
commit e95e3527d0
7 changed files with 115 additions and 148 deletions

View File

@ -0,0 +1,26 @@
using System.Collections.Generic;
using System.IO;
using Data;
using Utils;
namespace Managers
{
public class DefineManager : Singleton<DefineManager>
{
private const string coreNamespace = "Data";
private static readonly string[] dataSetFilePath = { "Data", "Mod" };
public Dictionary<string, Dictionary<string, Define>> defines = new();
public Dictionary<string, DefinePack> packs = new();
public void Init()
{
var packFolder = Directory.GetDirectories(dataSetFilePath[0]);
foreach (var folder in packFolder)
{
var pack = new DefinePack();
if (pack.LoadPack(folder)) packs.Add(pack.packID, pack);
}
}
}
}

View File

@ -0,0 +1,3 @@
fileFormatVersion: 2
guid: b521fe6d2648423e818beda6d4a3c007
timeCreated: 1752148078