using System; using System.Collections; using System.Collections.Generic; using Ichni.RhythmGame.Beatmap; using Lean.Pool; using UnityEngine; namespace Ichni.RhythmGame { public partial class EnvironmentObject : SubstantialObject { public bool isStatic; public static EnvironmentObject GenerateElement(string elementName, Guid id, List tags, bool isFirstGenerated, string themeBundleName, string objectName, GameElement parentElement, bool isStatic) { EnvironmentObject environmentObject = SubstantialObject.GenerateElement(elementName, id, tags, isFirstGenerated, themeBundleName, objectName, parentElement) .GetComponent(); environmentObject.isStatic = isStatic; environmentObject.gameObject.isStatic = isStatic; return environmentObject; } } public partial class EnvironmentObject { public override void SaveBM() { matchedBM = new EnvironmentObject_BM(elementName, elementGuid, tags, parentElement.matchedBM as GameElement_BM, themeBundleName, objectName, isStatic); } } namespace Beatmap { public class EnvironmentObject_BM : SubstantialObject_BM { public bool isStatic; public EnvironmentObject_BM() { } public EnvironmentObject_BM(string elementName, Guid elementGuid, List tags, GameElement_BM attachedElement, string themeBundleName, string objectName, bool isStatic) : base(elementName, elementGuid, tags, attachedElement, themeBundleName, objectName) { this.isStatic = isStatic; } public override void ExecuteBM() { matchedElement = EnvironmentObject.GenerateElement(elementName, elementGuid, tags, false, themeBundleName, objectName, GetElement(attachedElementGuid), isStatic); } } } }