private void Start() { // initialize all of the property trackers, and add them to the array. m_CurrentSkybox = new SkyboxProperties(); m_CurrentHaze = new HazeProperties(); m_CurrentBasicFog = new BasicFogProperties(); m_CurrentFillLight = new BasicLightProperties( lightKit.Find("Fill light") ); m_CurrentBackLight = new BasicLightProperties( lightKit.Find("Bounce light") ); m_CurrentKeyLight = new KeyLightProperties( lightKit.Find("Directional light") ); m_CurrentAmbientLight = new AmbientLightProperties(); m_CurrentLightKit = GameObject.Find ("MainLightKit").transform; m_AtmosphereProperties = new AtmosphereProperties[]{ m_CurrentSkybox, m_CurrentHaze, m_CurrentBasicFog, m_CurrentFillLight, m_CurrentBackLight, m_CurrentKeyLight, m_CurrentAmbientLight }; // initialize the texture list. loadedSkyboxes = new Dictionary<string, Dictionary<string, Texture2D>>(); // setup the default atmosphere configuration. SetupDefaultConfiguration(); // register for events. // EventHandler.instance.addEventListener( ComplexEventObj.ChangeGridArea, this.gameObject, "OnChangeGridArea" ); // EventHandler.instance.addEventListener( BasicEventObj.ToggleThemeRenderSettings, this.gameObject, "OnToggleThemeRenderSettings" ); // set the default state to 'on'. m_CurrentSubState = SubState.Init; this.ChangeState( SubState.On ); // this process will trigger all "hasChanged" flags to be set to true. }
private void Start(){ // initialize all of the property trackers, and add them to the array. m_CurrentSkybox = new SkyboxProperties(); m_CurrentHaze = new HazeProperties(); m_CurrentBasicFog = new BasicFogProperties(); m_AtmosphereProperties = new AtmosphereProperties[]{ m_CurrentSkybox, m_CurrentHaze, m_CurrentBasicFog}; // initialize the texture list. loadedSkyboxes = new Dictionary<string, Dictionary<string, Texture2D>>(); // setup the default atmosphere configuration. SetupDefaultConfiguration(); // set the default state to 'on'. m_CurrentSubState = SubState.Init; this.ChangeState( SubState.On ); // this process will trigger all "hasChanged" flags to be set to true. }