public virtual void Start() { if (IsPhysicsEnabled) { RecreatePhysics(); } Input.RegisterListener(OnInputEvent); int count = m_components.Count; for (int i = 0; i < count; i++) { m_components[i].Start(); } if (UpdateScriptEvent.HasHandlers()) { m_updateScope = World.UpdateScheduler.Connect(Update, EUpdatePriority.Default); } StartScriptEvent.Invoke(); }
public void Update(float deltaTime) { UpdateScriptEvent.Invoke(deltaTime, this); }