Skip to content

Commit

Permalink
Implement/match LegoPathActor::UpdatePlane (#1133)
Browse files Browse the repository at this point in the history
  • Loading branch information
foxtacles authored Nov 3, 2024
1 parent d8412a4 commit 1badade
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
4 changes: 4 additions & 0 deletions LEGO1/lego/legoomni/include/legonamedplane.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,10 @@ class LegoNamedPlane {
void SetName(const char* p_name) { m_name = p_name; }
const MxString* GetName() const { return &m_name; }

void SetPosition(const Mx3DPointFloat& p_position) { m_position = p_position; }
void SetDirection(const Mx3DPointFloat& p_direction) { m_direction = p_direction; }
void SetUp(const Mx3DPointFloat& p_up) { m_up = p_up; }

// FUNCTION: LEGO1 0x100344d0
MxResult Serialize(LegoFile* p_file)
{
Expand Down
8 changes: 6 additions & 2 deletions LEGO1/lego/legoomni/src/paths/legopathactor.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
#include "geom/legounkown100db7f4.h"
#include "legocachesoundmanager.h"
#include "legocameracontroller.h"
#include "legonamedplane.h"
#include "legonavcontroller.h"
#include "legopathboundary.h"
#include "legopathedgecontainer.h"
Expand Down Expand Up @@ -719,8 +720,11 @@ void LegoPathActor::VTable0xa8()
}
}

// STUB: LEGO1 0x1002f770
// FUNCTION: LEGO1 0x1002f770
void LegoPathActor::UpdatePlane(LegoNamedPlane& p_namedPlane)
{
// TODO
p_namedPlane.SetName(m_boundary->GetName());
p_namedPlane.SetPosition(GetWorldPosition());
p_namedPlane.SetDirection(GetWorldDirection());
p_namedPlane.SetUp(GetWorldUp());
}
2 changes: 1 addition & 1 deletion LEGO1/lego/sources/geom/legowegedge.h
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ class LegoWEGEdge : public LegoWEEdge {
Mx4DPointFloat* GetEdgeNormal(int index) { return &m_edgeNormals[index]; }

// FUNCTION: BETA10 0x1001c9b0
LegoChar* GetName() { return m_name; }
const LegoChar* GetName() { return m_name; }

void SetFlag0x10(LegoU32 p_disable)
{
Expand Down

0 comments on commit 1badade

Please sign in to comment.