69 TrafficLight->SetController(
this);
107 Light->SetLightState(NewState);
111 Light->SetTrafficLightState(NewState);
166 if(LightState.State == State)
168 LightState.Time = NewTime;
177 if(LightState.State == State)
179 return LightState.Time;
void SetRedTime(float NewTime)
bool AdvanceTimeAndCycleFinished(float DeltaTime)
float GetStateTime(const ETrafficLightState State) const
void EmptyTrafficLights()
void SetElapsedTime(float InElapsedTime)
TArray< FTrafficLightStage > LightStates
void SetControllerId(const FString &Id)
const FString & GetControllerId() const
void SetGroup(ATrafficLightGroup *Group)
Class which implements the state changing of traffic lights.
void SetTrafficLightsState(ETrafficLightState NewState)
Defines a stage of a semaphor with a State and the time this state lasts.
TArray< UTrafficLightComponent * > TrafficLights
void RemoveTrafficLight(UTrafficLightComponent *TrafficLight)
void SetGreenTime(float NewTime)
float GetYellowTime() const
const FTrafficLightStage & GetCurrentState() const
void RemoveCarlaActorTrafficLight(FCarlaActor *CarlaActor)
TArray< FCarlaActor * > TrafficLightCarlaActors
void SetCurrentLightState(ETrafficLightState NewState)
float GetElapsedTime() const
void SetStates(TArray< FTrafficLightStage > States)
void SetSequence(int InSequence)
bool IsCycleFinished() const
void AddCarlaActorTrafficLight(FCarlaActor *CarlaActor)
const TArray< UTrafficLightComponent * > & GetTrafficLights()
float GetGreenTime() const
void SetStateTime(const ETrafficLightState State, float NewTime)
ATrafficLightGroup * TrafficLightGroup
UTrafficLightController()
ATrafficLightGroup * GetGroup()
void SetYellowTime(float NewTime)
void AddTrafficLight(UTrafficLightComponent *TrafficLight)
A view over an actor and its properties.