Esempio n. 1
0
            private void DestroyRenderTexture()
            {
                if (renderTargetListener != null)
                {
                    renderTexture.RemoveListener(renderTargetListener);
                    renderTargetListener.Dispose();
                    renderTargetListener = null;
                }

                if (viewport != null)
                {
                    viewport.Dispose();
                    viewport = null;
                }

                if (camera != null)
                {
                    camera.Dispose();
                    camera = null;
                }

                renderTexture = null;

                if (texture != null)
                {
                    texture.Dispose();
                    texture = null;
                }
            }
Esempio n. 2
0
 protected override void OnDetach()
 {
     //base.OnDetach(); //fix akunitbuy and akcustomize INCIN
     if (spawner.Spawned != null)
     {
         spawner.Spawned.SetForDeletion(false);
         spawner.Spawned = null;
     }
     if (rmCamera != null)
     {
         rmCamera.Dispose();
         rmCamera = null;
     }
 }
Esempio n. 3
0
        protected override void OnDetach()
        {
            //base.OnDetach();

            if (spawner.Spawned != null)
            {
                spawner.Spawned.SetForDeletion(false);
                spawner.Spawned = null;
            }
            if (rmCamera != null)
            {
                rmCamera.Dispose();
                rmCamera = null;
            }
        }