public override void OnCreatedComponent(IComponent component) { if (components.Add(component.gameObject, out var zone, out var trigger)) { enterEvents[trigger.onEnter] = other => OnZoneTriggerEnter(zone, other); exitEvents[trigger.onExit] = other => OnZoneTriggerExit(zone, other); } }
public override void OnCreatedComponent(IComponent component) { components.Add(component.gameObject); }