public void TriggerAction(PlayerEvent ev, string actionName) { Debug.Log ("Trigger action " + actionName + " for event " + ev.Content); if (ev.type == PlayerEvent.Type.Equipment) { var equipmentActionProcessor = new EquipmentActionProcessor(sim); equipmentActionProcessor.HandleAction(ev, actionName); } if (ev.type == PlayerEvent.Type.Consumable) { var consumableActionProcessor = new ConsumableActionProcessor(sim); consumableActionProcessor.HandleAction(ev, actionName); } NotificationCenter.PostNotification(Constants.OnUpdateEvents); }
public void TriggerAction(PlayerEvent ev, string actionName) { Debug.Log("Trigger action " + actionName + " for event " + ev.Content); if (ev.type == PlayerEvent.Type.Equipment) { var equipmentActionProcessor = new EquipmentActionProcessor(sim); equipmentActionProcessor.HandleAction(ev, actionName); } if (ev.type == PlayerEvent.Type.Consumable) { var consumableActionProcessor = new ConsumableActionProcessor(sim); consumableActionProcessor.HandleAction(ev, actionName); } NotificationCenter.PostNotification(Constants.OnUpdateEvents); }