mirror of
https://github.com/isledecomp/isle.git
synced 2025-10-26 09:54:18 +00:00
Refactor files based on beta debug build (#645)
* Rename LegoUnkSaveDataWriter -> LegoCharacterManager * Refactor mxomni into mxomni/mxmisc * Refactor legoomni into legoomni/misc * Resolve deps * Refactor atom * Refactor mxutil * Refactor mxio * Rename/relocate files * Fix format
This commit is contained in:
committed by
GitHub
parent
c62469fef4
commit
8069923651
81
LEGO1/lego/legoomni/src/actors/ambulance.cpp
Normal file
81
LEGO1/lego/legoomni/src/actors/ambulance.cpp
Normal file
@@ -0,0 +1,81 @@
|
||||
#include "ambulance.h"
|
||||
|
||||
#include "decomp.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(Ambulance, 0x184);
|
||||
|
||||
// FUNCTION: LEGO1 0x10035ee0
|
||||
Ambulance::Ambulance()
|
||||
{
|
||||
this->m_unk0x168 = 0;
|
||||
this->m_unk0x16a = -1;
|
||||
this->m_unk0x164 = 0;
|
||||
this->m_unk0x16c = 0;
|
||||
this->m_unk0x174 = -1;
|
||||
this->m_unk0x16e = 0;
|
||||
this->m_unk0x178 = -1;
|
||||
this->m_unk0x170 = 0;
|
||||
this->m_unk0x172 = 0;
|
||||
this->m_unk0x13c = 40.0;
|
||||
this->m_unk0x17c = 1.0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10035f90
|
||||
void Ambulance::Destroy(MxBool p_fromDestructor)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100361d0
|
||||
MxResult Ambulance::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10036300
|
||||
void Ambulance::VTable0x70(float p_float)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10036420
|
||||
MxLong Ambulance::Notify(MxParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10036860
|
||||
MxU32 Ambulance::VTable0xdc(MxType19NotificationParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10036ce0
|
||||
MxU32 Ambulance::VTable0xcc()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10036e90
|
||||
void Ambulance::VTable0xe4()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10036f90
|
||||
MxU32 Ambulance::VTable0xd4(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10037160
|
||||
MxResult Ambulance::Tickle()
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
58
LEGO1/lego/legoomni/src/actors/bike.cpp
Normal file
58
LEGO1/lego/legoomni/src/actors/bike.cpp
Normal file
@@ -0,0 +1,58 @@
|
||||
#include "bike.h"
|
||||
|
||||
#include "legocontrolmanager.h"
|
||||
#include "legogamestate.h"
|
||||
#include "legoomni.h"
|
||||
#include "legoutils.h"
|
||||
#include "legoworld.h"
|
||||
#include "misc.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(Bike, 0x164);
|
||||
|
||||
// FUNCTION: LEGO1 0x10076670
|
||||
Bike::Bike()
|
||||
{
|
||||
this->m_unk0x13c = 20.0;
|
||||
this->m_unk0x150 = 3.0;
|
||||
this->m_unk0x148 = 1;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100768f0
|
||||
MxResult Bike::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
MxResult result = IslePathActor::Create(p_dsAction);
|
||||
m_world = CurrentWorld();
|
||||
|
||||
if (m_world) {
|
||||
m_world->Add(this);
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10076920
|
||||
void Bike::VTable0xe4()
|
||||
{
|
||||
IslePathActor::VTable0xe4();
|
||||
GameState()->SetCurrentArea(LegoGameState::Area::e_unk57);
|
||||
FUN_1003ee00(*g_isleScript, 11);
|
||||
FUN_1003ee00(*g_isleScript, 12);
|
||||
FUN_1003ee00(*g_isleScript, 15);
|
||||
FUN_1003ee00(*g_isleScript, 14);
|
||||
FUN_1003ee00(*g_isleScript, 13);
|
||||
ControlManager()->Unregister(this);
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100769a0
|
||||
MxU32 Bike::VTable0xcc()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10076aa0
|
||||
MxU32 Bike::VTable0xd4(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
32
LEGO1/lego/legoomni/src/actors/bumpbouy.cpp
Normal file
32
LEGO1/lego/legoomni/src/actors/bumpbouy.cpp
Normal file
@@ -0,0 +1,32 @@
|
||||
#include "bumpbouy.h"
|
||||
|
||||
// STUB: LEGO1 0x1000fd00
|
||||
void BumpBouy::ParseAction(char*)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1000fd10
|
||||
void BumpBouy::SetWorldSpeed(MxFloat p_worldSpeed)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1000fd20
|
||||
void BumpBouy::VTable0x70(float p_float)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1000fd30
|
||||
void BumpBouy::VTable0x74(Matrix4& p_transform)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100274d0
|
||||
MxLong BumpBouy::Notify(MxParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
20
LEGO1/lego/legoomni/src/actors/doors.cpp
Normal file
20
LEGO1/lego/legoomni/src/actors/doors.cpp
Normal file
@@ -0,0 +1,20 @@
|
||||
#include "doors.h"
|
||||
|
||||
// STUB: LEGO1 0x10066100
|
||||
MxS32 Doors::VTable0x94()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10066250
|
||||
void Doors::VTable0x70(float p_float)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100664e0
|
||||
void Doors::ParseAction(char*)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
52
LEGO1/lego/legoomni/src/actors/dunebuggy.cpp
Normal file
52
LEGO1/lego/legoomni/src/actors/dunebuggy.cpp
Normal file
@@ -0,0 +1,52 @@
|
||||
#include "dunebuggy.h"
|
||||
|
||||
#include "decomp.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(DuneBuggy, 0x16c);
|
||||
|
||||
// FUNCTION: LEGO1 0x10067bb0
|
||||
DuneBuggy::DuneBuggy()
|
||||
{
|
||||
this->m_unk0x13c = 25.0;
|
||||
this->m_unk0x164 = 1.0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10067e30
|
||||
MxResult DuneBuggy::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10067ec0
|
||||
void DuneBuggy::VTable0x70(float p_float)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10067fa0
|
||||
void DuneBuggy::VTable0xe4()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10068060
|
||||
MxU32 DuneBuggy::VTable0xcc()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100681b0
|
||||
MxU32 DuneBuggy::VTable0xd4(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10068270
|
||||
MxU32 DuneBuggy::VTable0xdc(MxType19NotificationParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
416
LEGO1/lego/legoomni/src/actors/helicopter.cpp
Normal file
416
LEGO1/lego/legoomni/src/actors/helicopter.cpp
Normal file
@@ -0,0 +1,416 @@
|
||||
#include "helicopter.h"
|
||||
|
||||
#include "act1state.h"
|
||||
#include "act3.h"
|
||||
#include "isle.h"
|
||||
#include "jukebox.h"
|
||||
#include "legoanimationmanager.h"
|
||||
#include "legocontrolmanager.h"
|
||||
#include "legogamestate.h"
|
||||
#include "legoomni.h"
|
||||
#include "legoutils.h"
|
||||
#include "legoworld.h"
|
||||
#include "misc.h"
|
||||
#include "mxtransitionmanager.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(Helicopter, 0x230)
|
||||
DECOMP_SIZE_ASSERT(Mx3DPointFloat, 0x14)
|
||||
DECOMP_SIZE_ASSERT(Mx4DPointFloat, 0x18)
|
||||
DECOMP_SIZE_ASSERT(MxMatrix, 0x48)
|
||||
|
||||
// FUNCTION: LEGO1 0x10001e60
|
||||
Helicopter::Helicopter()
|
||||
{
|
||||
m_unk0x13c = 60;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10003230
|
||||
Helicopter::~Helicopter()
|
||||
{
|
||||
ControlManager()->Unregister(this);
|
||||
IslePathActor::Destroy(TRUE);
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100032c0
|
||||
MxResult Helicopter::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
MxResult result = IslePathActor::Create(p_dsAction);
|
||||
LegoWorld* world = CurrentWorld();
|
||||
SetWorld(world);
|
||||
if (world->IsA("Act3")) {
|
||||
((Act3*) GetWorld())->SetUnkown420c(this);
|
||||
}
|
||||
world = GetWorld();
|
||||
if (world) {
|
||||
world->Add(this);
|
||||
}
|
||||
GetState();
|
||||
return result;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10003320
|
||||
void Helicopter::GetState()
|
||||
{
|
||||
m_state = (HelicopterState*) GameState()->GetState("HelicopterState");
|
||||
if (!m_state) {
|
||||
m_state = (HelicopterState*) GameState()->CreateState("HelicopterState");
|
||||
}
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10003360
|
||||
void Helicopter::VTable0xe4()
|
||||
{
|
||||
if (GameState()->GetCurrentAct() == LegoGameState::e_act1) {
|
||||
VTable0xe8(0x28, TRUE, 7);
|
||||
}
|
||||
|
||||
IslePathActor::VTable0xe4();
|
||||
|
||||
if (GameState()->GetCurrentAct() == LegoGameState::e_act1) {
|
||||
GameState()->SetCurrentArea(LegoGameState::e_unk60);
|
||||
if (CurrentActor()) {
|
||||
if (CurrentActor()->IsA("IslePathActor")) {
|
||||
((IslePathActor*) CurrentActor())->VTable0xe8(0x37, TRUE, 7);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
m_state->SetUnknown8(0);
|
||||
FUN_1003ee00(m_script, 0x16);
|
||||
FUN_1003ee00(m_script, 0x17);
|
||||
FUN_1003ee00(m_script, 0x18);
|
||||
FUN_1003ee00(m_script, 0x19);
|
||||
FUN_1003ee00(m_script, 0x1a);
|
||||
FUN_1003ee00(m_script, 0x1b);
|
||||
FUN_1003ee00(m_script, 0x1c);
|
||||
FUN_1003ee00(m_script, 0x1d);
|
||||
FUN_1003ee00(m_script, 0x1e);
|
||||
FUN_1003ee00(m_script, 0x1f);
|
||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
||||
ControlManager()->Unregister(this);
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10003480
|
||||
MxU32 Helicopter::VTable0xcc()
|
||||
{
|
||||
if (!FUN_1003ef60()) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (!m_world) {
|
||||
m_world = CurrentWorld();
|
||||
}
|
||||
|
||||
AnimationManager()->FUN_1005f6d0(FALSE);
|
||||
|
||||
if (CurrentActor()) {
|
||||
if (CurrentActor()->GetActorId() != GameState()->GetActorId()) {
|
||||
CurrentActor()->VTable0xe4();
|
||||
}
|
||||
}
|
||||
|
||||
switch (GameState()->GetCurrentAct()) {
|
||||
case LegoGameState::e_act1:
|
||||
m_script = *g_isleScript;
|
||||
AnimationManager()->FUN_10064670(FALSE);
|
||||
VTable0xe8(0x29, TRUE, 7);
|
||||
((Isle*) CurrentWorld())->SetUnknown13c(0x3c);
|
||||
FUN_10015820(TRUE, 0);
|
||||
TransitionManager()->StartTransition(MxTransitionManager::e_pixelation, 50, FALSE, TRUE);
|
||||
SetUnknownDC(4);
|
||||
PlayMusic(JukeBox::e_jail);
|
||||
break;
|
||||
case LegoGameState::e_act2:
|
||||
m_script = *g_act2mainScript;
|
||||
break;
|
||||
case LegoGameState::e_act3:
|
||||
m_script = *g_act3Script;
|
||||
break;
|
||||
}
|
||||
|
||||
VTable0xe0();
|
||||
InvokeAction(Extra::ActionType::e_start, m_script, 0x15, NULL);
|
||||
GetCurrentAction().SetObjectId(-1);
|
||||
ControlManager()->Register(this);
|
||||
return 1;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100035e0
|
||||
MxU32 Helicopter::VTable0xd4(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
MxU32 ret = 0;
|
||||
MxAtomId script;
|
||||
|
||||
switch (GameState()->GetCurrentAct()) {
|
||||
case LegoGameState::e_act1:
|
||||
script = *g_isleScript;
|
||||
break;
|
||||
case LegoGameState::e_act2:
|
||||
script = *g_act2mainScript;
|
||||
break;
|
||||
case LegoGameState::e_act3:
|
||||
script = *g_act3Script;
|
||||
break;
|
||||
}
|
||||
|
||||
if (p_param.GetUnknown0x28() == 1) {
|
||||
switch (p_param.GetClickedObjectId()) {
|
||||
case 0x17:
|
||||
if (*g_act3Script == script) {
|
||||
((Act3*) CurrentWorld())->SetUnkown4270(2);
|
||||
TransitionManager()->StartTransition(MxTransitionManager::e_pixelation, 50, FALSE, FALSE);
|
||||
}
|
||||
else if (m_state->GetUnkown8() != 0) {
|
||||
break;
|
||||
}
|
||||
VTable0xe4();
|
||||
GameState()->SetCurrentArea(LegoGameState::e_unk66);
|
||||
ret = 1;
|
||||
break;
|
||||
case 0x18: {
|
||||
if (*g_act3Script == script) {
|
||||
break;
|
||||
}
|
||||
Act1State* state = (Act1State*) GameState()->GetState("Act1State");
|
||||
if (m_state->GetUnkown8() == 0) {
|
||||
state->SetUnknown18(4);
|
||||
m_state->SetUnknown8(1);
|
||||
m_world->FUN_1001fc80(this);
|
||||
InvokeAction(Extra::ActionType::e_start, script, 0x20, NULL);
|
||||
SetUnknownDC(0);
|
||||
}
|
||||
ret = 1;
|
||||
break;
|
||||
}
|
||||
case 0x19:
|
||||
if (*g_act3Script == script) {
|
||||
break;
|
||||
}
|
||||
if (m_state->GetUnkown8() == 2) {
|
||||
m_state->SetUnknown8(3);
|
||||
m_world->FUN_1001fc80(this);
|
||||
InvokeAction(Extra::ActionType::e_start, script, 0x21, NULL);
|
||||
SetUnknownDC(4);
|
||||
}
|
||||
ret = 1;
|
||||
break;
|
||||
case 0x1a:
|
||||
if (*g_act3Script != script) {
|
||||
break;
|
||||
}
|
||||
ret = 1;
|
||||
/* fall through */
|
||||
case 0x1b:
|
||||
if (*g_act3Script != script) {
|
||||
break;
|
||||
}
|
||||
if (m_world && m_world->GetCamera()) {
|
||||
Mx3DPointFloat loc, dir, lookat;
|
||||
loc = m_world->GetCamera()->GetWorldLocation();
|
||||
dir = m_world->GetCamera()->GetWorldDirection();
|
||||
lookat = dir;
|
||||
float scale = 3;
|
||||
lookat.Mul(scale);
|
||||
lookat.Add(&loc);
|
||||
Mx3DPointFloat v68, v7c, v90(0, 1, 0), va4;
|
||||
v68 = m_world->GetCamera()->GetWorldUp();
|
||||
va4.EqualsCross(v68, dir);
|
||||
v7c.EqualsCross(va4, v90);
|
||||
if (ret) {
|
||||
if (((Act3*) m_world)->FUN_100727e0(m_unk0x138, loc, dir, v7c)) {
|
||||
break;
|
||||
}
|
||||
else if (((Act3*) m_world)->FUN_10072980(m_unk0x138, loc, dir, v7c)) {
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
ret = 1;
|
||||
break;
|
||||
case 0x1c:
|
||||
if (GameState()->GetCurrentAct() == LegoGameState::e_act1) {
|
||||
((Isle*) CurrentWorld())->SetUnknown13c(2);
|
||||
TransitionManager()->StartTransition(MxTransitionManager::e_pixelation, 50, FALSE, FALSE);
|
||||
VTable0xe4();
|
||||
}
|
||||
ret = 1;
|
||||
break;
|
||||
case 0x1d:
|
||||
ret = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
return ret;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10003c20
|
||||
MxU32 Helicopter::VTable0xd8(MxType18NotificationParam& p_param)
|
||||
{
|
||||
MxU32 ret = 0;
|
||||
|
||||
switch (m_state->GetUnkown8()) {
|
||||
case 1: {
|
||||
if (GameState()->GetCurrentAct() == LegoGameState::e_act1) {
|
||||
((Act1State*) GameState()->GetState("Act1State"))->SetUnknown18(4);
|
||||
VTable0xe8(0x2a, TRUE, 7);
|
||||
}
|
||||
else {
|
||||
VTable0xe8(0x31, TRUE, 7);
|
||||
}
|
||||
|
||||
m_state->SetUnknown8(2);
|
||||
|
||||
MxMatrix matrix;
|
||||
matrix.SetIdentity();
|
||||
|
||||
float s = sin(0.5235987901687622); // PI / 6, 30 deg
|
||||
float c = cos(0.5235987901687622); // PI / 6, 30 deg
|
||||
|
||||
float matrixCopy[4][4];
|
||||
memcpy(matrixCopy, matrix.GetData(), sizeof(matrixCopy));
|
||||
for (MxS32 i = 0; i < 4; i++) {
|
||||
matrix.GetData()[i][1] = matrixCopy[i][1] * c - matrixCopy[i][2] * s;
|
||||
matrix.GetData()[i][2] = matrixCopy[i][2] * c + matrixCopy[i][1] * s;
|
||||
}
|
||||
|
||||
Vector3 at(matrix[3]), dir(matrix[2]), up(matrix[1]);
|
||||
m_world->GetCamera()->SetWorldTransform(at, dir, up);
|
||||
FUN_10010c30();
|
||||
ret = 1;
|
||||
break;
|
||||
}
|
||||
case 3: {
|
||||
MxMatrix matrix;
|
||||
matrix.SetIdentity();
|
||||
|
||||
Vector3 at(matrix[3]), dir(matrix[2]), up(matrix[1]);
|
||||
at[1] = 1.25;
|
||||
m_world->GetCamera()->SetWorldTransform(at, dir, up);
|
||||
|
||||
if (GameState()->GetCurrentAct() == LegoGameState::e_act1) {
|
||||
((Act1State*) GameState()->GetState("Act1State"))->SetUnknown18(0);
|
||||
VTable0xe8(0x29, TRUE, 7);
|
||||
}
|
||||
else {
|
||||
VTable0xe8(0x30, TRUE, 7);
|
||||
}
|
||||
|
||||
m_state->SetUnknown8(0);
|
||||
ret = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10003e90
|
||||
void Helicopter::VTable0x74(Matrix4& p_transform)
|
||||
{
|
||||
if (m_unk0xea != 0) {
|
||||
m_roi->FUN_100a46b0(p_transform);
|
||||
FUN_10010c30();
|
||||
}
|
||||
else {
|
||||
m_roi->FUN_100a58f0(p_transform);
|
||||
m_roi->VTable0x14();
|
||||
if (m_cameraFlag) {
|
||||
FUN_10010c30();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10003ee0
|
||||
void Helicopter::VTable0x70(float p_float)
|
||||
{
|
||||
MxU32 state = m_state->GetUnkown8();
|
||||
switch (state) {
|
||||
default:
|
||||
LegoPathActor::VTable0x70(p_float);
|
||||
return;
|
||||
case 4:
|
||||
case 5:
|
||||
float f = m_unk0x1f0 - p_float + 3000;
|
||||
if (f >= 0) {
|
||||
float f2 = f / 3000 + 1;
|
||||
if (f2 < 0) {
|
||||
f2 = 0;
|
||||
}
|
||||
if (1.0f < f2) {
|
||||
f2 = 1.0f;
|
||||
}
|
||||
Vector3 v(m_unk0x160[3]);
|
||||
MxMatrix mat;
|
||||
Vector3 v2(m_unk0x1a8[3]);
|
||||
float* loc = m_unk0x1a8[3];
|
||||
mat.SetIdentity();
|
||||
float fa[4];
|
||||
Vector4 v3(fa);
|
||||
if (m_unk0x1f4.FUN_100040a0(v3, f2) == SUCCESS) {
|
||||
mat.FromQuaternion(v3);
|
||||
}
|
||||
v2.SetVector(loc);
|
||||
v2.Sub(&v);
|
||||
v2.Mul(f2);
|
||||
v2.Add(&v);
|
||||
m_world->GetCamera()->FUN_100123e0(mat, 0);
|
||||
}
|
||||
else {
|
||||
if (state == 4) {
|
||||
((Act3*) m_world)->FUN_10073400();
|
||||
}
|
||||
else {
|
||||
((Act3*) m_world)->FUN_10073430();
|
||||
}
|
||||
m_unk0xdc = 4;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100040a0
|
||||
MxResult HelicopterSubclass::FUN_100040a0(Vector4& p_v, float p_f)
|
||||
{
|
||||
MxU32 state = m_unk0x30;
|
||||
if (state == 1) {
|
||||
p_v.EqualsImpl(m_unk0x00.GetData());
|
||||
p_v[3] = acos(p_v[3]) * (1 - p_f) * 2.0;
|
||||
return p_v.NormalizeQuaternion();
|
||||
}
|
||||
else if (state == 2) {
|
||||
p_v.EqualsImpl(m_unk0x18.GetData());
|
||||
p_v[3] = acos(p_v[3]) * p_f * 2.0;
|
||||
return p_v.NormalizeQuaternion();
|
||||
}
|
||||
else if (state == 3) {
|
||||
double d1 = p_v.Dot(&m_unk0x00, &m_unk0x18), d2;
|
||||
if (d1 + 1 > 0.00001) {
|
||||
if (1 - d1 > 0.00001) {
|
||||
double d = acos(d1);
|
||||
sin(d);
|
||||
d1 = sin((1 - p_f) * d) / sin(d);
|
||||
d2 = sin(p_f * d) / sin(d);
|
||||
}
|
||||
else {
|
||||
d1 = 1 - p_f;
|
||||
d2 = p_f;
|
||||
}
|
||||
for (MxS32 i = 0; i < 4; i++) {
|
||||
p_v[i] = m_unk0x18[i] * d2 + m_unk0x00[i] * d1;
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
p_v[0] = -m_unk0x00[1];
|
||||
p_v[1] = m_unk0x00[1];
|
||||
p_v[2] = -m_unk0x00[3];
|
||||
p_v[3] = m_unk0x00[2];
|
||||
d1 = sin((1 - p_f) * 1.570796326794895);
|
||||
d2 = sin(p_f * 1.570796326794895);
|
||||
for (MxS32 i = 0; i < 3; i++) {
|
||||
p_v[i] = m_unk0x00[i] * d1 + p_v[i] * d2;
|
||||
}
|
||||
return SUCCESS;
|
||||
}
|
||||
else {
|
||||
return FAILURE;
|
||||
}
|
||||
}
|
||||
18
LEGO1/lego/legoomni/src/actors/isleactor.cpp
Normal file
18
LEGO1/lego/legoomni/src/actors/isleactor.cpp
Normal file
@@ -0,0 +1,18 @@
|
||||
#include "isleactor.h"
|
||||
|
||||
// NOTE: This is copied from base class LegoActor. IsleActor may in fact be larger but we don't know yet.
|
||||
DECOMP_SIZE_ASSERT(IsleActor, 0x78)
|
||||
|
||||
// STUB: LEGO1 0x1002c780
|
||||
MxResult IsleActor::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1002c7b0
|
||||
MxLong IsleActor::Notify(MxParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
57
LEGO1/lego/legoomni/src/actors/islepathactor.cpp
Normal file
57
LEGO1/lego/legoomni/src/actors/islepathactor.cpp
Normal file
@@ -0,0 +1,57 @@
|
||||
#include "islepathactor.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(IslePathActor, 0x160)
|
||||
|
||||
// FUNCTION: LEGO1 0x1001a200
|
||||
IslePathActor::IslePathActor()
|
||||
{
|
||||
this->m_world = NULL;
|
||||
this->m_unk0x13c = 6.0;
|
||||
this->m_unk0x15c = 1.0;
|
||||
this->m_unk0x158 = 0;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1001a280
|
||||
MxResult IslePathActor::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
return MxEntity::Create(p_dsAction);
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1001a2a0
|
||||
void IslePathActor::Destroy(MxBool p_fromDestructor)
|
||||
{
|
||||
if (!p_fromDestructor) {
|
||||
LegoPathActor::Destroy(FALSE);
|
||||
}
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1001a2c0
|
||||
MxLong IslePathActor::Notify(MxParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1001a350
|
||||
void IslePathActor::VTable0xe0()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1001a3f0
|
||||
void IslePathActor::VTable0xe4()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1001b2a0
|
||||
void IslePathActor::VTable0xe8(MxU32, MxBool, MxU8)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1001b5b0
|
||||
void IslePathActor::VTable0xec()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
44
LEGO1/lego/legoomni/src/actors/jetski.cpp
Normal file
44
LEGO1/lego/legoomni/src/actors/jetski.cpp
Normal file
@@ -0,0 +1,44 @@
|
||||
#include "jetski.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(Jetski, 0x164);
|
||||
|
||||
// FUNCTION: LEGO1 0x1007e3b0
|
||||
Jetski::Jetski()
|
||||
{
|
||||
this->m_unk0x13c = 25.0;
|
||||
this->m_unk0x150 = 2.0;
|
||||
this->m_unk0x148 = 1;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1007e630
|
||||
MxResult Jetski::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1007e680
|
||||
void Jetski::VTable0x70(float p_float)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1007e6f0
|
||||
void Jetski::VTable0xe4()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1007e750
|
||||
MxU32 Jetski::VTable0xcc()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1007e8e0
|
||||
MxU32 Jetski::VTable0xd4(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
128
LEGO1/lego/legoomni/src/actors/jukeboxentity.cpp
Normal file
128
LEGO1/lego/legoomni/src/actors/jukeboxentity.cpp
Normal file
@@ -0,0 +1,128 @@
|
||||
#include "jukeboxentity.h"
|
||||
|
||||
#include "isle.h"
|
||||
#include "islepathactor.h"
|
||||
#include "jukeboxstate.h"
|
||||
#include "legogamestate.h"
|
||||
#include "legoomni.h"
|
||||
#include "legoutils.h"
|
||||
#include "misc.h"
|
||||
#include "mxbackgroundaudiomanager.h"
|
||||
#include "mxmisc.h"
|
||||
#include "mxnotificationmanager.h"
|
||||
#include "mxtransitionmanager.h"
|
||||
|
||||
// FUNCTION: LEGO1 0x10085bc0
|
||||
JukeBoxEntity::JukeBoxEntity()
|
||||
{
|
||||
NotificationManager()->Register(this);
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10085dd0
|
||||
JukeBoxEntity::~JukeBoxEntity()
|
||||
{
|
||||
NotificationManager()->Unregister(this);
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10085e40
|
||||
MxLong JukeBoxEntity::Notify(MxParam& p_param)
|
||||
{
|
||||
if (((MxNotificationParam&) p_param).GetType() == c_notificationType11) {
|
||||
if (!FUN_1003ef60()) {
|
||||
return 1;
|
||||
}
|
||||
|
||||
if (CurrentActor()->GetActorId() != GameState()->GetActorId()) {
|
||||
CurrentActor()->VTable0xe4();
|
||||
}
|
||||
|
||||
((Isle*) FindWorld(*g_isleScript, 0))->SetUnknown13c(0x35);
|
||||
TransitionManager()->StartTransition(MxTransitionManager::e_pixelation, 50, FALSE, FALSE);
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10085ed0
|
||||
void JukeBoxEntity::StartAction()
|
||||
{
|
||||
MxDSAction action;
|
||||
BackgroundAudioManager()->Stop();
|
||||
JukeBoxState* state = (JukeBoxState*) GameState()->GetState("JukeBoxState");
|
||||
state->SetActive(TRUE);
|
||||
|
||||
switch (state->GetState()) {
|
||||
case 0:
|
||||
InvokeAction(Extra::e_start, *g_isleScript, 0x319, NULL);
|
||||
GameState()->SetUnknown0x41c(0x37);
|
||||
break;
|
||||
case 1:
|
||||
InvokeAction(Extra::e_start, *g_isleScript, 0x31e, NULL);
|
||||
GameState()->SetUnknown0x41c(0x38);
|
||||
break;
|
||||
case 2:
|
||||
InvokeAction(Extra::e_start, *g_isleScript, 0x31b, NULL);
|
||||
GameState()->SetUnknown0x41c(0x39);
|
||||
break;
|
||||
case 3:
|
||||
InvokeAction(Extra::e_start, *g_isleScript, 0x31a, NULL);
|
||||
GameState()->SetUnknown0x41c(0x3a);
|
||||
break;
|
||||
case 4:
|
||||
InvokeAction(Extra::e_start, *g_isleScript, 0x31f, NULL);
|
||||
GameState()->SetUnknown0x41c(0x3b);
|
||||
break;
|
||||
case 5:
|
||||
InvokeAction(Extra::e_start, *g_isleScript, 0x31c, NULL);
|
||||
GameState()->SetUnknown0x41c(0x3c);
|
||||
break;
|
||||
}
|
||||
|
||||
action.SetAtomId(*g_jukeboxScript);
|
||||
action.SetObjectId(GameState()->GetUnknown0x41c());
|
||||
|
||||
m_audioEnabled = BackgroundAudioManager()->GetEnabled();
|
||||
if (!m_audioEnabled) {
|
||||
BackgroundAudioManager()->Enable(TRUE);
|
||||
}
|
||||
|
||||
BackgroundAudioManager()->PlayMusic(action, 5, 4);
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x100860f0
|
||||
void JukeBoxEntity::StopAction(MxU32 p_state)
|
||||
{
|
||||
JukeBoxState* state = (JukeBoxState*) GameState()->GetState("JukeBoxState");
|
||||
|
||||
if (state && state->IsActive()) {
|
||||
switch (p_state) {
|
||||
case 0x37:
|
||||
state->SetActive(FALSE);
|
||||
InvokeAction(Extra::e_stop, *g_isleScript, 0x319, NULL);
|
||||
break;
|
||||
case 0x38:
|
||||
state->SetActive(FALSE);
|
||||
InvokeAction(Extra::e_stop, *g_isleScript, 0x31e, NULL);
|
||||
break;
|
||||
case 0x39:
|
||||
state->SetActive(FALSE);
|
||||
InvokeAction(Extra::e_stop, *g_isleScript, 0x31b, NULL);
|
||||
break;
|
||||
case 0x3a:
|
||||
state->SetActive(FALSE);
|
||||
InvokeAction(Extra::e_stop, *g_isleScript, 0x31a, NULL);
|
||||
break;
|
||||
case 0x3b:
|
||||
state->SetActive(FALSE);
|
||||
InvokeAction(Extra::e_stop, *g_isleScript, 0x31f, NULL);
|
||||
break;
|
||||
case 0x3c:
|
||||
state->SetActive(FALSE);
|
||||
InvokeAction(Extra::e_stop, *g_isleScript, 0x31c, NULL);
|
||||
break;
|
||||
}
|
||||
|
||||
BackgroundAudioManager()->Enable(IsBackgroundAudioEnabled());
|
||||
}
|
||||
}
|
||||
52
LEGO1/lego/legoomni/src/actors/motorcycle.cpp
Normal file
52
LEGO1/lego/legoomni/src/actors/motorcycle.cpp
Normal file
@@ -0,0 +1,52 @@
|
||||
#include "motocycle.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(Motocycle, 0x16c);
|
||||
|
||||
// FUNCTION: LEGO1 0x100357b0
|
||||
Motocycle::Motocycle()
|
||||
{
|
||||
this->m_unk0x13c = 40.0;
|
||||
this->m_unk0x150 = 1.75;
|
||||
this->m_unk0x148 = 1;
|
||||
this->m_unk0x164 = 1.0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10035a40
|
||||
MxResult Motocycle::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10035ad0
|
||||
void Motocycle::VTable0x70(float p_float)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10035bc0
|
||||
void Motocycle::VTable0xe4()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10035c50
|
||||
MxU32 Motocycle::VTable0xcc()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10035d70
|
||||
MxU32 Motocycle::VTable0xd4(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10035df0
|
||||
MxU32 Motocycle::VTable0xdc(MxType19NotificationParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
38
LEGO1/lego/legoomni/src/actors/pizza.cpp
Normal file
38
LEGO1/lego/legoomni/src/actors/pizza.cpp
Normal file
@@ -0,0 +1,38 @@
|
||||
#include "pizza.h"
|
||||
|
||||
#include "mxmisc.h"
|
||||
#include "mxticklemanager.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(Pizza, 0x9c);
|
||||
|
||||
// FUNCTION: LEGO1 0x10037ef0
|
||||
Pizza::Pizza()
|
||||
{
|
||||
this->m_unk0x7c = 0;
|
||||
this->m_unk0x80 = 0;
|
||||
this->m_unk0x84 = 0;
|
||||
this->m_unk0x88 = 0;
|
||||
this->m_unk0x8c = -1;
|
||||
this->m_unk0x98 = 0;
|
||||
this->m_unk0x90 = 0x80000000;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10038100
|
||||
Pizza::~Pizza()
|
||||
{
|
||||
TickleManager()->UnregisterClient(this);
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10038170
|
||||
MxResult Pizza::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100388a0
|
||||
MxResult Pizza::Tickle()
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
8
LEGO1/lego/legoomni/src/actors/pizzeria.cpp
Normal file
8
LEGO1/lego/legoomni/src/actors/pizzeria.cpp
Normal file
@@ -0,0 +1,8 @@
|
||||
#include "pizzeria.h"
|
||||
|
||||
// STUB: LEGO1 0x100179c0
|
||||
MxResult Pizzeria::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
33
LEGO1/lego/legoomni/src/actors/racecar.cpp
Normal file
33
LEGO1/lego/legoomni/src/actors/racecar.cpp
Normal file
@@ -0,0 +1,33 @@
|
||||
#include "racecar.h"
|
||||
|
||||
#include "legocontrolmanager.h"
|
||||
#include "misc.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(RaceCar, 0x164);
|
||||
|
||||
// FUNCTION: LEGO1 0x10028200
|
||||
RaceCar::RaceCar()
|
||||
{
|
||||
m_unk0x13c = 40.0;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x10028420
|
||||
RaceCar::~RaceCar()
|
||||
{
|
||||
ControlManager()->Unregister(this);
|
||||
VTable0xe4();
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10028490
|
||||
MxResult RaceCar::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100284d0
|
||||
MxU32 RaceCar::VTable0xcc()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
160
LEGO1/lego/legoomni/src/actors/radio.cpp
Normal file
160
LEGO1/lego/legoomni/src/actors/radio.cpp
Normal file
@@ -0,0 +1,160 @@
|
||||
#include "radio.h"
|
||||
|
||||
#include "legocontrolmanager.h"
|
||||
#include "legogamestate.h"
|
||||
#include "legoomni.h"
|
||||
#include "misc.h"
|
||||
#include "mxbackgroundaudiomanager.h"
|
||||
#include "mxcontrolpresenter.h"
|
||||
#include "mxmisc.h"
|
||||
#include "mxnotificationmanager.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(Radio, 0x10);
|
||||
|
||||
// FUNCTION: LEGO1 0x1002c850
|
||||
Radio::Radio()
|
||||
{
|
||||
NotificationManager()->Register(this);
|
||||
ControlManager()->Register(this);
|
||||
|
||||
m_unk0x0c = TRUE;
|
||||
CreateRadioState();
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1002c990
|
||||
Radio::~Radio()
|
||||
{
|
||||
if (m_state->IsActive()) {
|
||||
BackgroundAudioManager()->Stop();
|
||||
m_state->SetActive(FALSE);
|
||||
}
|
||||
|
||||
ControlManager()->Unregister(this);
|
||||
NotificationManager()->Unregister(this);
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1002ca30
|
||||
MxLong Radio::Notify(MxParam& p_param)
|
||||
{
|
||||
MxLong result = 0;
|
||||
|
||||
if (m_unk0x0c) {
|
||||
switch (((MxNotificationParam&) p_param).GetType()) {
|
||||
case c_notificationEndAction:
|
||||
result = HandleEndAction((MxEndActionNotificationParam&) p_param);
|
||||
break;
|
||||
case c_notificationClick:
|
||||
result = HandleClick((LegoControlManagerEvent&) p_param);
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1002ca70
|
||||
void Radio::Play()
|
||||
{
|
||||
if (!m_state->IsActive()) {
|
||||
CurrentWorld();
|
||||
|
||||
MxDSAction action;
|
||||
action.SetObjectId(m_state->FUN_1002d090());
|
||||
action.SetAtomId(*g_jukeboxScript);
|
||||
action.SetLoopCount(1);
|
||||
|
||||
m_audioEnabled = BackgroundAudioManager()->GetEnabled();
|
||||
if (!m_audioEnabled) {
|
||||
BackgroundAudioManager()->Enable(TRUE);
|
||||
}
|
||||
|
||||
BackgroundAudioManager()->PlayMusic(action, 3, 4);
|
||||
m_state->SetActive(TRUE);
|
||||
}
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1002cb70
|
||||
void Radio::Stop()
|
||||
{
|
||||
if (m_state->IsActive()) {
|
||||
LegoWorld* world = CurrentWorld();
|
||||
|
||||
MxControlPresenter* presenter = (MxControlPresenter*) world->Find(world->GetAtom(), 18);
|
||||
|
||||
if (presenter) {
|
||||
presenter->VTable0x6c(0);
|
||||
}
|
||||
|
||||
BackgroundAudioManager()->Stop();
|
||||
BackgroundAudioManager()->Enable(m_audioEnabled);
|
||||
m_state->SetActive(FALSE);
|
||||
}
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1002cbc0
|
||||
MxLong Radio::HandleClick(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
MxDSAction action; // Unused
|
||||
MxS32 objectId = p_param.GetClickedObjectId();
|
||||
|
||||
if (objectId == 18) {
|
||||
if (m_state->IsActive()) {
|
||||
Stop();
|
||||
}
|
||||
else {
|
||||
Play();
|
||||
}
|
||||
|
||||
if (CurrentWorld()) {
|
||||
#ifdef COMPAT_MODE
|
||||
MxNotificationParam param(c_notificationEndAction, this);
|
||||
CurrentWorld()->Notify(param);
|
||||
#else
|
||||
CurrentWorld()->Notify(MxNotificationParam(c_notificationType0, this));
|
||||
#endif
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1002ccc0
|
||||
MxLong Radio::HandleEndAction(MxEndActionNotificationParam& p_param)
|
||||
{
|
||||
if (m_state->IsActive() &&
|
||||
m_state->FUN_1002d0c0(p_param.GetAction()->GetAtomId(), p_param.GetAction()->GetObjectId())) {
|
||||
|
||||
MxDSAction action;
|
||||
action.SetAtomId(*g_jukeboxScript);
|
||||
action.SetObjectId(m_state->FUN_1002d090());
|
||||
action.SetLoopCount(1);
|
||||
|
||||
BackgroundAudioManager()->PlayMusic(action, 3, 4);
|
||||
return 1;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1002cdc0
|
||||
void Radio::Initialize(MxBool p_und)
|
||||
{
|
||||
if (m_unk0x0c != p_und) {
|
||||
m_unk0x0c = p_und;
|
||||
CreateRadioState();
|
||||
}
|
||||
}
|
||||
|
||||
// FUNCTION: LEGO1 0x1002cde0
|
||||
void Radio::CreateRadioState()
|
||||
{
|
||||
LegoGameState* gameState = GameState();
|
||||
RadioState* state = (RadioState*) gameState->GetState("RadioState");
|
||||
if (state == NULL) {
|
||||
state = (RadioState*) gameState->CreateState("RadioState");
|
||||
}
|
||||
|
||||
m_state = state;
|
||||
}
|
||||
52
LEGO1/lego/legoomni/src/actors/skateboard.cpp
Normal file
52
LEGO1/lego/legoomni/src/actors/skateboard.cpp
Normal file
@@ -0,0 +1,52 @@
|
||||
#include "skateboard.h"
|
||||
|
||||
#include "decomp.h"
|
||||
#include "mxmisc.h"
|
||||
#include "mxnotificationmanager.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(SkateBoard, 0x168);
|
||||
|
||||
// FUNCTION: LEGO1 0x1000fd40
|
||||
SkateBoard::SkateBoard()
|
||||
{
|
||||
this->m_unk0x160 = 0;
|
||||
this->m_unk0x13c = 15.0;
|
||||
this->m_unk0x150 = 3.5;
|
||||
this->m_unk0x148 = 1;
|
||||
|
||||
NotificationManager()->Register(this);
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10010000
|
||||
MxResult SkateBoard::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10010050
|
||||
void SkateBoard::VTable0xe4()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100100e0
|
||||
MxU32 SkateBoard::VTable0xcc()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x10010230
|
||||
MxU32 SkateBoard::VTable0xd4(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x100104f0
|
||||
MxU32 SkateBoard::VTable0xd0()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
71
LEGO1/lego/legoomni/src/actors/towtrack.cpp
Normal file
71
LEGO1/lego/legoomni/src/actors/towtrack.cpp
Normal file
@@ -0,0 +1,71 @@
|
||||
#include "towtrack.h"
|
||||
|
||||
DECOMP_SIZE_ASSERT(TowTrack, 0x180);
|
||||
|
||||
// FUNCTION: LEGO1 0x1004c720
|
||||
TowTrack::TowTrack()
|
||||
{
|
||||
this->m_unk0x168 = 0;
|
||||
this->m_unk0x16a = -1;
|
||||
this->m_unk0x164 = 0;
|
||||
this->m_unk0x16c = 0;
|
||||
this->m_unk0x170 = -1;
|
||||
this->m_unk0x16e = 0;
|
||||
this->m_unk0x174 = -1;
|
||||
this->m_unk0x13c = 40.0;
|
||||
this->m_unk0x178 = 1.0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1004c9e0
|
||||
MxResult TowTrack::Create(MxDSAction& p_dsAction)
|
||||
{
|
||||
// TODO
|
||||
return SUCCESS;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1004cb10
|
||||
void TowTrack::VTable0x70(float p_float)
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1004cc80
|
||||
MxLong TowTrack::Notify(MxParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1004cd30
|
||||
MxU32 TowTrack::VTable0xd8(MxType18NotificationParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1004d330
|
||||
MxU32 TowTrack::VTable0xdc(MxType19NotificationParam& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1004d690
|
||||
MxU32 TowTrack::VTable0xcc()
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1004d8f0
|
||||
void TowTrack::VTable0xe4()
|
||||
{
|
||||
// TODO
|
||||
}
|
||||
|
||||
// STUB: LEGO1 0x1004d9e0
|
||||
MxU32 TowTrack::VTable0xd4(LegoControlManagerEvent& p_param)
|
||||
{
|
||||
// TODO
|
||||
return 0;
|
||||
}
|
||||
Reference in New Issue
Block a user