![]() |
DeskSim v2 0.1
Train simulator prototype created for Lokførerskolen
|
The status trigger box is used to send status updates to the controller. More...
#include <TrainStatusTriggerBox.h>
Public Member Functions | |
ATrainStatusTriggerBox () | |
Sets default values. | |
void | Tick (float DeltaTime) override |
Called every frame. More... | |
void | OnOverlapBegin (class AActor *OverlappedActor, class AActor *OtherActor) override |
Runs when overlapping begins. More... | |
void | OnOverlapEnd (class AActor *OverlappedActor, class AActor *OtherActor) override |
Runs when overlapping ends. More... | |
void | SendStatusToController () |
Sends the emergency status to the controller. | |
void | EmergencyIf (bool bEqual) |
Sends emergency stop to the train if signal status match or not. More... | |
void | EmergencyIfNot () |
Sends emergency stop to the train if signal status does not match. | |
![]() | |
ATrainTriggerBox () | |
Sets default values. | |
virtual void | Tick (float DeltaTime) |
Called every frame. More... | |
virtual void | OnOverlapBegin (class AActor *OverlappedActor, class AActor *OtherActor) |
Runs when overlapping begins. More... | |
virtual void | OnOverlapEnd (class AActor *OverlappedActor, class AActor *OtherActor) |
Runs when overlapping ends. More... | |
Public Attributes | |
ETriggerStatusType | StatusTrigger |
Which trigger type to use for this box. | |
ESignalStatus | SignalCompare |
The signal status to compare against. | |
![]() | |
TSubclassOf< ACentralSignalController > | CentralControllerClass |
Contains the class of the controller. | |
ACentralSignalController * | CentralController |
Reference to the controller. | |
ATrain * | Train |
Reference to the overlapping train. | |
ESignalType | SignalType |
FName | SignalID |
Protected Member Functions | |
void | BeginPlay () override |
Called when the game starts or when spawned. More... | |
void | EndPlay (EEndPlayReason::Type EndPlayReason) override |
Called when game stops or when despawned. More... | |
virtual void | BeginPlay () |
Called when the game starts or when spawned. More... | |
virtual void | EndPlay (EEndPlayReason::Type EndPlayReason) |
Called when game stops or when despawned. More... | |
The status trigger box is used to send status updates to the controller.
Currently the only status which is sent is emergency stop. The status is sent after a certain condition, such as entering the zone and a signal is of a certain signal status.
|
overrideprotectedvirtual |
Called when the game starts or when spawned.
Reimplemented from ATrainTriggerBox.
void ATrainStatusTriggerBox::EmergencyIf | ( | bool | bEqual | ) |
Sends emergency stop to the train if signal status match or not.
bEqual | - Used to switch between == and != |
|
overrideprotectedvirtual |
Called when game stops or when despawned.
Reimplemented from ATrainTriggerBox.
|
overridevirtual |
Runs when overlapping begins.
Reimplemented from ATrainTriggerBox.
|
overridevirtual |
Runs when overlapping ends.
Reimplemented from ATrainTriggerBox.
|
overridevirtual |
Called every frame.
Reimplemented from ATrainTriggerBox.