コード例 #1
0
        public static void UnloadProps()
        {
            PropsRenderer.StopPropsUpdate();

            if (AllPropsTypes != null && AllPropsTypes.Count > 0)
            {
                for (int i = 0; i < AllPropsTypes.Count; i++)
                {
                    foreach (Prop PropInstance in AllPropsTypes[i].PropsInstances)
                    {
                        Destroy(PropInstance.Obj.gameObject);
                    }
                }
            }

            AllPropsTypes = new List <PropTypeGroup>();
            if (Current)
            {
                TotalMassCount   = 0;
                TotalEnergyCount = 0;
                TotalReclaimTime = 0;
            }
        }
コード例 #2
0
 private void Awake()
 {
     Current = this;
 }