/// <summary> /// Normal constructor. Should not be called directly, but rather the SceneManager.CreateLight method should be used. /// </summary> /// <param name="name"></param> public TextureLight(string name, BspSceneManager creator) : base(name) { this.creator = creator; isTextureLight = true; diffuse = ColorEx.White; textureColor = ColorEx.White; intensity = LightIntensity.Normal; priority = 100; }
public void TestChildSceneNodeRemoval() { SceneManager sceneManager = new BspSceneManager( "Manager under test" ); SceneNode node = sceneManager.CreateSceneNode( "testNode" ); SceneNode childNode = node.CreateChildSceneNode( "childNode" ); Assert.IsTrue( ManagerContainsNode( sceneManager, childNode ), "A child node was created but not added to the scene graph." ); node.RemoveChild( childNode.Name ); Assert.IsTrue( ManagerContainsNode( sceneManager, childNode ), "A child node was removed from its parent but also incorrectly removed from the scene graph." ); }
public void TestChildSceneNodeDestruction() { SceneManager sceneManager = new BspSceneManager( "Manager under test" ); SceneNode node = sceneManager.CreateSceneNode( "testNode" ); SceneNode childNode = node.CreateChildSceneNode( "childNode" ); Assert.IsTrue( ManagerContainsNode( sceneManager, childNode ), "A child node was created but not added to the scene graph." ); node.RemoveAndDestroyChild( childNode.Name ); Assert.IsFalse( ManagerContainsNode( sceneManager, childNode ), "A child node was destroryed but not removed from the scene graph." ); }
/// <summary> /// Default constructor. /// </summary> public TextureLight( BspSceneManager creator ) : this( "", creator ) { }