mirror of
https://github.com/isledecomp/isle-portable.git
synced 2026-02-03 12:31:15 +00:00
* Fix remaining vtordisp issues (#1016) * Fix LegoRaceActor * Fix LegoRaceMap * Fix LegoCarRaceActor * Fix LegoJetskiRaceActor * Fix LegoJetski * Fix LegoRaceCar * Downgrade orig addr unique message to debug * Implement/match Ambulance::HandleEndAction (#1018) * Implement/match Ambulance::HandleClick (#1019) * Implement/match Ambulance::HandleClick * Remove junk * Add Ambulance::FUN_10036e60 * Implement/match Ambulance::Tickle (#1021) * Match LegoMeterPresenter::ParseExtra (#1022) * Match LegoMeterPresenter::ParseExtra * Add LegoMeterPresenter to factory * Add call to parent * Add missing TODO * Implement/match Ambulance::ActivateSceneActions (#1023) * Fix CaveEntity class (#1024) * Fix CaveEntity class * Rename function * Implement/match JailEntity::HandleClick and CaveEntity::HandleClick (#1025) * Implement/match JailEntity::HandleClick and CaveEntity::HandleClick * Fix * Add remaining classes, implement/match LegoObjectFactory (#1026) * Add missing classes * Match LegoObjectFactory * Remove semicolon * Add symbol * Fix * Implement/match Ambulance::VTable0x70 (#1027) * Implement/match Ambulance::HandleButtonDown (#1028) * Implement/match Ambulance::HandlePathStruct (#1029) * Implement/match Ambulance::HandlePathStruct * Add annotation * Implement/match remaining Ambulance functions (#1030) * Fix camera glitch (#1031) * Implement LegoAnimScene::FUN_1009f490 (#1032) * Implement LegoAnimScene::FUN_1009f490 * Update legoanim.cpp * Update legoanim.cpp * Update legoanim.cpp * Bugfix for LegoMeterPresenter::DrawMeter (#1033) * feat: Implement several ::Serialize functions (#1017) * feat: Implement many ::Serialize functions * address review comments, part 1 [skip ci] * address review comments, part 2 [skip ci] * review comments (final part) * refactor: Remove Read/Write duplication * fix merge conflict * Match PizzeriaState::Serialize again * Remove unused variable, add LegoVehicleBuildState::Serialize * Implement AnimState::Serialize * fix: Conform with naming scheme * refactor: change names back * refactor: int to MxS32 --------- Co-authored-by: jonschz <jonschz@users.noreply.github.com> --------- Co-authored-by: MS <disinvite@users.noreply.github.com> Co-authored-by: jonschz <17198703+jonschz@users.noreply.github.com> Co-authored-by: jonschz <jonschz@users.noreply.github.com>
114 lines
2.5 KiB
C++
114 lines
2.5 KiB
C++
#ifndef LEGOPATHSTRUCT_H
|
|
#define LEGOPATHSTRUCT_H
|
|
|
|
#include "decomp.h"
|
|
#include "mxatom.h"
|
|
#include "mxnotificationparam.h"
|
|
#include "mxtypes.h"
|
|
|
|
class LegoPathActor;
|
|
class LegoWorld;
|
|
|
|
// VTABLE: LEGO1 0x100d6230
|
|
// SIZE 0x10
|
|
class LegoPathStructEvent : public MxNotificationParam {
|
|
public:
|
|
LegoPathStructEvent(NotificationId p_type, MxCore* p_sender, MxU8 p_trigger, MxS16 p_data) : MxNotificationParam()
|
|
{
|
|
m_type = p_type;
|
|
m_sender = p_sender;
|
|
m_data = p_data;
|
|
m_trigger = p_trigger;
|
|
}
|
|
|
|
// FUNCTION: LEGO1 0x1001bac0
|
|
MxNotificationParam* Clone() const override
|
|
{
|
|
return new LegoPathStructEvent(m_type, m_sender, m_trigger, m_data);
|
|
} // vtable+0x04
|
|
|
|
inline MxU8 GetTrigger() { return m_trigger; }
|
|
inline MxS16 GetData() { return m_data; }
|
|
|
|
protected:
|
|
MxS16 m_data; // 0x0c
|
|
MxU8 m_trigger; // 0x0e
|
|
};
|
|
|
|
// VTABLE: LEGO1 0x100d7d9c
|
|
// SIZE 0x0c
|
|
struct LegoPathStructBase {
|
|
public:
|
|
enum {
|
|
c_bit1 = 0x01 << 24,
|
|
c_bit2 = 0x02 << 24,
|
|
c_bit3 = 0x04 << 24,
|
|
c_bit4 = 0x08 << 24,
|
|
c_bit5 = 0x10 << 24,
|
|
c_bit6 = 0x20 << 24,
|
|
c_bit7 = 0x40 << 24
|
|
};
|
|
|
|
LegoPathStructBase() : m_name(NULL), m_flags(0) {}
|
|
|
|
// FUNCTION: LEGO1 0x10047420
|
|
virtual ~LegoPathStructBase()
|
|
{
|
|
if (m_name != NULL) {
|
|
delete[] m_name;
|
|
}
|
|
}
|
|
|
|
char* m_name; // 0x04
|
|
MxU32 m_flags; // 0x08
|
|
};
|
|
|
|
// VTABLE: LEGO1 0x100d7da0
|
|
// SIZE 0x14
|
|
class LegoPathStruct : public LegoPathStructBase {
|
|
public:
|
|
enum Trigger {
|
|
c_camAnim = 'C',
|
|
c_d = 'D',
|
|
c_e = 'E',
|
|
c_g = 'G',
|
|
c_h = 'H',
|
|
c_music = 'M',
|
|
c_s = 'S',
|
|
c_w = 'W'
|
|
};
|
|
|
|
// FUNCTION: LEGO1 0x100473a0
|
|
LegoPathStruct() : m_world(NULL) {}
|
|
|
|
// FUNCTION: LEGO1 0x10047470
|
|
~LegoPathStruct() override {}
|
|
|
|
virtual void HandleTrigger(LegoPathActor* p_actor, MxBool p_direction, MxU32 p_data); // vtable+0x04
|
|
|
|
inline void SetWorld(LegoWorld* p_world) { m_world = p_world; }
|
|
inline void SetAtomId(const MxAtomId& p_atomId) { m_atomId = p_atomId; }
|
|
|
|
private:
|
|
MxBool HandleTrigger(LegoPathActor* p_actor, MxBool p_direction, MxU32 p_data, MxBool p_bool);
|
|
void FUN_1001bc40(const char* p_name, MxU32 p_data, MxBool p_bool);
|
|
void PlayMusic(MxBool p_direction, MxU32 p_data);
|
|
|
|
LegoWorld* m_world; // 0x0c
|
|
MxAtomId m_atomId; // 0x10
|
|
};
|
|
|
|
// SYNTHETIC: LEGO1 0x1001bb80
|
|
// LegoPathStructEvent::`scalar deleting destructor'
|
|
|
|
// SYNTHETIC: LEGO1 0x1001bbf0
|
|
// LegoPathStructEvent::~LegoPathStructEvent
|
|
|
|
// SYNTHETIC: LEGO1 0x10047440
|
|
// LegoPathStructBase::`scalar deleting destructor'
|
|
|
|
// SYNTHETIC: LEGO1 0x10047890
|
|
// LegoPathStruct::`vector deleting destructor'
|
|
|
|
#endif // LEGOPATHSTRUCT_H
|