示例#1
0
 public void RegisterComponent(Component component)
 {
     Contract.Requires <ArgumentNullException>(component != null, "component");
     key |= component.KeyPart;
     component.AssignToScene(scene);
     scene.EntityMap.AddComponentToEntity(component, this);
 }
示例#2
0
 public void UnregisterComponent(Component component)
 {
     key &= ~component.KeyPart;
     scene.EntityMap.RemoveComponentFromEntity(component, this);
 }