mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2024-11-22 13:37:22 +00:00
quick notes
This commit is contained in:
parent
43657324e9
commit
4336cb7f50
@ -123,6 +123,8 @@ void SimpleMoverPlatformSubComponent::LoadDataFromTemplate() {
|
||||
|
||||
NiPoint3 platformMove = platformEntry->platformMove;
|
||||
float moveTime = platformEntry->moveTime;
|
||||
m_PlatformMove = platformMove;
|
||||
m_MoveTime = moveTime;
|
||||
}
|
||||
|
||||
SimpleMoverPlatformSubComponent::SimpleMoverPlatformSubComponent(MovingPlatformComponent* parentComponent, const NiPoint3& platformMove, const bool startsInReverse) : PlatformSubComponent(parentComponent) {
|
||||
@ -143,6 +145,10 @@ MovingPlatformComponent::MovingPlatformComponent(Entity* parent, const std::stri
|
||||
|
||||
}
|
||||
|
||||
void MovingPlatformComponent::LoadDataFromTemplate() {
|
||||
std::for_each(m_Platforms.begin(), m_Platforms.end(), [](const std::unique_ptr<PlatformSubComponent>& platform) { platform->LoadDataFromTemplate(); });
|
||||
}
|
||||
|
||||
void MovingPlatformComponent::LoadConfigData() {
|
||||
if (m_Parent->GetVar<bool>(u"platformIsSimpleMover")) {
|
||||
AddMovingPlatform<SimpleMoverPlatformSubComponent>(NiPoint3::ZERO, false);
|
||||
@ -212,6 +218,7 @@ void MovingPlatformComponent::GotoWaypoint(uint32_t index, bool stopAtWaypoint)
|
||||
}
|
||||
|
||||
void MovingPlatformComponent::StartPathing() {
|
||||
// state == Travelling
|
||||
// //GameMessages::SendStartPathing(m_Parent);
|
||||
// m_PathingStopped = false;
|
||||
|
||||
@ -263,6 +270,7 @@ void MovingPlatformComponent::StartPathing() {
|
||||
}
|
||||
|
||||
void MovingPlatformComponent::ContinuePathing() {
|
||||
// state == Travelling
|
||||
// auto* subComponent = static_cast<MoverSubComponent*>(m_MoverSubComponent);
|
||||
|
||||
// subComponent->mState = eMovementPlatformState::Stationary;
|
||||
@ -373,6 +381,7 @@ void MovingPlatformComponent::ContinuePathing() {
|
||||
}
|
||||
|
||||
void MovingPlatformComponent::StopPathing() {
|
||||
// state == Stopped
|
||||
//m_Parent->CancelCallbackTimers();
|
||||
|
||||
// auto* subComponent = static_cast<MoverSubComponent*>(m_MoverSubComponent);
|
||||
@ -388,10 +397,6 @@ void MovingPlatformComponent::StopPathing() {
|
||||
//GameMessages::SendPlatformResync(m_Parent, UNASSIGNED_SYSTEM_ADDRESS);
|
||||
}
|
||||
|
||||
void MovingPlatformComponent::SetSerialized(bool value) {
|
||||
// m_Serialize = value;
|
||||
}
|
||||
|
||||
bool MovingPlatformComponent::GetNoAutoStart() const {
|
||||
return false;
|
||||
// return m_NoAutoStart;
|
||||
|
@ -37,6 +37,8 @@ public:
|
||||
virtual void Serialize(RakNet::BitStream* outBitStream, bool bIsInitialUpdate);
|
||||
virtual eMoverSubComponentType GetPlatformType() { return eMoverSubComponentType::None; };
|
||||
bool GetIsDirty() const { return m_IsDirty; }
|
||||
virtual void LoadDataFromTemplate() {};
|
||||
virtual void LoadConfigData() {};
|
||||
protected:
|
||||
|
||||
#ifdef _MOVING_PLATFORM_TEST
|
||||
@ -85,8 +87,8 @@ public:
|
||||
SimpleMoverPlatformSubComponent(MovingPlatformComponent* parentComponent, const NiPoint3& platformMove, const bool startAtEnd);
|
||||
~SimpleMoverPlatformSubComponent() override = default;
|
||||
eMoverSubComponentType GetPlatformType() override { return eMoverSubComponentType::SimpleMover; }
|
||||
void LoadConfigData();
|
||||
void LoadDataFromTemplate();
|
||||
void LoadConfigData() override;
|
||||
void LoadDataFromTemplate() override;
|
||||
void Serialize(RakNet::BitStream* outBitStream, bool bIsInitialUpdate) override;
|
||||
bool m_HasStartingPoint = false;
|
||||
bool m_DirtyStartingPoint = false;
|
||||
@ -110,6 +112,7 @@ public:
|
||||
|
||||
MovingPlatformComponent(Entity* parent, const std::string& pathName);
|
||||
|
||||
void LoadDataFromTemplate();
|
||||
void LoadConfigData();
|
||||
|
||||
void Serialize(RakNet::BitStream* outBitStream, bool bIsInitialUpdate, unsigned int& flags);
|
||||
|
Loading…
Reference in New Issue
Block a user