/*-------------------------------------- * PUBLIC METHODS *------------------------------------*/ /// <summary>Adds a component to the entity.</summary> /// <param name="component">The component to add to the entity.</param> public void AddComponent(EcsComponent component) { mComponents.Add(component.GetType(), component); var scene = mScene; if (scene != null) { scene.NotifyComponentsChanged(this); } }
public void AddComponent(EcsComponent component) { mComponents.Add(component.GetType(), component); }