Beispiel #1
0
        public void Act()
        {
            if (AI == null)
            {
                // TODO: This might be worth logging a warning about
                return;
            }
            IAction <PhysicalActor>?action = AI.NextAction();

            if (action == null)
            {
                throw new Exception($"An AI terminated ");
            }
            IEvent actionEvent = new ActionEvent <PhysicalActor>(action: action, actor: this);

            ScheduledEvent = actionEvent;
            Schedule.Add(actionEvent, action.OnsetTime);
        }