90 lines
3.2 KiB
C#
90 lines
3.2 KiB
C#
using System.Collections;
|
|
using System.Collections.Generic;
|
|
using Ichni.RhythmGame.Beatmap;
|
|
using UnityEngine;
|
|
|
|
namespace Ichni.RhythmGame
|
|
{
|
|
public class ProjectInformation : IBaseElement
|
|
{
|
|
public string projectName;
|
|
public string creatorName;
|
|
public string editorVersion;
|
|
public string createTime;
|
|
public string lastSaveTime;
|
|
public List<string> selectedThemeBundleList;
|
|
|
|
public string projectPath;
|
|
public BaseElement_BM matchedBM { get; set; }
|
|
|
|
public string peojectInfoPath => projectPath + "/ProjectInfo.json";
|
|
public string songInfoPath => projectPath + "/SongInfo.json";
|
|
public string songPath => projectPath + EditorManager.instance.songInformation.songName + ".wav";
|
|
public string beatmapPath => projectPath + "/Beatmap.json";
|
|
public string CommandScriptsPath => projectPath + "/CommandScripts.json";
|
|
|
|
public ProjectInformation(string projectName, string creatorName, string editorVersion,
|
|
string createTime, string lastSaveTime, List<string> selectedThemeBundleList)
|
|
{
|
|
this.projectName = projectName;
|
|
this.creatorName = creatorName;
|
|
this.editorVersion = editorVersion;
|
|
this.createTime = createTime;
|
|
this.lastSaveTime = lastSaveTime;
|
|
this.selectedThemeBundleList = selectedThemeBundleList;
|
|
|
|
projectPath = Application.streamingAssetsPath + "/Projects/" + projectName;
|
|
}
|
|
|
|
public void SaveBM()
|
|
{
|
|
matchedBM = new ProjectInformation_BM(projectName, creatorName, editorVersion,
|
|
createTime, lastSaveTime, selectedThemeBundleList);
|
|
}
|
|
|
|
public void SetUpInspector()
|
|
{
|
|
throw new System.NotImplementedException();
|
|
}
|
|
|
|
public void Refresh()
|
|
{
|
|
throw new System.NotImplementedException();
|
|
}
|
|
}
|
|
|
|
namespace Beatmap
|
|
{
|
|
public class ProjectInformation_BM : BaseElement_BM
|
|
{
|
|
public string projectName;
|
|
public string creatorName;
|
|
public string editorVersion;
|
|
public string createTime;
|
|
public string lastSaveTime;
|
|
public List<string> selectedThemeBundleList;
|
|
|
|
public ProjectInformation_BM()
|
|
{
|
|
|
|
}
|
|
|
|
public ProjectInformation_BM(string projectName, string creatorName, string editorVersion,
|
|
string createTime, string lastSaveTime, List<string> selectedThemeBundleList)
|
|
{
|
|
this.projectName = projectName;
|
|
this.creatorName = creatorName;
|
|
this.editorVersion = editorVersion;
|
|
this.createTime = createTime;
|
|
this.lastSaveTime = lastSaveTime;
|
|
this.selectedThemeBundleList = selectedThemeBundleList;
|
|
}
|
|
|
|
public override void ExecuteBM()
|
|
{
|
|
EditorManager.instance.projectInformation = new ProjectInformation(projectName,
|
|
creatorName, editorVersion, createTime, lastSaveTime, selectedThemeBundleList);
|
|
}
|
|
}
|
|
}
|
|
} |