Beispiel #1
0
 public void GameObject_RemoveComponent()
 {
     Magnata.Gameobject           go = new Magnata.Gameobject();
     Magnata.Components.Component c  = new Magnata.Components.Transform(go, new Magnata.Other.Vector(0, 0));
     go.AddComponent(c);
     go.RemoveComponent(c);
     Assert.IsNull(go.GetComponent <Magnata.Components.Transform>());
 }
Beispiel #2
0
        public void GameObject_Removed()
        {
            Magnata.Gameobject go = new Magnata.Gameobject();
            TestComponent      tc = new TestComponent(go);

            go.AddComponent(tc);
            go.RemoveComponent(tc);
            Assert.IsTrue(tc.Removed);
        }