Beispiel #1
0
        // Initialization
        public void Awake()
        {
            managerState = "waking up";
            m_radius     = (float)parentCelestialBody.Radius;
            //			print (m_radius);

            m_sunNode = new SunNode();
            m_sunNode.Start();

            m_skyNode = new SkyNode();
            m_skyNode.setManager(this);
            m_skyNode.SetParentCelestialBody(parentCelestialBody);
            m_skyNode.setParentPlanetTransform(ParentPlanetTransform);
            //			print ("skynode parent CB and PP set");
            //m_skyNode.loadSettings ();
            m_skyNode.loadFromConfigNode(false);
            m_skyNode.Start();
            //m_skyNode.loadFromConfigNode(false);
            //m_skyNode.loadFromConfigNode ();
            //			print ("skynode started");

            if (hasOcean)
            {
                m_oceanNode = new OceanWhiteCaps();
                m_oceanNode.setManager(this);
                m_oceanNode.setCore(m_core);

                m_oceanNode.loadFromConfigNode(false);
                m_oceanNode.Start();
            }

            managerState = "awake";
        }
Beispiel #2
0
        // Initialization
        public void Awake()
        {
            m_radius = parentCelestialBody.Radius;
            //			print (m_radius);

            m_sunNode = new SunNode();
            m_sunNode.Start();

            m_skyNode = new SkyNode();
            m_skyNode.setManager(this);
            m_skyNode.SetParentCelestialBody(parentCelestialBody);
            m_skyNode.setParentPlanetTransform(ParentPlanetTransform);
            //			print ("skynode parent CB and PP set");
            //m_skyNode.loadSettings ();
            m_skyNode.loadFromConfigNode(false);

            m_skyNode.Start();

            //m_skyNode.loadFromConfigNode(false);
            //m_skyNode.loadFromConfigNode ();
            //			print ("skynode started");

            if (hasOcean && Core.Instance.useOceanShaders)
            {
                m_oceanNode = new OceanWhiteCaps();
                m_oceanNode.setManager(this);
                m_oceanNode.setCore(Core.Instance);

                m_oceanNode.loadFromConfigNode(false);
                m_oceanNode.Start();
            }
        }
Beispiel #3
0
		// Initialization
		public void Awake() {
			managerState = "waking up";
			m_radius = (float) parentCelestialBody.Radius;
			//			print (m_radius);
			
			m_sunNode = new SunNode();
			m_sunNode.Start();
			
			m_skyNode = new SkyNode();
			m_skyNode.setManager(this);
			m_skyNode.SetParentCelestialBody(parentCelestialBody);
			m_skyNode.setParentPlanetTransform(ParentPlanetTransform);
			//			print ("skynode parent CB and PP set");
			//m_skyNode.loadSettings ();
			m_skyNode.loadFromConfigNode(false);
			m_skyNode.Start();
			//m_skyNode.loadFromConfigNode(false);
			//m_skyNode.loadFromConfigNode ();
			//			print ("skynode started");
			
			if (hasOcean) {
				m_oceanNode = new OceanWhiteCaps();
				m_oceanNode.setManager(this);
				m_oceanNode.setCore(m_core);

				m_oceanNode.loadFromConfigNode(false);
				m_oceanNode.Start();

			}
			
			managerState = "awake";
		}
Beispiel #4
0
 //this fixes the alt-enter bug the really stupid way but it'll do for now
 public void reBuildOcean()
 {
     if (hasOcean)
     {
         UnityEngine.Object.Destroy(m_oceanNode);
         m_oceanNode = new OceanWhiteCaps();
         m_oceanNode.setManager(this);
         m_oceanNode.setCore(m_core);
         m_oceanNode.loadFromConfigNode(false);
         m_oceanNode.Start();
         Debug.Log("[Scatterer] Rebuilt Ocean");
     }
 }
Beispiel #5
0
 //this fixes the alt-enter bug the really stupid way but it's fast so it'll do for now
 public void reBuildOcean()
 {
     if (hasOcean && Core.Instance.useOceanShaders)
     {
         m_oceanNode.OnDestroy();
         UnityEngine.Object.Destroy(m_oceanNode);
         m_oceanNode = new OceanWhiteCaps();
         m_oceanNode.setManager(this);
         m_oceanNode.setCore(Core.Instance);
         m_oceanNode.loadFromConfigNode(false);
         m_oceanNode.Start();
         Debug.Log("[Scatterer] Rebuilt Ocean");
     }
 }
Beispiel #6
0
		//this fixes the alt-enter bug the really stupid way but it'll do for now
		public void reBuildOcean() {
			if (hasOcean) {
				UnityEngine.Object.Destroy(m_oceanNode);
				m_oceanNode = new OceanWhiteCaps();
				m_oceanNode.setManager(this);
				m_oceanNode.setCore(m_core);
				m_oceanNode.loadFromConfigNode(false);
				m_oceanNode.Start();
				Debug.Log("[Scatterer] Rebuilt Ocean");
			}
			
		}