mirror of
https://github.com/Squareville/TestEventServer.git
synced 2026-01-07 09:00:09 -06:00
Public release of the DLU server code!
Have fun!
This commit is contained in:
16
dScripts/AgStagePlatforms.cpp
Normal file
16
dScripts/AgStagePlatforms.cpp
Normal file
@@ -0,0 +1,16 @@
|
||||
#include "AgStagePlatforms.h"
|
||||
#include "MovingPlatformComponent.h"
|
||||
|
||||
void AgStagePlatforms::OnStartup(Entity *self) {
|
||||
auto* component = self->GetComponent<MovingPlatformComponent>();
|
||||
if (component) {
|
||||
component->SetNoAutoStart(true);
|
||||
component->StopPathing();
|
||||
}
|
||||
}
|
||||
|
||||
void AgStagePlatforms::OnWaypointReached(Entity* self, uint32_t waypointIndex) {
|
||||
auto* component = self->GetComponent<MovingPlatformComponent>();
|
||||
if (waypointIndex == 0 && component)
|
||||
component->StopPathing();
|
||||
}
|
||||
Reference in New Issue
Block a user