public PerceptionEvent(PERCEPTION_EVENT_TYPE _type, float _time_in_memory) { type = _type; time_in_memory = _time_in_memory; counter_in_memory = 0.0f; is_finished = false; start_counting = true; }
public void TriggerHearEvent(PERCEPTION_EVENT_TYPE type, float time_in_memory, int radius, int origin_tile_x, int origin_tile_y, int destiny_x, int destiny_y) { PerceptionHearEvent new_event = new PerceptionHearEvent(type, time_in_memory, radius); new_event.SetOrigin(origin_tile_x, origin_tile_y); new_event.SetDestiny(destiny_x, destiny_y); event_manager.GetComponent <PerceptionManager>().GenEvent(new_event); }
public PerceptionEvent(PerceptionEvent e) { type = e.type; time_in_memory = e.time_in_memory; objective_tile_x = e.objective_tile_x; objective_tile_y = e.objective_tile_y; origin_tile_y = e.origin_tile_y; origin_tile_x = e.origin_tile_x; counter_in_memory = 0.0f; start_counting = true; is_finished = false; }
public PerceptionEvent GetEvent(PERCEPTION_EVENT_TYPE type) { foreach (PerceptionEvent memory_event in events_in_memory) { if (memory_event.type == type) { return(memory_event); } } return(null); }
public PerceptionHearEvent(PERCEPTION_EVENT_TYPE _type, float _time_in_memory, int _radius) : base(_type, _time_in_memory) { radius_in_tiles = _radius; }