mirror of
https://github.com/isledecomp/isle.git
synced 2026-06-18 02:14:09 +00:00
Rename FUN_* symbols
Rename's FUN_* symbols.
This commit is contained in:
parent
2614373c8b
commit
0e81b9cb2f
@ -66,7 +66,7 @@ BOOL CMainDialog::OnInitDialog()
|
|||||||
LegoDeviceEnumerate* info = currentConfigApp->m_dxInfo;
|
LegoDeviceEnumerate* info = currentConfigApp->m_dxInfo;
|
||||||
assert(info);
|
assert(info);
|
||||||
|
|
||||||
info->FUN_1009d210();
|
info->FilterSupportedDrivers();
|
||||||
m_modified = currentConfigApp->ReadRegisterSettings();
|
m_modified = currentConfigApp->ReadRegisterSettings();
|
||||||
CListBox* list_3d_devices = (CListBox*) GetDlgItem(IDC_LIST_3DDEVICES);
|
CListBox* list_3d_devices = (CListBox*) GetDlgItem(IDC_LIST_3DDEVICES);
|
||||||
int driver_i = 0;
|
int driver_i = 0;
|
||||||
|
|||||||
@ -269,7 +269,7 @@ BOOL CConfigApp::ReadRegisterSettings()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (r < 0) {
|
if (r < 0) {
|
||||||
m_dxInfo->FUN_1009d210();
|
m_dxInfo->FilterSupportedDrivers();
|
||||||
r = m_dxInfo->GetBestDevice();
|
r = m_dxInfo->GetBestDevice();
|
||||||
is_modified = TRUE;
|
is_modified = TRUE;
|
||||||
assert(r >= 0);
|
assert(r >= 0);
|
||||||
|
|||||||
@ -111,8 +111,8 @@ class Act3Cop : public Act3Actor {
|
|||||||
|
|
||||||
void SetUnknown0x20(MxFloat p_unk0x20) { m_unk0x20 = p_unk0x20; }
|
void SetUnknown0x20(MxFloat p_unk0x20) { m_unk0x20 = p_unk0x20; }
|
||||||
|
|
||||||
MxResult FUN_10040350(Act3Ammo& p_ammo, const Vector3&);
|
MxResult RespondToAmmoHit(Act3Ammo& p_ammo, const Vector3&);
|
||||||
MxResult FUN_10040360();
|
MxResult ChooseCopDestination();
|
||||||
|
|
||||||
// SYNTHETIC: LEGO1 0x10043120
|
// SYNTHETIC: LEGO1 0x10043120
|
||||||
// Act3Cop::`scalar deleting destructor'
|
// Act3Cop::`scalar deleting destructor'
|
||||||
@ -153,14 +153,14 @@ class Act3Brickster : public Act3Actor {
|
|||||||
void SetUnknown0x24(MxFloat p_unk0x24) { m_unk0x24 = p_unk0x24; }
|
void SetUnknown0x24(MxFloat p_unk0x24) { m_unk0x24 = p_unk0x24; }
|
||||||
void SetUnknown0x50(MxFloat p_unk0x50) { m_unk0x50 = p_unk0x50; }
|
void SetUnknown0x50(MxFloat p_unk0x50) { m_unk0x50 = p_unk0x50; }
|
||||||
|
|
||||||
MxResult FUN_100417a0(Act3Ammo& p_ammo, const Vector3&);
|
MxResult RespondToAmmoHit(Act3Ammo& p_ammo, const Vector3&);
|
||||||
MxResult FUN_100417c0();
|
MxResult ChooseBricksterDestination();
|
||||||
|
|
||||||
// SYNTHETIC: LEGO1 0x10043250
|
// SYNTHETIC: LEGO1 0x10043250
|
||||||
// Act3Brickster::`scalar deleting destructor'
|
// Act3Brickster::`scalar deleting destructor'
|
||||||
|
|
||||||
private:
|
private:
|
||||||
MxS32 FUN_10042300();
|
MxS32 EvadeNearestCop();
|
||||||
|
|
||||||
MxFloat m_unk0x20; // 0x20
|
MxFloat m_unk0x20; // 0x20
|
||||||
MxFloat m_unk0x24; // 0x24
|
MxFloat m_unk0x24; // 0x24
|
||||||
|
|||||||
@ -76,8 +76,8 @@ class Helicopter : public IslePathActor {
|
|||||||
void Exit() override; // vtable+0xe4
|
void Exit() override; // vtable+0xe4
|
||||||
|
|
||||||
void CreateState();
|
void CreateState();
|
||||||
void FUN_10004640(const Matrix4& p_matrix);
|
void StartGoodEndingFlight(const Matrix4& p_matrix);
|
||||||
void FUN_10004670(const Matrix4& p_matrix);
|
void StartBadEndingFlight(const Matrix4& p_matrix);
|
||||||
|
|
||||||
// SYNTHETIC: LEGO1 0x10003210
|
// SYNTHETIC: LEGO1 0x10003210
|
||||||
// Helicopter::`scalar deleting destructor'
|
// Helicopter::`scalar deleting destructor'
|
||||||
@ -86,7 +86,7 @@ class Helicopter : public IslePathActor {
|
|||||||
friend class Act3;
|
friend class Act3;
|
||||||
|
|
||||||
protected:
|
protected:
|
||||||
void FUN_100042a0(const Matrix4& p_matrix);
|
void PrepareEndingFlightTransform(const Matrix4& p_matrix);
|
||||||
|
|
||||||
MxMatrix m_unk0x160; // 0x160
|
MxMatrix m_unk0x160; // 0x160
|
||||||
MxMatrix m_unk0x1a8; // 0x1a8
|
MxMatrix m_unk0x1a8; // 0x1a8
|
||||||
|
|||||||
@ -20,7 +20,7 @@ class Lego3DSound {
|
|||||||
MxResult Create(LPDIRECTSOUNDBUFFER p_directSoundBuffer, const char* p_name, MxS32 p_volume);
|
MxResult Create(LPDIRECTSOUNDBUFFER p_directSoundBuffer, const char* p_name, MxS32 p_volume);
|
||||||
void Destroy();
|
void Destroy();
|
||||||
MxU32 UpdatePosition(LPDIRECTSOUNDBUFFER p_directSoundBuffer);
|
MxU32 UpdatePosition(LPDIRECTSOUNDBUFFER p_directSoundBuffer);
|
||||||
void FUN_10011a60(LPDIRECTSOUNDBUFFER p_directSoundBuffer, const char* p_name);
|
void AttachToSoundTarget(LPDIRECTSOUNDBUFFER p_directSoundBuffer, const char* p_name);
|
||||||
void Reset();
|
void Reset();
|
||||||
MxS32 SetDistance(MxS32 p_min, MxS32 p_max);
|
MxS32 SetDistance(MxS32 p_min, MxS32 p_max);
|
||||||
|
|
||||||
|
|||||||
@ -160,19 +160,19 @@ class LegoAnimationManager : public MxCore {
|
|||||||
void Reset(MxBool p_und);
|
void Reset(MxBool p_und);
|
||||||
void Suspend();
|
void Suspend();
|
||||||
void Resume();
|
void Resume();
|
||||||
void FUN_1005f6d0(MxBool p_unk0x400);
|
void EnableExtras(MxBool p_unk0x400);
|
||||||
void EnableCamAnims(MxBool p_enableCamAnims);
|
void EnableCamAnims(MxBool p_enableCamAnims);
|
||||||
MxResult LoadWorldInfo(LegoOmni::World p_worldId);
|
MxResult LoadWorldInfo(LegoOmni::World p_worldId);
|
||||||
MxBool FindVehicle(const char* p_name, MxU32& p_index);
|
MxBool FindVehicle(const char* p_name, MxU32& p_index);
|
||||||
MxResult ReadAnimInfo(LegoStorage* p_storage, AnimInfo* p_info);
|
MxResult ReadAnimInfo(LegoStorage* p_storage, AnimInfo* p_info);
|
||||||
MxResult ReadModelInfo(LegoStorage* p_storage, ModelInfo* p_info);
|
MxResult ReadModelInfo(LegoStorage* p_storage, ModelInfo* p_info);
|
||||||
void FUN_10060480(const LegoChar* p_characterNames[], MxU32 p_numCharacterNames);
|
void EnableCharactersByName(const LegoChar* p_characterNames[], MxU32 p_numCharacterNames);
|
||||||
void FUN_100604d0(MxBool p_unk0x08);
|
void SetAllCharactersAnimationEnabled(MxBool p_unk0x08);
|
||||||
void FUN_100604f0(MxS32 p_objectIds[], MxU32 p_numObjectIds);
|
void EnableAnimationsByObjectId(MxS32 p_objectIds[], MxU32 p_numObjectIds);
|
||||||
void FUN_10060540(MxBool p_unk0x29);
|
void SetAllAnimationsEnabled(MxBool p_unk0x29);
|
||||||
void FUN_10060570(MxBool p_unk0x1a);
|
void SetAutoPlayAnimations(MxBool p_unk0x1a);
|
||||||
MxResult StartEntityAction(MxDSAction& p_dsAction, LegoEntity* p_entity);
|
MxResult StartEntityAction(MxDSAction& p_dsAction, LegoEntity* p_entity);
|
||||||
MxResult FUN_10060dc0(
|
MxResult StartManagedAnimation(
|
||||||
MxU32 p_objectId,
|
MxU32 p_objectId,
|
||||||
MxMatrix* p_matrix,
|
MxMatrix* p_matrix,
|
||||||
MxBool p_param3,
|
MxBool p_param3,
|
||||||
@ -184,17 +184,17 @@ class LegoAnimationManager : public MxCore {
|
|||||||
MxBool p_param9
|
MxBool p_param9
|
||||||
);
|
);
|
||||||
void CameraTriggerFire(LegoPathActor* p_actor, MxBool, MxU32 p_location, MxBool p_bool);
|
void CameraTriggerFire(LegoPathActor* p_actor, MxBool, MxU32 p_location, MxBool p_bool);
|
||||||
void FUN_10061010(MxBool p_und);
|
void StopAnimations(MxBool p_und);
|
||||||
LegoTranInfo* GetTranInfo(MxU32 p_index);
|
LegoTranInfo* GetTranInfo(MxU32 p_index);
|
||||||
void FUN_10062770();
|
void CacheTransitionSounds();
|
||||||
void PurgeExtra(MxBool p_und);
|
void PurgeExtra(MxBool p_und);
|
||||||
void AddExtra(MxS32 p_location, MxBool p_und);
|
void AddExtra(MxS32 p_location, MxBool p_und);
|
||||||
void FUN_10063270(LegoROIList* p_list, LegoAnimPresenter* p_presenter);
|
void ClaimExtraActorsFromPresenterList(LegoROIList* p_list, LegoAnimPresenter* p_presenter);
|
||||||
void FUN_10063780(LegoROIList* p_list);
|
void StashPresenterActors(LegoROIList* p_list);
|
||||||
MxResult FUN_10064670(Vector3* p_position);
|
MxResult SpawnBricksterAtPoliceStation(Vector3* p_position);
|
||||||
MxResult FUN_10064740(Vector3* p_position);
|
MxResult SpawnParentsAtHospital(Vector3* p_position);
|
||||||
MxResult FUN_10064880(const char* p_name, MxS32 p_unk0x0c, MxS32 p_unk0x10);
|
MxResult SetExtraActorTiming(const char* p_name, MxS32 p_unk0x0c, MxS32 p_unk0x10);
|
||||||
MxBool FUN_10064ee0(MxU32 p_objectId);
|
MxBool IsAnimationFinished(MxU32 p_objectId);
|
||||||
|
|
||||||
static void configureLegoAnimationManager(MxS32 p_legoAnimationManagerConfig);
|
static void configureLegoAnimationManager(MxS32 p_legoAnimationManagerConfig);
|
||||||
|
|
||||||
@ -203,7 +203,7 @@ class LegoAnimationManager : public MxCore {
|
|||||||
|
|
||||||
private:
|
private:
|
||||||
void Init();
|
void Init();
|
||||||
MxResult FUN_100605e0(
|
MxResult StartAnimationByIndex(
|
||||||
MxU32 p_index,
|
MxU32 p_index,
|
||||||
MxBool p_unk0x0a,
|
MxBool p_unk0x0a,
|
||||||
MxMatrix* p_matrix,
|
MxMatrix* p_matrix,
|
||||||
@ -214,11 +214,11 @@ class LegoAnimationManager : public MxCore {
|
|||||||
MxBool p_bool4,
|
MxBool p_bool4,
|
||||||
MxBool p_bool5
|
MxBool p_bool5
|
||||||
);
|
);
|
||||||
MxResult FUN_100609f0(MxU32 p_objectId, MxMatrix* p_matrix, MxBool p_und1, MxBool p_und2);
|
MxResult StartRawObjectAnimation(MxU32 p_objectId, MxMatrix* p_matrix, MxBool p_und1, MxBool p_und2);
|
||||||
void DeleteAnimations();
|
void DeleteAnimations();
|
||||||
void FUN_10061530();
|
void StopDeferredAnimations();
|
||||||
MxResult FUN_100617c0(MxS32 p_unk0x08, MxU16& p_unk0x0e, MxU16& p_unk0x10);
|
MxResult GetAnimationRangeByLocation(MxS32 p_unk0x08, MxU16& p_unk0x0e, MxU16& p_unk0x10);
|
||||||
MxU16 FUN_10062110(
|
MxU16 FindAmbientAnimationForExtra(
|
||||||
LegoROI* p_roi,
|
LegoROI* p_roi,
|
||||||
Vector3& p_direction,
|
Vector3& p_direction,
|
||||||
Vector3& p_position,
|
Vector3& p_position,
|
||||||
@ -228,21 +228,21 @@ class LegoAnimationManager : public MxCore {
|
|||||||
MxBool p_unk0x14
|
MxBool p_unk0x14
|
||||||
);
|
);
|
||||||
MxS8 GetCharacterIndex(const char* p_name);
|
MxS8 GetCharacterIndex(const char* p_name);
|
||||||
MxBool FUN_100623a0(AnimInfo& p_info);
|
MxBool IsAnimationBlockedByVisibleActor(AnimInfo& p_info);
|
||||||
MxBool ModelExists(AnimInfo& p_info, const char* p_name);
|
MxBool ModelExists(AnimInfo& p_info, const char* p_name);
|
||||||
void FUN_10062580(AnimInfo& p_info);
|
void DetachActorsUsedByAnimation(AnimInfo& p_info);
|
||||||
MxBool FUN_10062650(Mx3DPointFloat& p_position, float p_und, LegoROI* p_roi);
|
MxBool IsROIWithinSphere(Mx3DPointFloat& p_position, float p_und, LegoROI* p_roi);
|
||||||
MxBool FUN_10062710(AnimInfo& p_info);
|
MxBool IsAnimationRejectedForPlayer(AnimInfo& p_info);
|
||||||
MxBool FUN_10062e20(LegoROI* p_roi, LegoAnimPresenter* p_presenter);
|
MxBool PromoteROIToExtraActor(LegoROI* p_roi, LegoAnimPresenter* p_presenter);
|
||||||
void FUN_10063950(LegoROI* p_roi);
|
void ReleaseStashedActor(LegoROI* p_roi);
|
||||||
void FUN_10063aa0();
|
void ReleaseAllStashedActors();
|
||||||
MxBool FUN_10063b90(LegoWorld* p_world, LegoExtraActor* p_actor, MxU8 p_mood, MxU32 p_characterId);
|
MxBool BuildExtraActorCycles(LegoWorld* p_world, LegoExtraActor* p_actor, MxU8 p_mood, MxU32 p_characterId);
|
||||||
void FUN_10063d10();
|
void UpdateExtraActorSpeeds();
|
||||||
void FUN_10063e40(LegoAnimPresenter* p_presenter);
|
void FlushStashedActorsToWorld(LegoAnimPresenter* p_presenter);
|
||||||
MxBool FUN_10063fb0(LegoLocation::Boundary* p_boundary, LegoWorld* p_world);
|
MxBool IsLocationBoundarySpawnable(LegoLocation::Boundary* p_boundary, LegoWorld* p_world);
|
||||||
MxBool FUN_10064010(LegoPathBoundary* p_boundary, LegoOrientedEdge* p_edge, float p_destScale);
|
MxBool IsEdgeSpawnPointOffscreen(LegoPathBoundary* p_boundary, LegoOrientedEdge* p_edge, float p_destScale);
|
||||||
MxBool FUN_10064120(LegoLocation::Boundary* p_boundary, MxBool p_bool1, MxBool p_bool2);
|
MxBool FindRandomSpawnBoundary(LegoLocation::Boundary* p_boundary, MxBool p_bool1, MxBool p_bool2);
|
||||||
MxResult FUN_10064380(
|
MxResult PlaceNamedExtraActor(
|
||||||
const char* p_name,
|
const char* p_name,
|
||||||
const char* p_boundaryName,
|
const char* p_boundaryName,
|
||||||
MxS32 p_src,
|
MxS32 p_src,
|
||||||
@ -255,8 +255,8 @@ class LegoAnimationManager : public MxCore {
|
|||||||
MxS32 p_unk0x10,
|
MxS32 p_unk0x10,
|
||||||
float p_speed
|
float p_speed
|
||||||
);
|
);
|
||||||
void FUN_100648f0(LegoTranInfo* p_tranInfo, MxLong p_unk0x404);
|
void BeginAnimationCameraTransition(LegoTranInfo* p_tranInfo, MxLong p_unk0x404);
|
||||||
void FUN_10064b50(MxLong p_time);
|
void UpdateAnimationCameraTransition(MxLong p_time);
|
||||||
|
|
||||||
LegoOmni::World m_worldId; // 0x08
|
LegoOmni::World m_worldId; // 0x08
|
||||||
MxU16 m_animCount; // 0x0c
|
MxU16 m_animCount; // 0x0c
|
||||||
|
|||||||
@ -65,23 +65,23 @@ class LegoAnimMMPresenter : public MxCompositePresenter {
|
|||||||
|
|
||||||
// SYNTHETIC: LEGO1 0x1004aa40
|
// SYNTHETIC: LEGO1 0x1004aa40
|
||||||
// LegoAnimMMPresenter::`scalar deleting destructor'
|
// LegoAnimMMPresenter::`scalar deleting destructor'
|
||||||
MxBool FUN_1004b830();
|
MxBool HasPassedPresenterStart();
|
||||||
void FUN_1004b840();
|
void StopAndFinishAnimation();
|
||||||
MxBool FUN_1004b8b0();
|
MxBool UsesLocalActors();
|
||||||
void FUN_1004b8c0();
|
void ReleaseUserActor();
|
||||||
|
|
||||||
LegoAnimPresenter* GetPresenter() { return m_presenter; }
|
LegoAnimPresenter* GetPresenter() { return m_presenter; }
|
||||||
|
|
||||||
private:
|
private:
|
||||||
MxBool FUN_1004b450();
|
MxBool RunStartupSequence();
|
||||||
MxBool FUN_1004b530(MxLong p_time);
|
MxBool CaptureAnimationState(MxLong p_time);
|
||||||
MxBool FUN_1004b570(MxLong p_time);
|
MxBool WaitForPreRoll(MxLong p_time);
|
||||||
MxBool FUN_1004b580(MxLong p_time);
|
MxBool WaitForTransitionSound(MxLong p_time);
|
||||||
MxBool FUN_1004b5b0(MxLong p_time);
|
MxBool RestoreInitialTransforms(MxLong p_time);
|
||||||
MxBool FUN_1004b600(MxLong p_time);
|
MxBool PreparePresentersForStart(MxLong p_time);
|
||||||
MxBool FUN_1004b610(MxLong p_time);
|
MxBool StartChildPresenters(MxLong p_time);
|
||||||
MxBool FUN_1004b6b0(MxLong p_time);
|
MxBool WaitForAnimationPresenterIdle(MxLong p_time);
|
||||||
MxBool FUN_1004b6d0(MxLong p_time);
|
MxBool RestoreUserActorAfterAnimation(MxLong p_time);
|
||||||
|
|
||||||
LegoAnimPresenter* m_presenter; // 0x4c
|
LegoAnimPresenter* m_presenter; // 0x4c
|
||||||
MxLong m_unk0x50; // 0x50
|
MxLong m_unk0x50; // 0x50
|
||||||
|
|||||||
@ -37,7 +37,7 @@ class LegoCacheSound : public MxCore {
|
|||||||
MxU32 p_dataSize
|
MxU32 p_dataSize
|
||||||
); // vtable+0x14
|
); // vtable+0x14
|
||||||
virtual void Destroy(); // vtable+0x18
|
virtual void Destroy(); // vtable+0x18
|
||||||
virtual void FUN_10006cd0(undefined4, undefined4); // vtable+0x1c
|
virtual void HandleSoundCallback(undefined4, undefined4); // vtable+0x1c
|
||||||
|
|
||||||
const MxString& GetUnknown0x48() const { return m_unk0x48; }
|
const MxString& GetUnknown0x48() const { return m_unk0x48; }
|
||||||
const MxBool GetUnknown0x58() const { return m_unk0x58; }
|
const MxBool GetUnknown0x58() const { return m_unk0x58; }
|
||||||
@ -45,7 +45,7 @@ class LegoCacheSound : public MxCore {
|
|||||||
LegoCacheSound* Clone();
|
LegoCacheSound* Clone();
|
||||||
MxResult Play(const char* p_name, MxBool p_looping);
|
MxResult Play(const char* p_name, MxBool p_looping);
|
||||||
void Stop();
|
void Stop();
|
||||||
void FUN_10006be0();
|
void UpdatePlayback();
|
||||||
void SetDistance(MxS32 p_min, MxS32 p_max);
|
void SetDistance(MxS32 p_min, MxS32 p_max);
|
||||||
void MuteSilence(MxBool p_muted);
|
void MuteSilence(MxBool p_muted);
|
||||||
void MuteStop(MxBool p_mute);
|
void MuteStop(MxBool p_mute);
|
||||||
|
|||||||
@ -91,7 +91,7 @@ class LegoCharacterManager {
|
|||||||
MxU8 GetMood(LegoROI* p_roi);
|
MxU8 GetMood(LegoROI* p_roi);
|
||||||
LegoROI* CreateAutoROI(const char* p_name, const char* p_lodName, MxBool p_createEntity);
|
LegoROI* CreateAutoROI(const char* p_name, const char* p_lodName, MxBool p_createEntity);
|
||||||
MxResult UpdateBoundingSphereAndBox(LegoROI* p_roi);
|
MxResult UpdateBoundingSphereAndBox(LegoROI* p_roi);
|
||||||
LegoROI* FUN_10085a80(const char* p_name, const char* p_lodName, MxBool p_createEntity);
|
LegoROI* CreateAutoROIWrapper(const char* p_name, const char* p_lodName, MxBool p_createEntity);
|
||||||
|
|
||||||
static const char* GetCustomizeAnimFile() { return g_customizeAnimFile; }
|
static const char* GetCustomizeAnimFile() { return g_customizeAnimFile; }
|
||||||
|
|
||||||
|
|||||||
@ -133,7 +133,7 @@ class LegoInputManager : public MxPresenter {
|
|||||||
|
|
||||||
void ProcessEvents();
|
void ProcessEvents();
|
||||||
MxBool ProcessOneEvent(LegoEventNotificationParam& p_param);
|
MxBool ProcessOneEvent(LegoEventNotificationParam& p_param);
|
||||||
MxBool FUN_1005cdf0(LegoEventNotificationParam& p_param);
|
MxBool TranslateMouseEventToClickOrDrag(LegoEventNotificationParam& p_param);
|
||||||
void GetKeyboardState();
|
void GetKeyboardState();
|
||||||
MxResult GetNavigationKeyStates(MxU32& p_keyFlags);
|
MxResult GetNavigationKeyStates(MxU32& p_keyFlags);
|
||||||
|
|
||||||
|
|||||||
@ -38,7 +38,7 @@ class LegoRaceActor : public virtual LegoAnimActor {
|
|||||||
MxU32 StepState(float p_time, Matrix4& p_matrix) override; // vtable+0x90
|
MxU32 StepState(float p_time, Matrix4& p_matrix) override; // vtable+0x90
|
||||||
MxResult HitActor(LegoPathActor* p_actor, MxBool p_bool) override; // vtable+0x94
|
MxResult HitActor(LegoPathActor* p_actor, MxBool p_bool) override; // vtable+0x94
|
||||||
|
|
||||||
virtual MxResult FUN_10014aa0();
|
virtual MxResult OnRaceActorAction();
|
||||||
|
|
||||||
// SYNTHETIC: LEGO1 0x10012c10
|
// SYNTHETIC: LEGO1 0x10012c10
|
||||||
// LegoRaceActor::`vbase destructor'
|
// LegoRaceActor::`vbase destructor'
|
||||||
|
|||||||
@ -50,7 +50,7 @@ class LegoVideoManager : public MxVideoManager {
|
|||||||
MxResult ResetPalette(MxBool p_ignoreSkyColor);
|
MxResult ResetPalette(MxBool p_ignoreSkyColor);
|
||||||
MxPresenter* GetPresenterByActionObjectName(const char* p_char);
|
MxPresenter* GetPresenterByActionObjectName(const char* p_char);
|
||||||
|
|
||||||
void FUN_1007c520();
|
void PrepareCreditsScreen();
|
||||||
|
|
||||||
Tgl::Renderer* GetRenderer() { return m_renderer; }
|
Tgl::Renderer* GetRenderer() { return m_renderer; }
|
||||||
|
|
||||||
|
|||||||
@ -17,7 +17,7 @@ class RaceSkel : public LegoAnimActor {
|
|||||||
|
|
||||||
MxResult AnimateWithTransform(float p_time, Matrix4& p_transform) override;
|
MxResult AnimateWithTransform(float p_time, Matrix4& p_transform) override;
|
||||||
|
|
||||||
virtual void FUN_10071c80(Vector3& p_vec);
|
virtual void GetFixedRaceSkeletonPosition(Vector3& p_vec);
|
||||||
|
|
||||||
void GetCurrentAnimData(float* p_outCurAnimPosition, float* p_outCurAnimDuration);
|
void GetCurrentAnimData(float* p_outCurAnimPosition, float* p_outCurAnimDuration);
|
||||||
|
|
||||||
|
|||||||
@ -200,7 +200,7 @@ MxResult Act3Cop::HitActor(LegoPathActor* p_actor, MxBool p_bool)
|
|||||||
|
|
||||||
assert(SoundManager()->GetCacheSoundManager());
|
assert(SoundManager()->GetCacheSoundManager());
|
||||||
SoundManager()->GetCacheSoundManager()->Play("eatdn", NULL, FALSE);
|
SoundManager()->GetCacheSoundManager()->Play("eatdn", NULL, FALSE);
|
||||||
FUN_10040360();
|
ChooseCopDestination();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (((Act3*) m_world)->m_brickster->GetROI() != roi) {
|
if (((Act3*) m_world)->m_brickster->GetROI() != roi) {
|
||||||
@ -304,26 +304,26 @@ void Act3Cop::Animate(float p_time)
|
|||||||
|
|
||||||
if (distance < 25.0f) {
|
if (distance < 25.0f) {
|
||||||
brickster->SetActorState(c_disabled);
|
brickster->SetActorState(c_disabled);
|
||||||
FUN_10040360();
|
ChooseCopDestination();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_grec == NULL) {
|
if (m_grec == NULL) {
|
||||||
FUN_10040360();
|
ChooseCopDestination();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10040350
|
// FUNCTION: LEGO1 0x10040350
|
||||||
// FUNCTION: BETA10 0x10018c4a
|
// FUNCTION: BETA10 0x10018c4a
|
||||||
MxResult Act3Cop::FUN_10040350(Act3Ammo& p_ammo, const Vector3&)
|
MxResult Act3Cop::RespondToAmmoHit(Act3Ammo& p_ammo, const Vector3&)
|
||||||
{
|
{
|
||||||
return FUN_10040360();
|
return ChooseCopDestination();
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10040360
|
// FUNCTION: LEGO1 0x10040360
|
||||||
// FUNCTION: BETA10 0x10018c6a
|
// FUNCTION: BETA10 0x10018c6a
|
||||||
MxResult Act3Cop::FUN_10040360()
|
MxResult Act3Cop::ChooseCopDestination()
|
||||||
{
|
{
|
||||||
LegoPathEdgeContainer* grec = NULL;
|
LegoPathEdgeContainer* grec = NULL;
|
||||||
Act3* a3 = (Act3*) m_world;
|
Act3* a3 = (Act3*) m_world;
|
||||||
@ -514,7 +514,7 @@ MxResult Act3Cop::CalculateSpline()
|
|||||||
delete m_grec;
|
delete m_grec;
|
||||||
m_grec = NULL;
|
m_grec = NULL;
|
||||||
m_transformTime = Timer()->GetTime();
|
m_transformTime = Timer()->GetTime();
|
||||||
FUN_10040360();
|
ChooseCopDestination();
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -585,7 +585,7 @@ void Act3Brickster::Animate(float p_time)
|
|||||||
|
|
||||||
switch (m_unk0x38) {
|
switch (m_unk0x38) {
|
||||||
case 1:
|
case 1:
|
||||||
FUN_100417c0();
|
ChooseBricksterDestination();
|
||||||
break;
|
break;
|
||||||
case 2:
|
case 2:
|
||||||
m_unk0x58++;
|
m_unk0x58++;
|
||||||
@ -601,7 +601,7 @@ void Act3Brickster::Animate(float p_time)
|
|||||||
SoundManager()->GetCacheSoundManager()->Play("eatpz", NULL, FALSE);
|
SoundManager()->GetCacheSoundManager()->Play("eatpz", NULL, FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_100417c0();
|
ChooseBricksterDestination();
|
||||||
break;
|
break;
|
||||||
case 3:
|
case 3:
|
||||||
assert(m_shootAnim && m_pInfo);
|
assert(m_shootAnim && m_pInfo);
|
||||||
@ -614,7 +614,7 @@ void Act3Brickster::Animate(float p_time)
|
|||||||
assert(SoundManager()->GetCacheSoundManager());
|
assert(SoundManager()->GetCacheSoundManager());
|
||||||
SoundManager()->GetCacheSoundManager()->Play("thpt", NULL, FALSE);
|
SoundManager()->GetCacheSoundManager()->Play("thpt", NULL, FALSE);
|
||||||
m_unk0x58 = 0;
|
m_unk0x58 = 0;
|
||||||
FUN_100417c0();
|
ChooseBricksterDestination();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
MxMatrix local70;
|
MxMatrix local70;
|
||||||
@ -659,7 +659,7 @@ void Act3Brickster::Animate(float p_time)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_100417c0();
|
ChooseBricksterDestination();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
MxMatrix locale4;
|
MxMatrix locale4;
|
||||||
@ -700,7 +700,7 @@ void Act3Brickster::Animate(float p_time)
|
|||||||
SoundManager()->GetCacheSoundManager()->Play("xarrow", NULL, FALSE);
|
SoundManager()->GetCacheSoundManager()->Play("xarrow", NULL, FALSE);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
FUN_10042300();
|
EvadeNearestCop();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 6:
|
case 6:
|
||||||
@ -714,12 +714,12 @@ void Act3Brickster::Animate(float p_time)
|
|||||||
m_unk0x3c = m_bInfo->m_entity->GetROI()->GetLocal2World()[3];
|
m_unk0x3c = m_bInfo->m_entity->GetROI()->GetLocal2World()[3];
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
FUN_10042300();
|
EvadeNearestCop();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
case 7:
|
case 7:
|
||||||
default:
|
default:
|
||||||
FUN_10042300();
|
EvadeNearestCop();
|
||||||
break;
|
break;
|
||||||
case 8:
|
case 8:
|
||||||
m_unk0x24 = p_time + 10000.0f;
|
m_unk0x24 = p_time + 10000.0f;
|
||||||
@ -727,10 +727,10 @@ void Act3Brickster::Animate(float p_time)
|
|||||||
break;
|
break;
|
||||||
case 9:
|
case 9:
|
||||||
if (m_unk0x24 < p_time) {
|
if (m_unk0x24 < p_time) {
|
||||||
FUN_100417c0();
|
ChooseBricksterDestination();
|
||||||
}
|
}
|
||||||
else if (m_unk0x24 - 9000.0f < p_time) {
|
else if (m_unk0x24 - 9000.0f < p_time) {
|
||||||
FUN_10042300();
|
EvadeNearestCop();
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@ -774,10 +774,10 @@ MxResult Act3Brickster::HitActor(LegoPathActor* p_actor, MxBool p_bool)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100417a0
|
// FUNCTION: LEGO1 0x100417a0
|
||||||
// FUNCTION: BETA10 0x1001a3cf
|
// FUNCTION: BETA10 0x1001a3cf
|
||||||
MxResult Act3Brickster::FUN_100417a0(Act3Ammo& p_ammo, const Vector3&)
|
MxResult Act3Brickster::RespondToAmmoHit(Act3Ammo& p_ammo, const Vector3&)
|
||||||
{
|
{
|
||||||
if (m_unk0x58 < 8) {
|
if (m_unk0x58 < 8) {
|
||||||
return FUN_100417c0();
|
return ChooseBricksterDestination();
|
||||||
}
|
}
|
||||||
|
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
@ -785,7 +785,7 @@ MxResult Act3Brickster::FUN_100417a0(Act3Ammo& p_ammo, const Vector3&)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100417c0
|
// FUNCTION: LEGO1 0x100417c0
|
||||||
// FUNCTION: BETA10 0x1001a407
|
// FUNCTION: BETA10 0x1001a407
|
||||||
MxResult Act3Brickster::FUN_100417c0()
|
MxResult Act3Brickster::ChooseBricksterDestination()
|
||||||
{
|
{
|
||||||
m_pInfo = NULL;
|
m_pInfo = NULL;
|
||||||
m_bInfo = NULL;
|
m_bInfo = NULL;
|
||||||
@ -1010,7 +1010,7 @@ MxResult Act3Brickster::FUN_100417c0()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10042300
|
// FUNCTION: LEGO1 0x10042300
|
||||||
// FUNCTION: BETA10 0x1001b017
|
// FUNCTION: BETA10 0x1001b017
|
||||||
MxS32 Act3Brickster::FUN_10042300()
|
MxS32 Act3Brickster::EvadeNearestCop()
|
||||||
{
|
{
|
||||||
Act3* a3 = (Act3*) m_world;
|
Act3* a3 = (Act3*) m_world;
|
||||||
|
|
||||||
@ -1058,7 +1058,7 @@ MxS32 Act3Brickster::FUN_10042300()
|
|||||||
LegoOrientedEdge* maxE = NULL;
|
LegoOrientedEdge* maxE = NULL;
|
||||||
boundaries[0] = m_boundary;
|
boundaries[0] = m_boundary;
|
||||||
|
|
||||||
if (m_destEdge->FUN_10048c40(local38)) {
|
if (m_destEdge->ContainsPointOnEdge(local38)) {
|
||||||
boundaries[1] = (LegoPathBoundary*) m_destEdge->OtherFace(m_boundary);
|
boundaries[1] = (LegoPathBoundary*) m_destEdge->OtherFace(m_boundary);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|||||||
@ -437,7 +437,7 @@ void Act3Ammo::Animate(float p_time)
|
|||||||
#else
|
#else
|
||||||
if (m_world->m_pizzas[index].IsValid() && !m_world->m_pizzas[index].IsSharkFood()) {
|
if (m_world->m_pizzas[index].IsValid() && !m_world->m_pizzas[index].IsSharkFood()) {
|
||||||
m_world->EatPizza(index);
|
m_world->EatPizza(index);
|
||||||
m_world->m_brickster->FUN_100417c0();
|
m_world->m_brickster->ChooseBricksterDestination();
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
|||||||
@ -581,7 +581,7 @@ void Ambulance::Reset()
|
|||||||
m_atPoliceTask = 0;
|
m_atPoliceTask = 0;
|
||||||
g_isleFlags |= Isle::c_playMusic;
|
g_isleFlags |= Isle::c_playMusic;
|
||||||
AnimationManager()->EnableCamAnims(TRUE);
|
AnimationManager()->EnableCamAnims(TRUE);
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
m_state->m_startTime = INT_MIN;
|
m_state->m_startTime = INT_MIN;
|
||||||
m_state = NULL;
|
m_state = NULL;
|
||||||
}
|
}
|
||||||
@ -591,7 +591,7 @@ void Ambulance::Reset()
|
|||||||
void Ambulance::PlayAnimation(IsleScript::Script p_objectId)
|
void Ambulance::PlayAnimation(IsleScript::Script p_objectId)
|
||||||
{
|
{
|
||||||
AnimationManager()
|
AnimationManager()
|
||||||
->FUN_10060dc0(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, FALSE, FALSE, TRUE);
|
->StartManagedAnimation(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, FALSE, FALSE, TRUE);
|
||||||
m_lastAnimation = p_objectId;
|
m_lastAnimation = p_objectId;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -600,7 +600,7 @@ void Ambulance::PlayAnimation(IsleScript::Script p_objectId)
|
|||||||
void Ambulance::PlayFinalAnimation(IsleScript::Script p_objectId)
|
void Ambulance::PlayFinalAnimation(IsleScript::Script p_objectId)
|
||||||
{
|
{
|
||||||
AnimationManager()
|
AnimationManager()
|
||||||
->FUN_10060dc0(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk1, NULL, FALSE, FALSE, TRUE, TRUE);
|
->StartManagedAnimation(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk1, NULL, FALSE, FALSE, TRUE, TRUE);
|
||||||
m_lastAnimation = p_objectId;
|
m_lastAnimation = p_objectId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -68,8 +68,8 @@ MxLong Bike::HandleClick()
|
|||||||
GetCurrentAction().SetObjectId(-1);
|
GetCurrentAction().SetObjectId(-1);
|
||||||
|
|
||||||
Vector3 position = m_roi->GetWorldPosition();
|
Vector3 position = m_roi->GetWorldPosition();
|
||||||
AnimationManager()->FUN_10064670(&position);
|
AnimationManager()->SpawnBricksterAtPoliceStation(&position);
|
||||||
AnimationManager()->FUN_10064740(&position);
|
AnimationManager()->SpawnParentsAtHospital(&position);
|
||||||
ControlManager()->Register(this);
|
ControlManager()->Register(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -117,7 +117,7 @@ void Bike::ActivateSceneActions()
|
|||||||
MxMatrix mat(UserActor()->GetROI()->GetLocal2World());
|
MxMatrix mat(UserActor()->GetROI()->GetLocal2World());
|
||||||
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.7, mat[2][2] * 2.5);
|
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.7, mat[2][2] * 2.5);
|
||||||
|
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
IsleScript::c_sns006in_RunAnim,
|
IsleScript::c_sns006in_RunAnim,
|
||||||
&mat,
|
&mat,
|
||||||
TRUE,
|
TRUE,
|
||||||
|
|||||||
@ -72,7 +72,7 @@ MxLong InfoCenterEntity::HandleClick(LegoEventNotificationParam& p_param)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
@ -93,7 +93,7 @@ MxLong GasStationEntity::HandleClick(LegoEventNotificationParam& p_param)
|
|||||||
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
||||||
isle->SetDestLocation(LegoGameState::Area::e_garage);
|
isle->SetDestLocation(LegoGameState::Area::e_garage);
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -117,7 +117,7 @@ MxLong HospitalEntity::HandleClick(LegoEventNotificationParam& p_param)
|
|||||||
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
||||||
isle->SetDestLocation(LegoGameState::Area::e_hospital);
|
isle->SetDestLocation(LegoGameState::Area::e_hospital);
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -141,7 +141,7 @@ MxLong PoliceEntity::HandleClick(LegoEventNotificationParam& p_param)
|
|||||||
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
||||||
isle->SetDestLocation(LegoGameState::Area::e_police);
|
isle->SetDestLocation(LegoGameState::Area::e_police);
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -163,7 +163,7 @@ MxLong BeachHouseEntity::HandleClick(LegoEventNotificationParam& p_param)
|
|||||||
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
||||||
isle->SetDestLocation(LegoGameState::Area::e_jetskibuild);
|
isle->SetDestLocation(LegoGameState::Area::e_jetskibuild);
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -184,7 +184,7 @@ MxLong RaceStandsEntity::HandleClick(LegoEventNotificationParam& p_param)
|
|||||||
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
Isle* isle = (Isle*) FindWorld(*g_isleScript, IsleScript::c__Isle);
|
||||||
isle->SetDestLocation(LegoGameState::Area::e_racecarbuild);
|
isle->SetDestLocation(LegoGameState::Area::e_racecarbuild);
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
TransitionManager()->StartTransition(MxTransitionManager::e_mosaic, 50, FALSE, FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -109,8 +109,8 @@ MxLong DuneBuggy::HandleClick()
|
|||||||
GetCurrentAction().SetObjectId(-1);
|
GetCurrentAction().SetObjectId(-1);
|
||||||
|
|
||||||
Vector3 position = m_roi->GetWorldPosition();
|
Vector3 position = m_roi->GetWorldPosition();
|
||||||
AnimationManager()->FUN_10064670(&position);
|
AnimationManager()->SpawnBricksterAtPoliceStation(&position);
|
||||||
AnimationManager()->FUN_10064740(&position);
|
AnimationManager()->SpawnParentsAtHospital(&position);
|
||||||
Enter();
|
Enter();
|
||||||
ControlManager()->Register(this);
|
ControlManager()->Register(this);
|
||||||
return 1;
|
return 1;
|
||||||
@ -198,7 +198,7 @@ void DuneBuggy::ActivateSceneActions()
|
|||||||
MxMatrix mat(UserActor()->GetROI()->GetLocal2World());
|
MxMatrix mat(UserActor()->GetROI()->GetLocal2World());
|
||||||
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.7, mat[2][2] * 2.5);
|
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.7, mat[2][2] * 2.5);
|
||||||
|
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
IsleScript::c_sns005in_RunAnim,
|
IsleScript::c_sns005in_RunAnim,
|
||||||
&mat,
|
&mat,
|
||||||
TRUE,
|
TRUE,
|
||||||
|
|||||||
@ -113,7 +113,7 @@ void Helicopter::Exit()
|
|||||||
RemoveFromCurrentWorld(m_script, 0x1d);
|
RemoveFromCurrentWorld(m_script, 0x1d);
|
||||||
RemoveFromCurrentWorld(m_script, 0x1e);
|
RemoveFromCurrentWorld(m_script, 0x1e);
|
||||||
RemoveFromCurrentWorld(m_script, 0x1f);
|
RemoveFromCurrentWorld(m_script, 0x1f);
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
ControlManager()->Unregister(this);
|
ControlManager()->Unregister(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -130,7 +130,7 @@ MxLong Helicopter::HandleClick()
|
|||||||
assert(m_world);
|
assert(m_world);
|
||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()->FUN_1005f6d0(FALSE);
|
AnimationManager()->EnableExtras(FALSE);
|
||||||
|
|
||||||
if (UserActor()) {
|
if (UserActor()) {
|
||||||
if (UserActor()->GetActorId() != GameState()->GetActorId()) {
|
if (UserActor()->GetActorId() != GameState()->GetActorId()) {
|
||||||
@ -141,7 +141,7 @@ MxLong Helicopter::HandleClick()
|
|||||||
switch (GameState()->GetCurrentAct()) {
|
switch (GameState()->GetCurrentAct()) {
|
||||||
case LegoGameState::e_act1:
|
case LegoGameState::e_act1:
|
||||||
m_script = *g_isleScript;
|
m_script = *g_isleScript;
|
||||||
AnimationManager()->FUN_10064670(NULL);
|
AnimationManager()->SpawnBricksterAtPoliceStation(NULL);
|
||||||
SpawnPlayer(
|
SpawnPlayer(
|
||||||
LegoGameState::e_helicopterLanded,
|
LegoGameState::e_helicopterLanded,
|
||||||
TRUE,
|
TRUE,
|
||||||
@ -445,7 +445,7 @@ void Helicopter::Animate(float p_time)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100042a0
|
// FUNCTION: LEGO1 0x100042a0
|
||||||
void Helicopter::FUN_100042a0(const Matrix4& p_matrix)
|
void Helicopter::PrepareEndingFlightTransform(const Matrix4& p_matrix)
|
||||||
{
|
{
|
||||||
MxMatrix local48;
|
MxMatrix local48;
|
||||||
MxMatrix local90;
|
MxMatrix local90;
|
||||||
@ -489,19 +489,19 @@ void Helicopter::FUN_100042a0(const Matrix4& p_matrix)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10004640
|
// FUNCTION: LEGO1 0x10004640
|
||||||
void Helicopter::FUN_10004640(const Matrix4& p_matrix)
|
void Helicopter::StartGoodEndingFlight(const Matrix4& p_matrix)
|
||||||
{
|
{
|
||||||
if (m_state->m_unk0x08 != 4 && m_state->m_unk0x08 != 5) {
|
if (m_state->m_unk0x08 != 4 && m_state->m_unk0x08 != 5) {
|
||||||
m_state->m_unk0x08 = 4;
|
m_state->m_unk0x08 = 4;
|
||||||
FUN_100042a0(p_matrix);
|
PrepareEndingFlightTransform(p_matrix);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10004670
|
// FUNCTION: LEGO1 0x10004670
|
||||||
void Helicopter::FUN_10004670(const Matrix4& p_matrix)
|
void Helicopter::StartBadEndingFlight(const Matrix4& p_matrix)
|
||||||
{
|
{
|
||||||
if (m_state->m_unk0x08 != 4 && m_state->m_unk0x08 != 5) {
|
if (m_state->m_unk0x08 != 4 && m_state->m_unk0x08 != 5) {
|
||||||
m_state->m_unk0x08 = 5;
|
m_state->m_unk0x08 = 5;
|
||||||
FUN_100042a0(p_matrix);
|
PrepareEndingFlightTransform(p_matrix);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -84,7 +84,7 @@ void IslePathActor::Enter()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
if (!m_cameraFlag) {
|
if (!m_cameraFlag) {
|
||||||
ResetWorldTransform(TRUE);
|
ResetWorldTransform(TRUE);
|
||||||
SetUserNavFlag(TRUE);
|
SetUserNavFlag(TRUE);
|
||||||
@ -585,7 +585,7 @@ void IslePathActor::SpawnPlayer(LegoGameState::Area p_area, MxBool p_enter, MxU8
|
|||||||
|
|
||||||
if (state != NULL && state->m_finishedBuild && !state->m_playedExitScript) {
|
if (state != NULL && state->m_finishedBuild && !state->m_playedExitScript) {
|
||||||
if (AnimationManager()
|
if (AnimationManager()
|
||||||
->FUN_10060dc0(anim, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, TRUE, TRUE, TRUE) ==
|
->StartManagedAnimation(anim, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, TRUE, TRUE, TRUE) ==
|
||||||
SUCCESS) {
|
SUCCESS) {
|
||||||
state->m_playedExitScript = TRUE;
|
state->m_playedExitScript = TRUE;
|
||||||
camAnim = FALSE;
|
camAnim = FALSE;
|
||||||
|
|||||||
@ -115,8 +115,8 @@ MxLong Jetski::HandleClick()
|
|||||||
#else
|
#else
|
||||||
GetCurrentAction().SetObjectId(-1);
|
GetCurrentAction().SetObjectId(-1);
|
||||||
|
|
||||||
AnimationManager()->FUN_1005f6d0(FALSE);
|
AnimationManager()->EnableExtras(FALSE);
|
||||||
AnimationManager()->FUN_10064670(NULL);
|
AnimationManager()->SpawnBricksterAtPoliceStation(NULL);
|
||||||
Enter();
|
Enter();
|
||||||
ControlManager()->Register(this);
|
ControlManager()->Register(this);
|
||||||
#endif
|
#endif
|
||||||
@ -174,7 +174,7 @@ void Jetski::ActivateSceneActions()
|
|||||||
MxMatrix mat(user->GetROI()->GetLocal2World());
|
MxMatrix mat(user->GetROI()->GetLocal2World());
|
||||||
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.6, mat[2][2] * 2.5);
|
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.6, mat[2][2] * 2.5);
|
||||||
|
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
IsleScript::c_sjs007in_RunAnim,
|
IsleScript::c_sjs007in_RunAnim,
|
||||||
&mat,
|
&mat,
|
||||||
TRUE,
|
TRUE,
|
||||||
|
|||||||
@ -104,8 +104,8 @@ MxLong Motocycle::HandleClick()
|
|||||||
GetCurrentAction().SetObjectId(-1);
|
GetCurrentAction().SetObjectId(-1);
|
||||||
|
|
||||||
Vector3 position = m_roi->GetWorldPosition();
|
Vector3 position = m_roi->GetWorldPosition();
|
||||||
AnimationManager()->FUN_10064670(&position);
|
AnimationManager()->SpawnBricksterAtPoliceStation(&position);
|
||||||
AnimationManager()->FUN_10064740(&position);
|
AnimationManager()->SpawnParentsAtHospital(&position);
|
||||||
ControlManager()->Register(this);
|
ControlManager()->Register(this);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
@ -157,7 +157,7 @@ void Motocycle::ActivateSceneActions()
|
|||||||
MxMatrix mat(UserActor()->GetROI()->GetLocal2World());
|
MxMatrix mat(UserActor()->GetROI()->GetLocal2World());
|
||||||
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.7, mat[2][2] * 2.5);
|
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.7, mat[2][2] * 2.5);
|
||||||
|
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
IsleScript::c_sns006in_RunAnim,
|
IsleScript::c_sns006in_RunAnim,
|
||||||
&mat,
|
&mat,
|
||||||
TRUE,
|
TRUE,
|
||||||
|
|||||||
@ -179,14 +179,14 @@ void Pizza::CreateState()
|
|||||||
// FUNCTION: BETA10 0x100edb81
|
// FUNCTION: BETA10 0x100edb81
|
||||||
void Pizza::Start(IsleScript::Script p_objectId)
|
void Pizza::Start(IsleScript::Script p_objectId)
|
||||||
{
|
{
|
||||||
AnimationManager()->FUN_10064740(NULL);
|
AnimationManager()->SpawnParentsAtHospital(NULL);
|
||||||
m_mission = m_state->GetMission(GameState()->GetActorId());
|
m_mission = m_state->GetMission(GameState()->GetActorId());
|
||||||
m_state->m_state = PizzaMissionState::e_introduction;
|
m_state->m_state = PizzaMissionState::e_introduction;
|
||||||
m_act1state->m_state = Act1State::e_pizza;
|
m_act1state->m_state = Act1State::e_pizza;
|
||||||
m_mission->m_startTime = INT_MIN;
|
m_mission->m_startTime = INT_MIN;
|
||||||
g_isleFlags &= ~Isle::c_playMusic;
|
g_isleFlags &= ~Isle::c_playMusic;
|
||||||
AnimationManager()->EnableCamAnims(FALSE);
|
AnimationManager()->EnableCamAnims(FALSE);
|
||||||
AnimationManager()->FUN_1005f6d0(FALSE);
|
AnimationManager()->EnableExtras(FALSE);
|
||||||
PlayAction(p_objectId, FALSE);
|
PlayAction(p_objectId, FALSE);
|
||||||
m_speechAction = IsleScript::c_noneIsle;
|
m_speechAction = IsleScript::c_noneIsle;
|
||||||
}
|
}
|
||||||
@ -205,7 +205,7 @@ void Pizza::Reset()
|
|||||||
UserActor()->SetActorState(LegoPathActor::c_initial);
|
UserActor()->SetActorState(LegoPathActor::c_initial);
|
||||||
g_isleFlags |= Isle::c_playMusic;
|
g_isleFlags |= Isle::c_playMusic;
|
||||||
AnimationManager()->EnableCamAnims(TRUE);
|
AnimationManager()->EnableCamAnims(TRUE);
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
m_mission->m_startTime = INT_MIN;
|
m_mission->m_startTime = INT_MIN;
|
||||||
m_mission = NULL;
|
m_mission = NULL;
|
||||||
m_playedLocationAnimation = FALSE;
|
m_playedLocationAnimation = FALSE;
|
||||||
@ -241,7 +241,7 @@ MxLong Pizza::HandleClick()
|
|||||||
m_state->m_state = PizzaMissionState::e_waitAcceptingQuest;
|
m_state->m_state = PizzaMissionState::e_waitAcceptingQuest;
|
||||||
m_mission->m_startTime = Timer()->GetTime();
|
m_mission->m_startTime = Timer()->GetTime();
|
||||||
TickleManager()->RegisterClient(this, 200);
|
TickleManager()->RegisterClient(this, 200);
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (m_state->m_state == PizzaMissionState::e_waitAcceptingQuest) {
|
if (m_state->m_state == PizzaMissionState::e_waitAcceptingQuest) {
|
||||||
@ -430,7 +430,7 @@ MxResult Pizza::Tickle()
|
|||||||
TickleManager()->UnregisterClient(this);
|
TickleManager()->UnregisterClient(this);
|
||||||
m_mission->UpdateScore(LegoState::e_grey);
|
m_mission->UpdateScore(LegoState::e_grey);
|
||||||
m_state->m_state = PizzaMissionState::e_timeoutAcceptingQuest;
|
m_state->m_state = PizzaMissionState::e_timeoutAcceptingQuest;
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
PlayAction(m_mission->GetUnknownFinishAction(), TRUE);
|
PlayAction(m_mission->GetUnknownFinishAction(), TRUE);
|
||||||
MxTrace("Pizza mission: timeout, declining\n");
|
MxTrace("Pizza mission: timeout, declining\n");
|
||||||
}
|
}
|
||||||
@ -587,7 +587,7 @@ void Pizza::PlayAction(MxU32 p_objectId, MxBool p_param7)
|
|||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()
|
AnimationManager()
|
||||||
->FUN_10060dc0(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, p_param7, TRUE, TRUE);
|
->StartManagedAnimation(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, p_param7, TRUE, TRUE);
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10039030
|
// FUNCTION: LEGO1 0x10039030
|
||||||
|
|||||||
@ -76,7 +76,7 @@ MxLong Pizzeria::HandleClick()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
|
|
||||||
Pizza* pizza = (Pizza*) CurrentWorld()->Find(*g_isleScript, IsleScript::c_Pizza_Actor);
|
Pizza* pizza = (Pizza*) CurrentWorld()->Find(*g_isleScript, IsleScript::c_Pizza_Actor);
|
||||||
pizza->Start((IsleScript::Script) m_pizzeriaState->NextAction());
|
pizza->Start((IsleScript::Script) m_pizzeriaState->NextAction());
|
||||||
|
|||||||
@ -100,8 +100,8 @@ MxLong SkateBoard::HandleClick()
|
|||||||
EnableScenePresentation(m_pizzaVisible);
|
EnableScenePresentation(m_pizzaVisible);
|
||||||
|
|
||||||
Vector3 position = m_roi->GetWorldPosition();
|
Vector3 position = m_roi->GetWorldPosition();
|
||||||
AnimationManager()->FUN_10064670(&position);
|
AnimationManager()->SpawnBricksterAtPoliceStation(&position);
|
||||||
AnimationManager()->FUN_10064740(&position);
|
AnimationManager()->SpawnParentsAtHospital(&position);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -157,7 +157,7 @@ void SkateBoard::ActivateSceneActions()
|
|||||||
MxMatrix mat(UserActor()->GetROI()->GetLocal2World());
|
MxMatrix mat(UserActor()->GetROI()->GetLocal2World());
|
||||||
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.2, mat[2][2] * 2.5);
|
mat.TranslateBy(mat[2][0] * 2.5, mat[2][1] + 0.2, mat[2][2] * 2.5);
|
||||||
|
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
IsleScript::c_sns008in_RunAnim,
|
IsleScript::c_sns008in_RunAnim,
|
||||||
&mat,
|
&mat,
|
||||||
TRUE,
|
TRUE,
|
||||||
|
|||||||
@ -218,7 +218,7 @@ MxLong TowTrack::HandleEndAction(MxEndActionNotificationParam& p_param)
|
|||||||
|
|
||||||
m_state->UpdateScore(LegoState::e_red, m_actorId);
|
m_state->UpdateScore(LegoState::e_red, m_actorId);
|
||||||
|
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
g_isleFlags |= Isle::c_playMusic;
|
g_isleFlags |= Isle::c_playMusic;
|
||||||
AnimationManager()->EnableCamAnims(TRUE);
|
AnimationManager()->EnableCamAnims(TRUE);
|
||||||
}
|
}
|
||||||
@ -274,7 +274,7 @@ MxLong TowTrack::HandleEndAction(MxEndActionNotificationParam& p_param)
|
|||||||
}
|
}
|
||||||
else if (objectId == IsleScript::c_wgs098nu_RunAnim || objectId == IsleScript::c_wgs099nu_RunAnim || objectId == IsleScript::c_wgs100nu_RunAnim || objectId == IsleScript::c_wgs101nu_RunAnim || objectId == IsleScript::c_wgs102nu_RunAnim || objectId == IsleScript::c_wgs085nu_RunAnim || objectId == IsleScript::c_wgs086nu_RunAnim || objectId == IsleScript::c_wgs087nu_RunAnim || objectId == IsleScript::c_wgs088nu_RunAnim || objectId == IsleScript::c_wgs089nu_RunAnim || objectId == IsleScript::c_wgs091nu_RunAnim || objectId == IsleScript::c_wgs092nu_RunAnim || objectId == IsleScript::c_wgs093nu_RunAnim || objectId == IsleScript::c_wgs094nu_RunAnim || objectId == IsleScript::c_wgs095nu_RunAnim) {
|
else if (objectId == IsleScript::c_wgs098nu_RunAnim || objectId == IsleScript::c_wgs099nu_RunAnim || objectId == IsleScript::c_wgs100nu_RunAnim || objectId == IsleScript::c_wgs101nu_RunAnim || objectId == IsleScript::c_wgs102nu_RunAnim || objectId == IsleScript::c_wgs085nu_RunAnim || objectId == IsleScript::c_wgs086nu_RunAnim || objectId == IsleScript::c_wgs087nu_RunAnim || objectId == IsleScript::c_wgs088nu_RunAnim || objectId == IsleScript::c_wgs089nu_RunAnim || objectId == IsleScript::c_wgs091nu_RunAnim || objectId == IsleScript::c_wgs092nu_RunAnim || objectId == IsleScript::c_wgs093nu_RunAnim || objectId == IsleScript::c_wgs094nu_RunAnim || objectId == IsleScript::c_wgs095nu_RunAnim) {
|
||||||
((Act1State*) GameState()->GetState("Act1State"))->m_state = Act1State::e_none;
|
((Act1State*) GameState()->GetState("Act1State"))->m_state = Act1State::e_none;
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
g_isleFlags |= Isle::c_playMusic;
|
g_isleFlags |= Isle::c_playMusic;
|
||||||
AnimationManager()->EnableCamAnims(TRUE);
|
AnimationManager()->EnableCamAnims(TRUE);
|
||||||
}
|
}
|
||||||
@ -554,7 +554,7 @@ void TowTrack::Reset()
|
|||||||
m_state->m_state = TowTrackMissionState::e_none;
|
m_state->m_state = TowTrackMissionState::e_none;
|
||||||
g_isleFlags |= Isle::c_playMusic;
|
g_isleFlags |= Isle::c_playMusic;
|
||||||
AnimationManager()->EnableCamAnims(TRUE);
|
AnimationManager()->EnableCamAnims(TRUE);
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
m_state->m_startTime = INT_MIN;
|
m_state->m_startTime = INT_MIN;
|
||||||
m_state->m_takingTooLong = FALSE;
|
m_state->m_takingTooLong = FALSE;
|
||||||
m_state = NULL;
|
m_state = NULL;
|
||||||
@ -567,16 +567,16 @@ void TowTrack::Reset()
|
|||||||
void TowTrack::PlayFinalAnimation(IsleScript::Script p_objectId)
|
void TowTrack::PlayFinalAnimation(IsleScript::Script p_objectId)
|
||||||
{
|
{
|
||||||
AnimationManager()
|
AnimationManager()
|
||||||
->FUN_10060dc0(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, FALSE, FALSE, TRUE);
|
->StartManagedAnimation(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, FALSE, FALSE, TRUE);
|
||||||
m_lastAnimation = p_objectId;
|
m_lastAnimation = p_objectId;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004dcb0
|
// FUNCTION: LEGO1 0x1004dcb0
|
||||||
void TowTrack::PlayActorAnimation(IsleScript::Script p_objectId)
|
void TowTrack::PlayActorAnimation(IsleScript::Script p_objectId)
|
||||||
{
|
{
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
AnimationManager()
|
AnimationManager()
|
||||||
->FUN_10060dc0(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk1, NULL, FALSE, TRUE, TRUE, TRUE);
|
->StartManagedAnimation(p_objectId, NULL, TRUE, LegoAnimationManager::e_unk1, NULL, FALSE, TRUE, TRUE, TRUE);
|
||||||
m_lastAnimation = p_objectId;
|
m_lastAnimation = p_objectId;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -185,7 +185,7 @@ MxU32 Lego3DSound::UpdatePosition(LPDIRECTSOUNDBUFFER p_directSoundBuffer)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10011a60
|
// FUNCTION: LEGO1 0x10011a60
|
||||||
// FUNCTION: BETA10 0x10039d04
|
// FUNCTION: BETA10 0x10039d04
|
||||||
void Lego3DSound::FUN_10011a60(LPDIRECTSOUNDBUFFER p_directSoundBuffer, const char* p_name)
|
void Lego3DSound::AttachToSoundTarget(LPDIRECTSOUNDBUFFER p_directSoundBuffer, const char* p_name)
|
||||||
{
|
{
|
||||||
assert(p_directSoundBuffer);
|
assert(p_directSoundBuffer);
|
||||||
|
|
||||||
|
|||||||
@ -40,7 +40,7 @@ MxResult LegoCacheSoundManager::Tickle()
|
|||||||
#endif
|
#endif
|
||||||
LegoCacheSound* sound = (*setIter).GetSound();
|
LegoCacheSound* sound = (*setIter).GetSound();
|
||||||
if (sound->GetUnknown0x58()) {
|
if (sound->GetUnknown0x58()) {
|
||||||
sound->FUN_10006be0();
|
sound->UpdatePlayback();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -49,7 +49,7 @@ MxResult LegoCacheSoundManager::Tickle()
|
|||||||
LegoCacheSound* sound = (*listIter).GetSound();
|
LegoCacheSound* sound = (*listIter).GetSound();
|
||||||
|
|
||||||
if (sound->GetUnknown0x58()) {
|
if (sound->GetUnknown0x58()) {
|
||||||
sound->FUN_10006be0();
|
sound->UpdatePlayback();
|
||||||
listIter++;
|
listIter++;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|||||||
@ -153,7 +153,7 @@ MxResult LegoCacheSound::Play(const char* p_name, MxBool p_looping)
|
|||||||
}
|
}
|
||||||
|
|
||||||
m_unk0x6a = FALSE;
|
m_unk0x6a = FALSE;
|
||||||
m_sound.FUN_10011a60(m_dsBuffer, p_name);
|
m_sound.AttachToSoundTarget(m_dsBuffer, p_name);
|
||||||
|
|
||||||
if (p_name != NULL) {
|
if (p_name != NULL) {
|
||||||
m_unk0x74 = p_name;
|
m_unk0x74 = p_name;
|
||||||
@ -227,7 +227,7 @@ void LegoCacheSound::Stop()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10006be0
|
// FUNCTION: LEGO1 0x10006be0
|
||||||
// FUNCTION: BETA10 0x10066d23
|
// FUNCTION: BETA10 0x10066d23
|
||||||
void LegoCacheSound::FUN_10006be0()
|
void LegoCacheSound::UpdatePlayback()
|
||||||
{
|
{
|
||||||
if (!m_looping) {
|
if (!m_looping) {
|
||||||
DWORD dwStatus;
|
DWORD dwStatus;
|
||||||
@ -280,7 +280,7 @@ void LegoCacheSound::SetDistance(MxS32 p_min, MxS32 p_max)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10006cd0
|
// FUNCTION: LEGO1 0x10006cd0
|
||||||
// FUNCTION: BETA10 0x10066eb0
|
// FUNCTION: BETA10 0x10066eb0
|
||||||
void LegoCacheSound::FUN_10006cd0(undefined4, undefined4)
|
void LegoCacheSound::HandleSoundCallback(undefined4, undefined4)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -342,7 +342,7 @@ LegoAnimationManager::~LegoAnimationManager()
|
|||||||
{
|
{
|
||||||
TickleManager()->UnregisterClient(this);
|
TickleManager()->UnregisterClient(this);
|
||||||
|
|
||||||
FUN_10061010(FALSE);
|
StopAnimations(FALSE);
|
||||||
|
|
||||||
for (MxS32 i = 0; i < (MxS32) sizeOfArray(m_extras); i++) {
|
for (MxS32 i = 0; i < (MxS32) sizeOfArray(m_extras); i++) {
|
||||||
LegoROI* roi = m_extras[i].m_roi;
|
LegoROI* roi = m_extras[i].m_roi;
|
||||||
@ -370,7 +370,7 @@ LegoAnimationManager::~LegoAnimationManager()
|
|||||||
DeleteAnimations();
|
DeleteAnimations();
|
||||||
|
|
||||||
if (m_unk0x424 != NULL) {
|
if (m_unk0x424 != NULL) {
|
||||||
FUN_10063aa0();
|
ReleaseAllStashedActors();
|
||||||
delete m_unk0x424;
|
delete m_unk0x424;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -427,7 +427,7 @@ void LegoAnimationManager::Suspend()
|
|||||||
m_unk0x42a = m_unk0x402;
|
m_unk0x42a = m_unk0x402;
|
||||||
m_unk0x402 = FALSE;
|
m_unk0x402 = FALSE;
|
||||||
|
|
||||||
FUN_10061010(FALSE);
|
StopAnimations(FALSE);
|
||||||
|
|
||||||
MxS32 i;
|
MxS32 i;
|
||||||
for (i = 0; i < (MxS32) sizeOfArray(m_extras); i++) {
|
for (i = 0; i < (MxS32) sizeOfArray(m_extras); i++) {
|
||||||
@ -544,7 +544,7 @@ void LegoAnimationManager::Init()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (m_unk0x424 != NULL) {
|
if (m_unk0x424 != NULL) {
|
||||||
FUN_10063aa0();
|
ReleaseAllStashedActors();
|
||||||
delete m_unk0x424;
|
delete m_unk0x424;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -553,7 +553,7 @@ void LegoAnimationManager::Init()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1005f6d0
|
// FUNCTION: LEGO1 0x1005f6d0
|
||||||
// FUNCTION: BETA10 0x100401e7
|
// FUNCTION: BETA10 0x100401e7
|
||||||
void LegoAnimationManager::FUN_1005f6d0(MxBool p_unk0x400)
|
void LegoAnimationManager::EnableExtras(MxBool p_unk0x400)
|
||||||
{
|
{
|
||||||
if (m_suspended) {
|
if (m_suspended) {
|
||||||
m_unk0x429 = p_unk0x400;
|
m_unk0x429 = p_unk0x400;
|
||||||
@ -713,7 +713,7 @@ MxResult LegoAnimationManager::LoadWorldInfo(LegoOmni::World p_worldId)
|
|||||||
m_tranInfoList = new LegoTranInfoList();
|
m_tranInfoList = new LegoTranInfoList();
|
||||||
m_tranInfoList2 = new LegoTranInfoList();
|
m_tranInfoList2 = new LegoTranInfoList();
|
||||||
|
|
||||||
FUN_100617c0(-1, m_unk0x0e, m_unk0x10);
|
GetAnimationRangeByLocation(-1, m_unk0x0e, m_unk0x10);
|
||||||
|
|
||||||
result = SUCCESS;
|
result = SUCCESS;
|
||||||
m_unk0x402 = TRUE;
|
m_unk0x402 = TRUE;
|
||||||
@ -881,7 +881,7 @@ void LegoAnimationManager::DeleteAnimations()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10060480
|
// FUNCTION: LEGO1 0x10060480
|
||||||
// FUNCTION: BETA10 0x100412a9
|
// FUNCTION: BETA10 0x100412a9
|
||||||
void LegoAnimationManager::FUN_10060480(const LegoChar* p_characterNames[], MxU32 p_numCharacterNames)
|
void LegoAnimationManager::EnableCharactersByName(const LegoChar* p_characterNames[], MxU32 p_numCharacterNames)
|
||||||
{
|
{
|
||||||
for (MxS32 i = 0; i < p_numCharacterNames; i++) {
|
for (MxS32 i = 0; i < p_numCharacterNames; i++) {
|
||||||
for (MxS32 j = 0; j < sizeOfArray(g_characters); j++) {
|
for (MxS32 j = 0; j < sizeOfArray(g_characters); j++) {
|
||||||
@ -894,7 +894,7 @@ void LegoAnimationManager::FUN_10060480(const LegoChar* p_characterNames[], MxU3
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100604d0
|
// FUNCTION: LEGO1 0x100604d0
|
||||||
// FUNCTION: BETA10 0x10041335
|
// FUNCTION: BETA10 0x10041335
|
||||||
void LegoAnimationManager::FUN_100604d0(MxBool p_unk0x08)
|
void LegoAnimationManager::SetAllCharactersAnimationEnabled(MxBool p_unk0x08)
|
||||||
{
|
{
|
||||||
for (MxS32 i = 0; i < (MxS32) sizeOfArray(g_characters); i++) {
|
for (MxS32 i = 0; i < (MxS32) sizeOfArray(g_characters); i++) {
|
||||||
g_characters[i].m_unk0x08 = p_unk0x08;
|
g_characters[i].m_unk0x08 = p_unk0x08;
|
||||||
@ -903,7 +903,7 @@ void LegoAnimationManager::FUN_100604d0(MxBool p_unk0x08)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100604f0
|
// FUNCTION: LEGO1 0x100604f0
|
||||||
// FUNCTION: BETA10 0x1004137b
|
// FUNCTION: BETA10 0x1004137b
|
||||||
void LegoAnimationManager::FUN_100604f0(MxS32 p_objectIds[], MxU32 p_numObjectIds)
|
void LegoAnimationManager::EnableAnimationsByObjectId(MxS32 p_objectIds[], MxU32 p_numObjectIds)
|
||||||
{
|
{
|
||||||
for (MxS32 i = 0; i < p_numObjectIds; i++) {
|
for (MxS32 i = 0; i < p_numObjectIds; i++) {
|
||||||
for (MxS32 j = 0; j < m_animCount; j++) {
|
for (MxS32 j = 0; j < m_animCount; j++) {
|
||||||
@ -916,7 +916,7 @@ void LegoAnimationManager::FUN_100604f0(MxS32 p_objectIds[], MxU32 p_numObjectId
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10060540
|
// FUNCTION: LEGO1 0x10060540
|
||||||
// FUNCTION: BETA10 0x1004140f
|
// FUNCTION: BETA10 0x1004140f
|
||||||
void LegoAnimationManager::FUN_10060540(MxBool p_unk0x29)
|
void LegoAnimationManager::SetAllAnimationsEnabled(MxBool p_unk0x29)
|
||||||
{
|
{
|
||||||
for (MxS32 i = 0; i < m_animCount; i++) {
|
for (MxS32 i = 0; i < m_animCount; i++) {
|
||||||
m_anims[i].m_unk0x29 = p_unk0x29;
|
m_anims[i].m_unk0x29 = p_unk0x29;
|
||||||
@ -925,7 +925,7 @@ void LegoAnimationManager::FUN_10060540(MxBool p_unk0x29)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10060570
|
// FUNCTION: LEGO1 0x10060570
|
||||||
// FUNCTION: BETA10 0x10041463
|
// FUNCTION: BETA10 0x10041463
|
||||||
void LegoAnimationManager::FUN_10060570(MxBool p_unk0x1a)
|
void LegoAnimationManager::SetAutoPlayAnimations(MxBool p_unk0x1a)
|
||||||
{
|
{
|
||||||
m_animRunning = FALSE;
|
m_animRunning = FALSE;
|
||||||
m_unk0x430 = FALSE;
|
m_unk0x430 = FALSE;
|
||||||
@ -933,7 +933,7 @@ void LegoAnimationManager::FUN_10060570(MxBool p_unk0x1a)
|
|||||||
|
|
||||||
if (m_unk0x1a != p_unk0x1a && (m_unk0x1a = p_unk0x1a)) {
|
if (m_unk0x1a != p_unk0x1a && (m_unk0x1a = p_unk0x1a)) {
|
||||||
do {
|
do {
|
||||||
if (FUN_100605e0(m_unk0x18, TRUE, NULL, TRUE, NULL, FALSE, TRUE, TRUE, TRUE) != FAILURE) {
|
if (StartAnimationByIndex(m_unk0x18, TRUE, NULL, TRUE, NULL, FALSE, TRUE, TRUE, TRUE) != FAILURE) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -947,7 +947,7 @@ void LegoAnimationManager::FUN_10060570(MxBool p_unk0x1a)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100605e0
|
// FUNCTION: LEGO1 0x100605e0
|
||||||
// FUNCTION: BETA10 0x1004152b
|
// FUNCTION: BETA10 0x1004152b
|
||||||
MxResult LegoAnimationManager::FUN_100605e0(
|
MxResult LegoAnimationManager::StartAnimationByIndex(
|
||||||
MxU32 p_index,
|
MxU32 p_index,
|
||||||
MxBool p_unk0x0a,
|
MxBool p_unk0x0a,
|
||||||
MxMatrix* p_matrix,
|
MxMatrix* p_matrix,
|
||||||
@ -963,7 +963,7 @@ MxResult LegoAnimationManager::FUN_100605e0(
|
|||||||
|
|
||||||
if (m_worldId != LegoOmni::e_undefined && p_index < m_animCount && m_tranInfoList != NULL) {
|
if (m_worldId != LegoOmni::e_undefined && p_index < m_animCount && m_tranInfoList != NULL) {
|
||||||
PurgeExtra(FALSE);
|
PurgeExtra(FALSE);
|
||||||
FUN_10062770();
|
CacheTransitionSounds();
|
||||||
|
|
||||||
MxDSAction action;
|
MxDSAction action;
|
||||||
AnimInfo& animInfo = m_anims[p_index];
|
AnimInfo& animInfo = m_anims[p_index];
|
||||||
@ -973,16 +973,16 @@ MxResult LegoAnimationManager::FUN_100605e0(
|
|||||||
return FAILURE;
|
return FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FUN_100623a0(animInfo)) {
|
if (IsAnimationBlockedByVisibleActor(animInfo)) {
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FUN_10062710(animInfo)) {
|
if (IsAnimationRejectedForPlayer(animInfo)) {
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_10062580(animInfo);
|
DetachActorsUsedByAnimation(animInfo);
|
||||||
|
|
||||||
LegoTranInfo* tranInfo = new LegoTranInfo();
|
LegoTranInfo* tranInfo = new LegoTranInfo();
|
||||||
tranInfo->m_animInfo = &animInfo;
|
tranInfo->m_animInfo = &animInfo;
|
||||||
@ -1022,7 +1022,7 @@ MxResult LegoAnimationManager::FUN_100605e0(
|
|||||||
m_unk0x404 = Timer()->GetTime();
|
m_unk0x404 = Timer()->GetTime();
|
||||||
|
|
||||||
if (p_bool5) {
|
if (p_bool5) {
|
||||||
FUN_100648f0(tranInfo, m_unk0x404);
|
BeginAnimationCameraTransition(tranInfo, m_unk0x404);
|
||||||
}
|
}
|
||||||
else if (p_unk0x0a) {
|
else if (p_unk0x0a) {
|
||||||
LegoPathActor* actor = UserActor();
|
LegoPathActor* actor = UserActor();
|
||||||
@ -1043,7 +1043,7 @@ MxResult LegoAnimationManager::FUN_100605e0(
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100609f0
|
// FUNCTION: LEGO1 0x100609f0
|
||||||
// FUNCTION: BETA10 0x10041a38
|
// FUNCTION: BETA10 0x10041a38
|
||||||
MxResult LegoAnimationManager::FUN_100609f0(MxU32 p_objectId, MxMatrix* p_matrix, MxBool p_und1, MxBool p_und2)
|
MxResult LegoAnimationManager::StartRawObjectAnimation(MxU32 p_objectId, MxMatrix* p_matrix, MxBool p_und1, MxBool p_und2)
|
||||||
{
|
{
|
||||||
MxResult result = FAILURE;
|
MxResult result = FAILURE;
|
||||||
MxDSAction action;
|
MxDSAction action;
|
||||||
@ -1063,7 +1063,7 @@ MxResult LegoAnimationManager::FUN_100609f0(MxU32 p_objectId, MxMatrix* p_matrix
|
|||||||
info->m_unk0x0c = new MxMatrix(*p_matrix);
|
info->m_unk0x0c = new MxMatrix(*p_matrix);
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_10062770();
|
CacheTransitionSounds();
|
||||||
|
|
||||||
info->m_unk0x1c = m_unk0x28;
|
info->m_unk0x1c = m_unk0x28;
|
||||||
info->m_unk0x20 = m_unk0x30;
|
info->m_unk0x20 = m_unk0x30;
|
||||||
@ -1134,7 +1134,7 @@ MxResult LegoAnimationManager::StartEntityAction(MxDSAction& p_dsAction, LegoEnt
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10060dc0
|
// FUNCTION: LEGO1 0x10060dc0
|
||||||
// FUNCTION: BETA10 0x10041f2c
|
// FUNCTION: BETA10 0x10041f2c
|
||||||
MxResult LegoAnimationManager::FUN_10060dc0(
|
MxResult LegoAnimationManager::StartManagedAnimation(
|
||||||
MxU32 p_objectId,
|
MxU32 p_objectId,
|
||||||
MxMatrix* p_matrix,
|
MxMatrix* p_matrix,
|
||||||
MxBool p_param3,
|
MxBool p_param3,
|
||||||
@ -1170,13 +1170,13 @@ MxResult LegoAnimationManager::FUN_10060dc0(
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
result = FUN_100605e0(i, unk0x0a, p_matrix, p_param3, p_roi, p_param6, p_param7, p_param8, p_param9);
|
result = StartAnimationByIndex(i, unk0x0a, p_matrix, p_param3, p_roi, p_param6, p_param7, p_param8, p_param9);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!found && p_param3 != FALSE) {
|
if (!found && p_param3 != FALSE) {
|
||||||
result = FUN_100609f0(p_objectId, p_matrix, p_param7, p_param8);
|
result = StartRawObjectAnimation(p_objectId, p_matrix, p_param7, p_param8);
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
@ -1200,7 +1200,7 @@ void LegoAnimationManager::CameraTriggerFire(LegoPathActor* p_actor, MxBool, MxU
|
|||||||
}
|
}
|
||||||
|
|
||||||
MxU16 unk0x0e, unk0x10;
|
MxU16 unk0x0e, unk0x10;
|
||||||
if (FUN_100617c0(p_location, unk0x0e, unk0x10) == SUCCESS) {
|
if (GetAnimationRangeByLocation(p_location, unk0x0e, unk0x10) == SUCCESS) {
|
||||||
MxU16 index = unk0x0e;
|
MxU16 index = unk0x0e;
|
||||||
MxU32 unk0x22 = -1;
|
MxU32 unk0x22 = -1;
|
||||||
MxBool success = FALSE;
|
MxBool success = FALSE;
|
||||||
@ -1208,7 +1208,7 @@ void LegoAnimationManager::CameraTriggerFire(LegoPathActor* p_actor, MxBool, MxU
|
|||||||
for (MxU16 i = unk0x0e; i <= unk0x10; i++) {
|
for (MxU16 i = unk0x0e; i <= unk0x10; i++) {
|
||||||
AnimInfo& animInfo = m_anims[i];
|
AnimInfo& animInfo = m_anims[i];
|
||||||
|
|
||||||
if ((p_bool || !FUN_100623a0(animInfo)) && !FUN_10062710(animInfo) && animInfo.m_unk0x29 &&
|
if ((p_bool || !IsAnimationBlockedByVisibleActor(animInfo)) && !IsAnimationRejectedForPlayer(animInfo) && animInfo.m_unk0x29 &&
|
||||||
animInfo.m_unk0x22 < unk0x22 && (animInfo.m_unk0x22 == 0 || *animInfo.m_name != 'i') &&
|
animInfo.m_unk0x22 < unk0x22 && (animInfo.m_unk0x22 == 0 || *animInfo.m_name != 'i') &&
|
||||||
*animInfo.m_name != 'I') {
|
*animInfo.m_name != 'I') {
|
||||||
index = i;
|
index = i;
|
||||||
@ -1218,7 +1218,7 @@ void LegoAnimationManager::CameraTriggerFire(LegoPathActor* p_actor, MxBool, MxU
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (success) {
|
if (success) {
|
||||||
FUN_100605e0(index, m_anims[index].m_unk0x0a, NULL, TRUE, NULL, FALSE, TRUE, TRUE, TRUE);
|
StartAnimationByIndex(index, m_anims[index].m_unk0x0a, NULL, TRUE, NULL, FALSE, TRUE, TRUE, TRUE);
|
||||||
location->m_unk0x5c = TRUE;
|
location->m_unk0x5c = TRUE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1227,9 +1227,9 @@ void LegoAnimationManager::CameraTriggerFire(LegoPathActor* p_actor, MxBool, MxU
|
|||||||
|
|
||||||
#ifdef BETA10
|
#ifdef BETA10
|
||||||
// FUNCTION: BETA10 0x100422cc
|
// FUNCTION: BETA10 0x100422cc
|
||||||
void LegoAnimationManager::FUN_10061010(MxBool p_und)
|
void LegoAnimationManager::StopAnimations(MxBool p_und)
|
||||||
{
|
{
|
||||||
FUN_10064b50(-1);
|
UpdateAnimationCameraTransition(-1);
|
||||||
|
|
||||||
if (m_tranInfoList != NULL) {
|
if (m_tranInfoList != NULL) {
|
||||||
LegoTranInfoListCursor cursor(m_tranInfoList);
|
LegoTranInfoListCursor cursor(m_tranInfoList);
|
||||||
@ -1240,7 +1240,7 @@ void LegoAnimationManager::FUN_10061010(MxBool p_und)
|
|||||||
MxTrace("Releasing user from %d\n", tranInfo->m_objectId);
|
MxTrace("Releasing user from %d\n", tranInfo->m_objectId);
|
||||||
|
|
||||||
if (tranInfo->m_presenter != NULL) {
|
if (tranInfo->m_presenter != NULL) {
|
||||||
tranInfo->m_presenter->FUN_1004b8c0();
|
tranInfo->m_presenter->ReleaseUserActor();
|
||||||
}
|
}
|
||||||
|
|
||||||
tranInfo->m_unk0x14 = FALSE;
|
tranInfo->m_unk0x14 = FALSE;
|
||||||
@ -1249,7 +1249,7 @@ void LegoAnimationManager::FUN_10061010(MxBool p_und)
|
|||||||
MxTrace("Stopping %d\n", tranInfo->m_objectId);
|
MxTrace("Stopping %d\n", tranInfo->m_objectId);
|
||||||
|
|
||||||
if (tranInfo->m_presenter != NULL) {
|
if (tranInfo->m_presenter != NULL) {
|
||||||
tranInfo->m_presenter->FUN_1004b840();
|
tranInfo->m_presenter->StopAndFinishAnimation();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1260,10 +1260,10 @@ void LegoAnimationManager::FUN_10061010(MxBool p_und)
|
|||||||
}
|
}
|
||||||
#else
|
#else
|
||||||
// FUNCTION: LEGO1 0x10061010
|
// FUNCTION: LEGO1 0x10061010
|
||||||
void LegoAnimationManager::FUN_10061010(MxBool p_und)
|
void LegoAnimationManager::StopAnimations(MxBool p_und)
|
||||||
{
|
{
|
||||||
MxBool animRunning = FALSE;
|
MxBool animRunning = FALSE;
|
||||||
FUN_10064b50(-1);
|
UpdateAnimationCameraTransition(-1);
|
||||||
|
|
||||||
if (m_tranInfoList != NULL) {
|
if (m_tranInfoList != NULL) {
|
||||||
LegoTranInfoListCursor cursor(m_tranInfoList);
|
LegoTranInfoListCursor cursor(m_tranInfoList);
|
||||||
@ -1281,13 +1281,13 @@ void LegoAnimationManager::FUN_10061010(MxBool p_und)
|
|||||||
tranInfo->m_flags &= ~LegoTranInfo::c_bit2;
|
tranInfo->m_flags &= ~LegoTranInfo::c_bit2;
|
||||||
}
|
}
|
||||||
|
|
||||||
tranInfo->m_presenter->FUN_1004b840();
|
tranInfo->m_presenter->StopAndFinishAnimation();
|
||||||
tranInfo->m_unk0x14 = FALSE;
|
tranInfo->m_unk0x14 = FALSE;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
MxTrace("Releasing user from %d\n", tranInfo->m_objectId);
|
MxTrace("Releasing user from %d\n", tranInfo->m_objectId);
|
||||||
// LINE: LEGO1 0x10061137
|
// LINE: LEGO1 0x10061137
|
||||||
tranInfo->m_presenter->FUN_1004b8c0();
|
tranInfo->m_presenter->ReleaseUserActor();
|
||||||
animRunning = TRUE;
|
animRunning = TRUE;
|
||||||
tranInfo->m_unk0x14 = FALSE;
|
tranInfo->m_unk0x14 = FALSE;
|
||||||
}
|
}
|
||||||
@ -1300,7 +1300,7 @@ void LegoAnimationManager::FUN_10061010(MxBool p_und)
|
|||||||
}
|
}
|
||||||
|
|
||||||
MxTrace("Stopping %d\n", tranInfo->m_objectId);
|
MxTrace("Stopping %d\n", tranInfo->m_objectId);
|
||||||
tranInfo->m_presenter->FUN_1004b840();
|
tranInfo->m_presenter->StopAndFinishAnimation();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -1324,7 +1324,7 @@ void LegoAnimationManager::FUN_10061010(MxBool p_und)
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10061530
|
// FUNCTION: LEGO1 0x10061530
|
||||||
void LegoAnimationManager::FUN_10061530()
|
void LegoAnimationManager::StopDeferredAnimations()
|
||||||
{
|
{
|
||||||
if (m_tranInfoList2 != NULL) {
|
if (m_tranInfoList2 != NULL) {
|
||||||
LegoTranInfoListCursor cursor(m_tranInfoList2);
|
LegoTranInfoListCursor cursor(m_tranInfoList2);
|
||||||
@ -1340,7 +1340,7 @@ void LegoAnimationManager::FUN_10061530()
|
|||||||
tranInfo->m_flags &= ~LegoTranInfo::c_bit2;
|
tranInfo->m_flags &= ~LegoTranInfo::c_bit2;
|
||||||
}
|
}
|
||||||
|
|
||||||
tranInfo->m_presenter->FUN_1004b840();
|
tranInfo->m_presenter->StopAndFinishAnimation();
|
||||||
cursor.Detach();
|
cursor.Detach();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -1353,7 +1353,7 @@ void LegoAnimationManager::FUN_10061530()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100617c0
|
// FUNCTION: LEGO1 0x100617c0
|
||||||
// FUNCTION: BETA10 0x1004240b
|
// FUNCTION: BETA10 0x1004240b
|
||||||
MxResult LegoAnimationManager::FUN_100617c0(MxS32 p_location, MxU16& p_unk0x0e, MxU16& p_unk0x10)
|
MxResult LegoAnimationManager::GetAnimationRangeByLocation(MxS32 p_location, MxU16& p_unk0x0e, MxU16& p_unk0x10)
|
||||||
{
|
{
|
||||||
MxResult result = FAILURE;
|
MxResult result = FAILURE;
|
||||||
MxU16 unk0x0e = 0;
|
MxU16 unk0x0e = 0;
|
||||||
@ -1428,7 +1428,7 @@ MxLong LegoAnimationManager::Notify(MxParam& p_param)
|
|||||||
{
|
{
|
||||||
if (((MxNotificationParam&) p_param).GetSender() == this) {
|
if (((MxNotificationParam&) p_param).GetSender() == this) {
|
||||||
if (((MxNotificationParam&) p_param).GetNotification() == c_notificationEndAnim) {
|
if (((MxNotificationParam&) p_param).GetNotification() == c_notificationEndAnim) {
|
||||||
FUN_100605e0(m_unk0x18, TRUE, NULL, TRUE, NULL, FALSE, TRUE, TRUE, TRUE);
|
StartAnimationByIndex(m_unk0x18, TRUE, NULL, TRUE, NULL, FALSE, TRUE, TRUE, TRUE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (((MxNotificationParam&) p_param).GetNotification() == c_notificationEndAnim && m_tranInfoList != NULL) {
|
else if (((MxNotificationParam&) p_param).GetNotification() == c_notificationEndAnim && m_tranInfoList != NULL) {
|
||||||
@ -1441,7 +1441,7 @@ MxLong LegoAnimationManager::Notify(MxParam& p_param)
|
|||||||
while (cursor.Next(tranInfo)) {
|
while (cursor.Next(tranInfo)) {
|
||||||
if (tranInfo->m_index == index) {
|
if (tranInfo->m_index == index) {
|
||||||
if (m_unk0x430 && m_unk0x42c == tranInfo) {
|
if (m_unk0x430 && m_unk0x42c == tranInfo) {
|
||||||
FUN_10064b50(-1);
|
UpdateAnimationCameraTransition(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (tranInfo->m_flags & LegoTranInfo::c_bit2) {
|
if (tranInfo->m_flags & LegoTranInfo::c_bit2) {
|
||||||
@ -1490,7 +1490,7 @@ MxLong LegoAnimationManager::Notify(MxParam& p_param)
|
|||||||
// FUNCTION: BETA10 0x1004293c
|
// FUNCTION: BETA10 0x1004293c
|
||||||
MxResult LegoAnimationManager::Tickle()
|
MxResult LegoAnimationManager::Tickle()
|
||||||
{
|
{
|
||||||
FUN_10061530();
|
StopDeferredAnimations();
|
||||||
|
|
||||||
if (!m_unk0x402) {
|
if (!m_unk0x402) {
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
@ -1546,7 +1546,7 @@ MxResult LegoAnimationManager::Tickle()
|
|||||||
MxLong time = Timer()->GetTime();
|
MxLong time = Timer()->GetTime();
|
||||||
float speed = actor->GetWorldSpeed();
|
float speed = actor->GetWorldSpeed();
|
||||||
|
|
||||||
FUN_10064b50(time);
|
UpdateAnimationCameraTransition(time);
|
||||||
|
|
||||||
if (!m_animRunning && time - m_unk0x404 > 10000 && speed < g_unk0x100f74b0[0][0] && speed > g_unk0x100f74b0[5][0]) {
|
if (!m_animRunning && time - m_unk0x404 > 10000 && speed < g_unk0x100f74b0[0][0] && speed > g_unk0x100f74b0[5][0]) {
|
||||||
LegoPathBoundary* boundary = actor->GetBoundary();
|
LegoPathBoundary* boundary = actor->GetBoundary();
|
||||||
@ -1565,13 +1565,13 @@ MxResult LegoAnimationManager::Tickle()
|
|||||||
LegoROI* roi = m_extras[i].m_roi;
|
LegoROI* roi = m_extras[i].m_roi;
|
||||||
|
|
||||||
if (roi != NULL) {
|
if (roi != NULL) {
|
||||||
MxU16 result = FUN_10062110(roi, direction, position, boundary, speed, unk0x0c, m_extras[i].m_unk0x14);
|
MxU16 result = FindAmbientAnimationForExtra(roi, direction, position, boundary, speed, unk0x0c, m_extras[i].m_unk0x14);
|
||||||
|
|
||||||
if (result) {
|
if (result) {
|
||||||
MxMatrix mat;
|
MxMatrix mat;
|
||||||
mat = roi->GetLocal2World();
|
mat = roi->GetLocal2World();
|
||||||
|
|
||||||
if (FUN_100605e0(result & USHRT_MAX, FALSE, &mat, TRUE, roi, FALSE, TRUE, TRUE, TRUE) == SUCCESS) {
|
if (StartAnimationByIndex(result & USHRT_MAX, FALSE, &mat, TRUE, roi, FALSE, TRUE, TRUE, TRUE) == SUCCESS) {
|
||||||
m_unk0x404 = time;
|
m_unk0x404 = time;
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
@ -1581,7 +1581,7 @@ MxResult LegoAnimationManager::Tickle()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (time - m_unk0x40c > 1000) {
|
if (time - m_unk0x40c > 1000) {
|
||||||
FUN_10063d10();
|
UpdateExtraActorSpeeds();
|
||||||
m_unk0x40c = time;
|
m_unk0x40c = time;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1614,7 +1614,7 @@ MxResult LegoAnimationManager::Tickle()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10062110
|
// FUNCTION: LEGO1 0x10062110
|
||||||
// FUNCTION: BETA10 0x10042f41
|
// FUNCTION: BETA10 0x10042f41
|
||||||
MxU16 LegoAnimationManager::FUN_10062110(
|
MxU16 LegoAnimationManager::FindAmbientAnimationForExtra(
|
||||||
LegoROI* p_roi,
|
LegoROI* p_roi,
|
||||||
Vector3& p_direction,
|
Vector3& p_direction,
|
||||||
Vector3& p_position,
|
Vector3& p_position,
|
||||||
@ -1706,7 +1706,7 @@ MxS8 LegoAnimationManager::GetCharacterIndex(const char* p_name)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100623a0
|
// FUNCTION: LEGO1 0x100623a0
|
||||||
// FUNCTION: BETA10 0x10043342
|
// FUNCTION: BETA10 0x10043342
|
||||||
MxBool LegoAnimationManager::FUN_100623a0(AnimInfo& p_info)
|
MxBool LegoAnimationManager::IsAnimationBlockedByVisibleActor(AnimInfo& p_info)
|
||||||
{
|
{
|
||||||
LegoWorld* world = CurrentWorld();
|
LegoWorld* world = CurrentWorld();
|
||||||
|
|
||||||
@ -1725,7 +1725,7 @@ MxBool LegoAnimationManager::FUN_100623a0(AnimInfo& p_info)
|
|||||||
if (entity != actor && entity->IsA("LegoPathActor")) {
|
if (entity != actor && entity->IsA("LegoPathActor")) {
|
||||||
LegoROI* roi = entity->GetROI();
|
LegoROI* roi = entity->GetROI();
|
||||||
|
|
||||||
if (roi->GetVisibility() && FUN_10062650(position, und, roi)) {
|
if (roi->GetVisibility() && IsROIWithinSphere(position, und, roi)) {
|
||||||
if (!ModelExists(p_info, roi->GetName())) {
|
if (!ModelExists(p_info, roi->GetName())) {
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
@ -1758,7 +1758,7 @@ MxBool LegoAnimationManager::ModelExists(AnimInfo& p_info, const char* p_name)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10062580
|
// FUNCTION: LEGO1 0x10062580
|
||||||
// FUNCTION: BETA10 0x10043552
|
// FUNCTION: BETA10 0x10043552
|
||||||
void LegoAnimationManager::FUN_10062580(AnimInfo& p_info)
|
void LegoAnimationManager::DetachActorsUsedByAnimation(AnimInfo& p_info)
|
||||||
{
|
{
|
||||||
ModelInfo* models = p_info.m_models;
|
ModelInfo* models = p_info.m_models;
|
||||||
MxU8 modelCount = p_info.m_modelCount;
|
MxU8 modelCount = p_info.m_modelCount;
|
||||||
@ -1794,7 +1794,7 @@ void LegoAnimationManager::FUN_10062580(AnimInfo& p_info)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10062650
|
// FUNCTION: LEGO1 0x10062650
|
||||||
// FUNCTION: BETA10 0x100436e2
|
// FUNCTION: BETA10 0x100436e2
|
||||||
MxBool LegoAnimationManager::FUN_10062650(Mx3DPointFloat& p_position, float p_und, LegoROI* p_roi)
|
MxBool LegoAnimationManager::IsROIWithinSphere(Mx3DPointFloat& p_position, float p_und, LegoROI* p_roi)
|
||||||
{
|
{
|
||||||
if (p_roi != NULL) {
|
if (p_roi != NULL) {
|
||||||
Mx3DPointFloat position(p_position);
|
Mx3DPointFloat position(p_position);
|
||||||
@ -1816,7 +1816,7 @@ MxBool LegoAnimationManager::FUN_10062650(Mx3DPointFloat& p_position, float p_un
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10062710
|
// FUNCTION: LEGO1 0x10062710
|
||||||
// FUNCTION: BETA10 0x10043787
|
// FUNCTION: BETA10 0x10043787
|
||||||
MxBool LegoAnimationManager::FUN_10062710(AnimInfo& p_info)
|
MxBool LegoAnimationManager::IsAnimationRejectedForPlayer(AnimInfo& p_info)
|
||||||
{
|
{
|
||||||
MxU8 und = 0;
|
MxU8 und = 0;
|
||||||
MxU8 actorId = GameState()->GetActorId();
|
MxU8 actorId = GameState()->GetActorId();
|
||||||
@ -1838,7 +1838,7 @@ MxBool LegoAnimationManager::FUN_10062710(AnimInfo& p_info)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10062770
|
// FUNCTION: LEGO1 0x10062770
|
||||||
// FUNCTION: BETA10 0x1004381a
|
// FUNCTION: BETA10 0x1004381a
|
||||||
void LegoAnimationManager::FUN_10062770()
|
void LegoAnimationManager::CacheTransitionSounds()
|
||||||
{
|
{
|
||||||
if (!m_unk0x38) {
|
if (!m_unk0x38) {
|
||||||
LegoWorld* world = CurrentWorld();
|
LegoWorld* world = CurrentWorld();
|
||||||
@ -1948,7 +1948,7 @@ void LegoAnimationManager::AddExtra(MxS32 p_location, MxBool p_und)
|
|||||||
if (p_location < 0) {
|
if (p_location < 0) {
|
||||||
boundary = new LegoLocation::Boundary;
|
boundary = new LegoLocation::Boundary;
|
||||||
|
|
||||||
if (!FUN_10064120(boundary, pathWalkingMode == 2, bool2)) {
|
if (!FindRandomSpawnBoundary(boundary, pathWalkingMode == 2, bool2)) {
|
||||||
delete boundary;
|
delete boundary;
|
||||||
boundary = NULL;
|
boundary = NULL;
|
||||||
}
|
}
|
||||||
@ -1957,10 +1957,10 @@ void LegoAnimationManager::AddExtra(MxS32 p_location, MxBool p_und)
|
|||||||
LegoLocation* location = LegoNavController::GetLocation(p_location);
|
LegoLocation* location = LegoNavController::GetLocation(p_location);
|
||||||
|
|
||||||
if (location != NULL) {
|
if (location != NULL) {
|
||||||
if (location->m_boundaryA.m_unk0x10 || FUN_10063fb0(&location->m_boundaryA, world)) {
|
if (location->m_boundaryA.m_unk0x10 || IsLocationBoundarySpawnable(&location->m_boundaryA, world)) {
|
||||||
boundary = &location->m_boundaryA;
|
boundary = &location->m_boundaryA;
|
||||||
}
|
}
|
||||||
else if (location->m_boundaryB.m_unk0x10 || FUN_10063fb0(&location->m_boundaryB, world)) {
|
else if (location->m_boundaryB.m_unk0x10 || IsLocationBoundarySpawnable(&location->m_boundaryB, world)) {
|
||||||
boundary = &location->m_boundaryB;
|
boundary = &location->m_boundaryB;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -2032,7 +2032,7 @@ void LegoAnimationManager::AddExtra(MxS32 p_location, MxBool p_und)
|
|||||||
rand() % 100 < g_characters[m_lastExtraCharacterId].m_unk0x15;
|
rand() % 100 < g_characters[m_lastExtraCharacterId].m_unk0x15;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FUN_10063b90(
|
if (BuildExtraActorCycles(
|
||||||
world,
|
world,
|
||||||
actor,
|
actor,
|
||||||
CharacterManager()->GetMood(m_extras[i].m_roi),
|
CharacterManager()->GetMood(m_extras[i].m_roi),
|
||||||
@ -2093,7 +2093,7 @@ void LegoAnimationManager::AddExtra(MxS32 p_location, MxBool p_und)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10062e20
|
// FUNCTION: LEGO1 0x10062e20
|
||||||
// FUNCTION: BETA10 0x100444cb
|
// FUNCTION: BETA10 0x100444cb
|
||||||
MxBool LegoAnimationManager::FUN_10062e20(LegoROI* p_roi, LegoAnimPresenter* p_presenter)
|
MxBool LegoAnimationManager::PromoteROIToExtraActor(LegoROI* p_roi, LegoAnimPresenter* p_presenter)
|
||||||
{
|
{
|
||||||
LegoWorld* world = CurrentWorld();
|
LegoWorld* world = CurrentWorld();
|
||||||
|
|
||||||
@ -2213,7 +2213,7 @@ MxBool LegoAnimationManager::FUN_10062e20(LegoROI* p_roi, LegoAnimPresenter* p_p
|
|||||||
actor->ClearMaps();
|
actor->ClearMaps();
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FUN_10063b90(world, actor, CharacterManager()->GetMood(p_roi), characterId)) {
|
if (BuildExtraActorCycles(world, actor, CharacterManager()->GetMood(p_roi), characterId)) {
|
||||||
m_extras[i].m_unk0x14 = TRUE;
|
m_extras[i].m_unk0x14 = TRUE;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -2250,7 +2250,7 @@ MxBool LegoAnimationManager::FUN_10062e20(LegoROI* p_roi, LegoAnimPresenter* p_p
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10063270
|
// FUNCTION: LEGO1 0x10063270
|
||||||
// FUNCTION: BETA10 0x10044b9a
|
// FUNCTION: BETA10 0x10044b9a
|
||||||
void LegoAnimationManager::FUN_10063270(LegoROIList* p_list, LegoAnimPresenter* p_presenter)
|
void LegoAnimationManager::ClaimExtraActorsFromPresenterList(LegoROIList* p_list, LegoAnimPresenter* p_presenter)
|
||||||
{
|
{
|
||||||
if (p_list != NULL) {
|
if (p_list != NULL) {
|
||||||
LegoWorld* world = CurrentWorld();
|
LegoWorld* world = CurrentWorld();
|
||||||
@ -2273,9 +2273,9 @@ void LegoAnimationManager::FUN_10063270(LegoROIList* p_list, LegoAnimPresenter*
|
|||||||
LegoROIListCursor cursor(p_list);
|
LegoROIListCursor cursor(p_list);
|
||||||
|
|
||||||
while (cursor.Next(roi)) {
|
while (cursor.Next(roi)) {
|
||||||
if (roi->GetVisibility() && FUN_10062e20(roi, p_presenter)) {
|
if (roi->GetVisibility() && PromoteROIToExtraActor(roi, p_presenter)) {
|
||||||
cursor.Detach();
|
cursor.Detach();
|
||||||
FUN_10063950(roi);
|
ReleaseStashedActor(roi);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
LegoExtraActor* actor = CharacterManager()->GetExtraActor(roi->GetName());
|
LegoExtraActor* actor = CharacterManager()->GetExtraActor(roi->GetName());
|
||||||
@ -2315,7 +2315,7 @@ void LegoAnimationManager::FUN_10063270(LegoROIList* p_list, LegoAnimPresenter*
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_10063e40(p_presenter);
|
FlushStashedActorsToWorld(p_presenter);
|
||||||
|
|
||||||
for (i = 0; i < sizeOfArray(g_vehicles); i++) {
|
for (i = 0; i < sizeOfArray(g_vehicles); i++) {
|
||||||
if (!g_vehicles[i].m_unk0x05) {
|
if (!g_vehicles[i].m_unk0x05) {
|
||||||
@ -2330,7 +2330,7 @@ void LegoAnimationManager::FUN_10063270(LegoROIList* p_list, LegoAnimPresenter*
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10063780
|
// FUNCTION: LEGO1 0x10063780
|
||||||
void LegoAnimationManager::FUN_10063780(LegoROIList* p_list)
|
void LegoAnimationManager::StashPresenterActors(LegoROIList* p_list)
|
||||||
{
|
{
|
||||||
if (p_list != NULL && m_unk0x424 != NULL) {
|
if (p_list != NULL && m_unk0x424 != NULL) {
|
||||||
LegoROIListCursor cursor(p_list);
|
LegoROIListCursor cursor(p_list);
|
||||||
@ -2348,7 +2348,7 @@ void LegoAnimationManager::FUN_10063780(LegoROIList* p_list)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10063950
|
// FUNCTION: LEGO1 0x10063950
|
||||||
void LegoAnimationManager::FUN_10063950(LegoROI* p_roi)
|
void LegoAnimationManager::ReleaseStashedActor(LegoROI* p_roi)
|
||||||
{
|
{
|
||||||
if (m_unk0x424 != NULL) {
|
if (m_unk0x424 != NULL) {
|
||||||
LegoROIListCursor cursor(m_unk0x424);
|
LegoROIListCursor cursor(m_unk0x424);
|
||||||
@ -2361,7 +2361,7 @@ void LegoAnimationManager::FUN_10063950(LegoROI* p_roi)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10063aa0
|
// FUNCTION: LEGO1 0x10063aa0
|
||||||
void LegoAnimationManager::FUN_10063aa0()
|
void LegoAnimationManager::ReleaseAllStashedActors()
|
||||||
{
|
{
|
||||||
LegoROIListCursor cursor(m_unk0x424);
|
LegoROIListCursor cursor(m_unk0x424);
|
||||||
LegoROI* roi;
|
LegoROI* roi;
|
||||||
@ -2373,7 +2373,7 @@ void LegoAnimationManager::FUN_10063aa0()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10063b90
|
// FUNCTION: LEGO1 0x10063b90
|
||||||
// FUNCTION: BETA10 0x10044d46
|
// FUNCTION: BETA10 0x10044d46
|
||||||
MxBool LegoAnimationManager::FUN_10063b90(LegoWorld* p_world, LegoExtraActor* p_actor, MxU8 p_mood, MxU32 p_characterId)
|
MxBool LegoAnimationManager::BuildExtraActorCycles(LegoWorld* p_world, LegoExtraActor* p_actor, MxU8 p_mood, MxU32 p_characterId)
|
||||||
{
|
{
|
||||||
const char** cycles = g_cycles[g_characters[p_characterId].m_unk0x16];
|
const char** cycles = g_cycles[g_characters[p_characterId].m_unk0x16];
|
||||||
const char* vehicleWC;
|
const char* vehicleWC;
|
||||||
@ -2433,7 +2433,7 @@ MxBool LegoAnimationManager::FUN_10063b90(LegoWorld* p_world, LegoExtraActor* p_
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10063d10
|
// FUNCTION: LEGO1 0x10063d10
|
||||||
// FUNCTION: BETA10 0x10045034
|
// FUNCTION: BETA10 0x10045034
|
||||||
void LegoAnimationManager::FUN_10063d10()
|
void LegoAnimationManager::UpdateExtraActorSpeeds()
|
||||||
{
|
{
|
||||||
if (CurrentWorld() != NULL) {
|
if (CurrentWorld() != NULL) {
|
||||||
MxLong time = Timer()->GetTime();
|
MxLong time = Timer()->GetTime();
|
||||||
@ -2475,14 +2475,14 @@ void LegoAnimationManager::FUN_10063d10()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10063e40
|
// FUNCTION: LEGO1 0x10063e40
|
||||||
void LegoAnimationManager::FUN_10063e40(LegoAnimPresenter* p_presenter)
|
void LegoAnimationManager::FlushStashedActorsToWorld(LegoAnimPresenter* p_presenter)
|
||||||
{
|
{
|
||||||
if (m_unk0x424 != NULL) {
|
if (m_unk0x424 != NULL) {
|
||||||
LegoROIListCursor cursor(m_unk0x424);
|
LegoROIListCursor cursor(m_unk0x424);
|
||||||
LegoROI* roi;
|
LegoROI* roi;
|
||||||
|
|
||||||
while (cursor.Next(roi)) {
|
while (cursor.Next(roi)) {
|
||||||
if (!FUN_10062e20(roi, p_presenter)) {
|
if (!PromoteROIToExtraActor(roi, p_presenter)) {
|
||||||
CharacterManager()->ReleaseActor(roi);
|
CharacterManager()->ReleaseActor(roi);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -2493,13 +2493,13 @@ void LegoAnimationManager::FUN_10063e40(LegoAnimPresenter* p_presenter)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10063fb0
|
// FUNCTION: LEGO1 0x10063fb0
|
||||||
// FUNCTION: BETA10 0x100452a7
|
// FUNCTION: BETA10 0x100452a7
|
||||||
MxBool LegoAnimationManager::FUN_10063fb0(LegoLocation::Boundary* p_boundary, LegoWorld* p_world)
|
MxBool LegoAnimationManager::IsLocationBoundarySpawnable(LegoLocation::Boundary* p_boundary, LegoWorld* p_world)
|
||||||
{
|
{
|
||||||
if (p_boundary->m_name != NULL) {
|
if (p_boundary->m_name != NULL) {
|
||||||
Mx3DPointFloat vec;
|
Mx3DPointFloat vec;
|
||||||
LegoPathBoundary* boundary = p_world->FindPathBoundary(p_boundary->m_name);
|
LegoPathBoundary* boundary = p_world->FindPathBoundary(p_boundary->m_name);
|
||||||
LegoOrientedEdge* pSrcE = (LegoOrientedEdge*) boundary->GetEdges()[p_boundary->m_src];
|
LegoOrientedEdge* pSrcE = (LegoOrientedEdge*) boundary->GetEdges()[p_boundary->m_src];
|
||||||
return FUN_10064010(boundary, pSrcE, p_boundary->m_srcScale);
|
return IsEdgeSpawnPointOffscreen(boundary, pSrcE, p_boundary->m_srcScale);
|
||||||
}
|
}
|
||||||
|
|
||||||
return FALSE;
|
return FALSE;
|
||||||
@ -2507,7 +2507,7 @@ MxBool LegoAnimationManager::FUN_10063fb0(LegoLocation::Boundary* p_boundary, Le
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10064010
|
// FUNCTION: LEGO1 0x10064010
|
||||||
// FUNCTION: BETA10 0x100453a5
|
// FUNCTION: BETA10 0x100453a5
|
||||||
MxBool LegoAnimationManager::FUN_10064010(LegoPathBoundary* p_boundary, LegoOrientedEdge* p_edge, float p_destScale)
|
MxBool LegoAnimationManager::IsEdgeSpawnPointOffscreen(LegoPathBoundary* p_boundary, LegoOrientedEdge* p_edge, float p_destScale)
|
||||||
{
|
{
|
||||||
Mx3DPointFloat p1;
|
Mx3DPointFloat p1;
|
||||||
Vector3* v1 = p_edge->CWVertex(*p_boundary);
|
Vector3* v1 = p_edge->CWVertex(*p_boundary);
|
||||||
@ -2537,7 +2537,7 @@ MxBool LegoAnimationManager::FUN_10064010(LegoPathBoundary* p_boundary, LegoOrie
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10064120
|
// FUNCTION: LEGO1 0x10064120
|
||||||
// FUNCTION: BETA10 0x100454f5
|
// FUNCTION: BETA10 0x100454f5
|
||||||
MxBool LegoAnimationManager::FUN_10064120(LegoLocation::Boundary* p_boundary, MxBool p_bool1, MxBool p_bool2)
|
MxBool LegoAnimationManager::FindRandomSpawnBoundary(LegoLocation::Boundary* p_boundary, MxBool p_bool1, MxBool p_bool2)
|
||||||
{
|
{
|
||||||
MxU32 local2c = 12;
|
MxU32 local2c = 12;
|
||||||
float destScale = ((rand() * 0.5) / RAND_MAX) + 0.25;
|
float destScale = ((rand() * 0.5) / RAND_MAX) + 0.25;
|
||||||
@ -2589,8 +2589,8 @@ MxBool LegoAnimationManager::FUN_10064120(LegoLocation::Boundary* p_boundary, Mx
|
|||||||
|
|
||||||
while (local2c--) {
|
while (local2c--) {
|
||||||
if (local34 != NULL) {
|
if (local34 != NULL) {
|
||||||
if (local34->BETA_1004a830(*boundary, LegoWEGEdge::c_bit1) && FUN_10064010(boundary, local34, destScale) &&
|
if (local34->BETA_1004a830(*boundary, LegoWEGEdge::c_bit1) && IsEdgeSpawnPointOffscreen(boundary, local34, destScale) &&
|
||||||
(!p_bool2 || FUN_10064010(boundary, local8, destScale))) {
|
(!p_bool2 || IsEdgeSpawnPointOffscreen(boundary, local8, destScale))) {
|
||||||
p_boundary->m_srcScale = p_boundary->m_destScale = destScale;
|
p_boundary->m_srcScale = p_boundary->m_destScale = destScale;
|
||||||
p_boundary->m_name = boundary->GetName();
|
p_boundary->m_name = boundary->GetName();
|
||||||
numEdges = boundary->GetNumEdges();
|
numEdges = boundary->GetNumEdges();
|
||||||
@ -2633,7 +2633,7 @@ MxBool LegoAnimationManager::FUN_10064120(LegoLocation::Boundary* p_boundary, Mx
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10064380
|
// FUNCTION: LEGO1 0x10064380
|
||||||
// FUNCTION: BETA10 0x1004583a
|
// FUNCTION: BETA10 0x1004583a
|
||||||
MxResult LegoAnimationManager::FUN_10064380(
|
MxResult LegoAnimationManager::PlaceNamedExtraActor(
|
||||||
const char* p_name,
|
const char* p_name,
|
||||||
const char* p_boundaryName,
|
const char* p_boundaryName,
|
||||||
MxS32 p_src,
|
MxS32 p_src,
|
||||||
@ -2734,7 +2734,7 @@ MxResult LegoAnimationManager::FUN_10064380(
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10064670
|
// FUNCTION: LEGO1 0x10064670
|
||||||
MxResult LegoAnimationManager::FUN_10064670(Vector3* p_position)
|
MxResult LegoAnimationManager::SpawnBricksterAtPoliceStation(Vector3* p_position)
|
||||||
{
|
{
|
||||||
MxBool success = FALSE;
|
MxBool success = FALSE;
|
||||||
|
|
||||||
@ -2751,14 +2751,14 @@ MxResult LegoAnimationManager::FUN_10064670(Vector3* p_position)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (success) {
|
if (success) {
|
||||||
return FUN_10064380("brickstr", "EDG02_95", 1, 0.5f, 3, 0.5f, rand() % 3 + 14, -1, rand() % 3, -1, 0.5f);
|
return PlaceNamedExtraActor("brickstr", "EDG02_95", 1, 0.5f, 3, 0.5f, rand() % 3 + 14, -1, rand() % 3, -1, 0.5f);
|
||||||
}
|
}
|
||||||
|
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10064740
|
// FUNCTION: LEGO1 0x10064740
|
||||||
MxResult LegoAnimationManager::FUN_10064740(Vector3* p_position)
|
MxResult LegoAnimationManager::SpawnParentsAtHospital(Vector3* p_position)
|
||||||
{
|
{
|
||||||
MxBool success = FALSE;
|
MxBool success = FALSE;
|
||||||
|
|
||||||
@ -2776,11 +2776,11 @@ MxResult LegoAnimationManager::FUN_10064740(Vector3* p_position)
|
|||||||
|
|
||||||
if (success) {
|
if (success) {
|
||||||
if (GameState()->GetActorId() != LegoActor::c_mama) {
|
if (GameState()->GetActorId() != LegoActor::c_mama) {
|
||||||
FUN_10064380("mama", "USR00_47", 1, 0.43f, 3, 0.84f, rand() % 3 + 13, -1, rand() % 3, -1, 0.7f);
|
PlaceNamedExtraActor("mama", "USR00_47", 1, 0.43f, 3, 0.84f, rand() % 3 + 13, -1, rand() % 3, -1, 0.7f);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (GameState()->GetActorId() != LegoActor::c_papa) {
|
if (GameState()->GetActorId() != LegoActor::c_papa) {
|
||||||
FUN_10064380("papa", "USR00_193", 3, 0.55f, 1, 0.4f, rand() % 3 + 13, -1, rand() % 3, -1, 0.9f);
|
PlaceNamedExtraActor("papa", "USR00_193", 3, 0.55f, 1, 0.4f, rand() % 3 + 13, -1, rand() % 3, -1, 0.9f);
|
||||||
}
|
}
|
||||||
|
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
@ -2791,7 +2791,7 @@ MxResult LegoAnimationManager::FUN_10064740(Vector3* p_position)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10064880
|
// FUNCTION: LEGO1 0x10064880
|
||||||
// FUNCTION: BETA10 0x10045d02
|
// FUNCTION: BETA10 0x10045d02
|
||||||
MxResult LegoAnimationManager::FUN_10064880(const char* p_name, MxS32 p_unk0x0c, MxS32 p_unk0x10)
|
MxResult LegoAnimationManager::SetExtraActorTiming(const char* p_name, MxS32 p_unk0x0c, MxS32 p_unk0x10)
|
||||||
{
|
{
|
||||||
for (MxS32 i = 0; i < (MxS32) sizeOfArray(m_extras); i++) {
|
for (MxS32 i = 0; i < (MxS32) sizeOfArray(m_extras); i++) {
|
||||||
LegoROI* roi = m_extras[i].m_roi;
|
LegoROI* roi = m_extras[i].m_roi;
|
||||||
@ -2810,7 +2810,7 @@ MxResult LegoAnimationManager::FUN_10064880(const char* p_name, MxS32 p_unk0x0c,
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100648f0
|
// FUNCTION: LEGO1 0x100648f0
|
||||||
// FUNCTION: BETA10 0x10045daf
|
// FUNCTION: BETA10 0x10045daf
|
||||||
void LegoAnimationManager::FUN_100648f0(LegoTranInfo* p_tranInfo, MxLong p_unk0x404)
|
void LegoAnimationManager::BeginAnimationCameraTransition(LegoTranInfo* p_tranInfo, MxLong p_unk0x404)
|
||||||
{
|
{
|
||||||
if (
|
if (
|
||||||
#ifndef BETA10
|
#ifndef BETA10
|
||||||
@ -2854,7 +2854,7 @@ void LegoAnimationManager::FUN_100648f0(LegoTranInfo* p_tranInfo, MxLong p_unk0x
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10064b50
|
// FUNCTION: LEGO1 0x10064b50
|
||||||
// FUNCTION: BETA10 0x10045f14
|
// FUNCTION: BETA10 0x10045f14
|
||||||
void LegoAnimationManager::FUN_10064b50(MxLong p_time)
|
void LegoAnimationManager::UpdateAnimationCameraTransition(MxLong p_time)
|
||||||
{
|
{
|
||||||
if (m_unk0x430 && m_unk0x42c != NULL) {
|
if (m_unk0x430 && m_unk0x42c != NULL) {
|
||||||
MxMatrix mat;
|
MxMatrix mat;
|
||||||
@ -2893,7 +2893,7 @@ void LegoAnimationManager::FUN_10064b50(MxLong p_time)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10064ee0
|
// FUNCTION: LEGO1 0x10064ee0
|
||||||
MxBool LegoAnimationManager::FUN_10064ee0(MxU32 p_objectId)
|
MxBool LegoAnimationManager::IsAnimationFinished(MxU32 p_objectId)
|
||||||
{
|
{
|
||||||
if (m_tranInfoList != NULL) {
|
if (m_tranInfoList != NULL) {
|
||||||
LegoTranInfoListCursor cursor(m_tranInfoList);
|
LegoTranInfoListCursor cursor(m_tranInfoList);
|
||||||
@ -2902,7 +2902,7 @@ MxBool LegoAnimationManager::FUN_10064ee0(MxU32 p_objectId)
|
|||||||
while (cursor.Next(tranInfo)) {
|
while (cursor.Next(tranInfo)) {
|
||||||
if (tranInfo->m_animInfo->m_objectId == p_objectId) {
|
if (tranInfo->m_animInfo->m_objectId == p_objectId) {
|
||||||
if (tranInfo->m_presenter) {
|
if (tranInfo->m_presenter) {
|
||||||
return tranInfo->m_presenter->FUN_1004b830();
|
return tranInfo->m_presenter->HasPassedPresenterStart();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|||||||
@ -180,7 +180,7 @@ void LegoAnimMMPresenter::StartingTickle()
|
|||||||
// FUNCTION: BETA10 0x1004c372
|
// FUNCTION: BETA10 0x1004c372
|
||||||
void LegoAnimMMPresenter::StreamingTickle()
|
void LegoAnimMMPresenter::StreamingTickle()
|
||||||
{
|
{
|
||||||
if (FUN_1004b450()) {
|
if (RunStartupSequence()) {
|
||||||
ProgressTickleState(e_repeating);
|
ProgressTickleState(e_repeating);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -262,49 +262,49 @@ void LegoAnimMMPresenter::ParseExtra()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b450
|
// FUNCTION: LEGO1 0x1004b450
|
||||||
// FUNCTION: BETA10 0x1004c71d
|
// FUNCTION: BETA10 0x1004c71d
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b450()
|
MxBool LegoAnimMMPresenter::RunStartupSequence()
|
||||||
{
|
{
|
||||||
MxBool result = FALSE;
|
MxBool result = FALSE;
|
||||||
MxLong time = Timer()->GetTime() - m_unk0x50;
|
MxLong time = Timer()->GetTime() - m_unk0x50;
|
||||||
|
|
||||||
switch (m_unk0x58) {
|
switch (m_unk0x58) {
|
||||||
case e_unk0:
|
case e_unk0:
|
||||||
if (!FUN_1004b530(time)) {
|
if (!CaptureAnimationState(time)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
m_unk0x58 = e_unk1;
|
m_unk0x58 = e_unk1;
|
||||||
case e_unk1:
|
case e_unk1:
|
||||||
if (!FUN_1004b570(time)) {
|
if (!WaitForPreRoll(time)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
m_unk0x58 = e_unk2;
|
m_unk0x58 = e_unk2;
|
||||||
case e_unk2:
|
case e_unk2:
|
||||||
if (!FUN_1004b580(time)) {
|
if (!WaitForTransitionSound(time)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
m_unk0x58 = e_unk3;
|
m_unk0x58 = e_unk3;
|
||||||
case e_unk3:
|
case e_unk3:
|
||||||
if (!FUN_1004b5b0(time)) {
|
if (!RestoreInitialTransforms(time)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
m_unk0x58 = e_unk4;
|
m_unk0x58 = e_unk4;
|
||||||
case e_unk4:
|
case e_unk4:
|
||||||
if (!FUN_1004b600(time)) {
|
if (!PreparePresentersForStart(time)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
m_unk0x58 = e_unk5;
|
m_unk0x58 = e_unk5;
|
||||||
case e_unk5:
|
case e_unk5:
|
||||||
if (!FUN_1004b610(time)) {
|
if (!StartChildPresenters(time)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
m_unk0x58 = e_unk6;
|
m_unk0x58 = e_unk6;
|
||||||
case e_unk6:
|
case e_unk6:
|
||||||
if (!FUN_1004b6b0(time)) {
|
if (!WaitForAnimationPresenterIdle(time)) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
m_unk0x58 = e_unk7;
|
m_unk0x58 = e_unk7;
|
||||||
case e_unk7:
|
case e_unk7:
|
||||||
FUN_1004b6d0(time);
|
RestoreUserActorAfterAnimation(time);
|
||||||
result = TRUE;
|
result = TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -313,7 +313,7 @@ MxBool LegoAnimMMPresenter::FUN_1004b450()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b530
|
// FUNCTION: LEGO1 0x1004b530
|
||||||
// FUNCTION: BETA10 0x1004c8c4
|
// FUNCTION: BETA10 0x1004c8c4
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b530(MxLong p_time)
|
MxBool LegoAnimMMPresenter::CaptureAnimationState(MxLong p_time)
|
||||||
{
|
{
|
||||||
if (m_presenter != NULL) {
|
if (m_presenter != NULL) {
|
||||||
m_presenter->GetTransforms(m_unk0x68, 0);
|
m_presenter->GetTransforms(m_unk0x68, 0);
|
||||||
@ -326,14 +326,14 @@ MxBool LegoAnimMMPresenter::FUN_1004b530(MxLong p_time)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b570
|
// FUNCTION: LEGO1 0x1004b570
|
||||||
// FUNCTION: BETA10 0x1004c9cc
|
// FUNCTION: BETA10 0x1004c9cc
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b570(MxLong p_time)
|
MxBool LegoAnimMMPresenter::WaitForPreRoll(MxLong p_time)
|
||||||
{
|
{
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b580
|
// FUNCTION: LEGO1 0x1004b580
|
||||||
// FUNCTION: BETA10 0x1004ca3f
|
// FUNCTION: BETA10 0x1004ca3f
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b580(MxLong p_time)
|
MxBool LegoAnimMMPresenter::WaitForTransitionSound(MxLong p_time)
|
||||||
{
|
{
|
||||||
switch (m_unk0x59) {
|
switch (m_unk0x59) {
|
||||||
case 0:
|
case 0:
|
||||||
@ -355,7 +355,7 @@ MxBool LegoAnimMMPresenter::FUN_1004b580(MxLong p_time)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b5b0
|
// FUNCTION: LEGO1 0x1004b5b0
|
||||||
// FUNCTION: BETA10 0x1004cb09
|
// FUNCTION: BETA10 0x1004cb09
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b5b0(MxLong p_time)
|
MxBool LegoAnimMMPresenter::RestoreInitialTransforms(MxLong p_time)
|
||||||
{
|
{
|
||||||
switch (m_unk0x59) {
|
switch (m_unk0x59) {
|
||||||
case 0:
|
case 0:
|
||||||
@ -382,14 +382,14 @@ MxBool LegoAnimMMPresenter::FUN_1004b5b0(MxLong p_time)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b600
|
// FUNCTION: LEGO1 0x1004b600
|
||||||
// FUNCTION: BETA10 0x1004cbfb
|
// FUNCTION: BETA10 0x1004cbfb
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b600(MxLong p_time)
|
MxBool LegoAnimMMPresenter::PreparePresentersForStart(MxLong p_time)
|
||||||
{
|
{
|
||||||
return TRUE;
|
return TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b610
|
// FUNCTION: LEGO1 0x1004b610
|
||||||
// FUNCTION: BETA10 0x1004cc6e
|
// FUNCTION: BETA10 0x1004cc6e
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b610(MxLong p_time)
|
MxBool LegoAnimMMPresenter::StartChildPresenters(MxLong p_time)
|
||||||
{
|
{
|
||||||
for (MxCompositePresenterList::iterator it = m_list.begin(); it != m_list.end(); it++) {
|
for (MxCompositePresenterList::iterator it = m_list.begin(); it != m_list.end(); it++) {
|
||||||
if ((*it)->IsA("LegoAnimPresenter") || (*it)->IsA("LegoLoopingAnimPresenter")) {
|
if ((*it)->IsA("LegoAnimPresenter") || (*it)->IsA("LegoLoopingAnimPresenter")) {
|
||||||
@ -411,7 +411,7 @@ MxBool LegoAnimMMPresenter::FUN_1004b610(MxLong p_time)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b6b0
|
// FUNCTION: LEGO1 0x1004b6b0
|
||||||
// FUNCTION: BETA10 0x1004cdc5
|
// FUNCTION: BETA10 0x1004cdc5
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b6b0(MxLong p_time)
|
MxBool LegoAnimMMPresenter::WaitForAnimationPresenterIdle(MxLong p_time)
|
||||||
{
|
{
|
||||||
if (m_presenter != NULL && m_presenter->GetCurrentTickleState() != e_idle) {
|
if (m_presenter != NULL && m_presenter->GetCurrentTickleState() != e_idle) {
|
||||||
return FALSE;
|
return FALSE;
|
||||||
@ -423,7 +423,7 @@ MxBool LegoAnimMMPresenter::FUN_1004b6b0(MxLong p_time)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b6d0
|
// FUNCTION: LEGO1 0x1004b6d0
|
||||||
// FUNCTION: BETA10 0x1004ce18
|
// FUNCTION: BETA10 0x1004ce18
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b6d0(MxLong p_time)
|
MxBool LegoAnimMMPresenter::RestoreUserActorAfterAnimation(MxLong p_time)
|
||||||
{
|
{
|
||||||
#ifdef BETA10
|
#ifdef BETA10
|
||||||
switch (m_unk0x58) {
|
switch (m_unk0x58) {
|
||||||
@ -486,14 +486,14 @@ MxBool LegoAnimMMPresenter::FUN_1004b6d0(MxLong p_time)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b830
|
// FUNCTION: LEGO1 0x1004b830
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b830()
|
MxBool LegoAnimMMPresenter::HasPassedPresenterStart()
|
||||||
{
|
{
|
||||||
return m_unk0x58 >= e_unk6;
|
return m_unk0x58 >= e_unk6;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b840
|
// FUNCTION: LEGO1 0x1004b840
|
||||||
// FUNCTION: BETA10 0x1004d033
|
// FUNCTION: BETA10 0x1004d033
|
||||||
void LegoAnimMMPresenter::FUN_1004b840()
|
void LegoAnimMMPresenter::StopAndFinishAnimation()
|
||||||
{
|
{
|
||||||
MxDSAction* action = m_action;
|
MxDSAction* action = m_action;
|
||||||
|
|
||||||
@ -507,26 +507,26 @@ void LegoAnimMMPresenter::FUN_1004b840()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_1004b6d0(0);
|
RestoreUserActorAfterAnimation(0);
|
||||||
EndAction();
|
EndAction();
|
||||||
|
|
||||||
#ifndef BETA10
|
#ifndef BETA10
|
||||||
if (action != NULL) {
|
if (action != NULL) {
|
||||||
Streamer()->FUN_100b98f0(action);
|
Streamer()->StopDiskAction(action);
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b8b0
|
// FUNCTION: LEGO1 0x1004b8b0
|
||||||
// FUNCTION: BETA10 0x1004d104
|
// FUNCTION: BETA10 0x1004d104
|
||||||
MxBool LegoAnimMMPresenter::FUN_1004b8b0()
|
MxBool LegoAnimMMPresenter::UsesLocalActors()
|
||||||
{
|
{
|
||||||
return m_tranInfo != NULL ? m_tranInfo->m_unk0x28 : TRUE;
|
return m_tranInfo != NULL ? m_tranInfo->m_unk0x28 : TRUE;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004b8c0
|
// FUNCTION: LEGO1 0x1004b8c0
|
||||||
// FUNCTION: BETA10 0x1004d13d
|
// FUNCTION: BETA10 0x1004d13d
|
||||||
void LegoAnimMMPresenter::FUN_1004b8c0()
|
void LegoAnimMMPresenter::ReleaseUserActor()
|
||||||
{
|
{
|
||||||
FUN_1004b6d0(0);
|
RestoreUserActorAfterAnimation(0);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1084,7 +1084,7 @@ MxResult LegoCharacterManager::UpdateBoundingSphereAndBox(LegoROI* p_roi)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x10085a80
|
// FUNCTION: LEGO1 0x10085a80
|
||||||
LegoROI* LegoCharacterManager::FUN_10085a80(const char* p_name, const char* p_lodName, MxBool p_createEntity)
|
LegoROI* LegoCharacterManager::CreateAutoROIWrapper(const char* p_name, const char* p_lodName, MxBool p_createEntity)
|
||||||
{
|
{
|
||||||
return CreateAutoROI(p_name, p_lodName, p_createEntity);
|
return CreateAutoROI(p_name, p_lodName, p_createEntity);
|
||||||
}
|
}
|
||||||
|
|||||||
@ -127,7 +127,7 @@ void LegoPlantManager::Reset(LegoOmni::World p_worldId)
|
|||||||
// FUNCTION: BETA10 0x100c50e9
|
// FUNCTION: BETA10 0x100c50e9
|
||||||
MxResult LegoPlantManager::DetermineBoundaries()
|
MxResult LegoPlantManager::DetermineBoundaries()
|
||||||
{
|
{
|
||||||
// similar to LegoBuildingManager::FUN_10030630()
|
// similar to LegoBuildingManager::DetermineBoundaries()
|
||||||
|
|
||||||
LegoWorld* world = CurrentWorld();
|
LegoWorld* world = CurrentWorld();
|
||||||
|
|
||||||
|
|||||||
@ -564,9 +564,9 @@ void EnableAnimations(MxBool p_enable)
|
|||||||
AnimationManager()->Resume();
|
AnimationManager()->Resume();
|
||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()->FUN_1005f6d0(p_enable);
|
AnimationManager()->EnableExtras(p_enable);
|
||||||
AnimationManager()->FUN_10060540(p_enable);
|
AnimationManager()->SetAllAnimationsEnabled(p_enable);
|
||||||
AnimationManager()->FUN_100604d0(p_enable);
|
AnimationManager()->SetAllCharactersAnimationEnabled(p_enable);
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1003ef40
|
// FUNCTION: LEGO1 0x1003ef40
|
||||||
|
|||||||
@ -675,7 +675,7 @@ MxLong LegoNavController::Notify(MxParam& p_param)
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case VK_SPACE: // Interrupt/end animations or free navigation
|
case VK_SPACE: // Interrupt/end animations or free navigation
|
||||||
AnimationManager()->FUN_10061010(TRUE);
|
AnimationManager()->StopAnimations(TRUE);
|
||||||
break;
|
break;
|
||||||
case 'Z': { // Make nearby plants "dance"
|
case 'Z': { // Make nearby plants "dance"
|
||||||
LegoOmni* omni = Lego();
|
LegoOmni* omni = Lego();
|
||||||
@ -815,7 +815,7 @@ MxLong LegoNavController::Notify(MxParam& p_param)
|
|||||||
// Add to animation object ID offset
|
// Add to animation object ID offset
|
||||||
g_nextAnimation += key - '0';
|
g_nextAnimation += key - '0';
|
||||||
g_animationCalcStep = 0;
|
g_animationCalcStep = 0;
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
g_nextAnimation,
|
g_nextAnimation,
|
||||||
NULL,
|
NULL,
|
||||||
TRUE,
|
TRUE,
|
||||||
@ -897,7 +897,7 @@ MxLong LegoNavController::Notify(MxParam& p_param)
|
|||||||
case 'A':
|
case 'A':
|
||||||
if (g_animationCalcStep == 1) {
|
if (g_animationCalcStep == 1) {
|
||||||
Lego()->m_initialized = TRUE;
|
Lego()->m_initialized = TRUE;
|
||||||
AnimationManager()->FUN_10060570(TRUE);
|
AnimationManager()->SetAutoPlayAnimations(TRUE);
|
||||||
g_animationCalcStep = 0;
|
g_animationCalcStep = 0;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -984,7 +984,7 @@ MxLong LegoNavController::Notify(MxParam& p_param)
|
|||||||
break;
|
break;
|
||||||
case 'V':
|
case 'V':
|
||||||
if (g_nextAnimation > 0 && g_animationCalcStep == 0) {
|
if (g_nextAnimation > 0 && g_animationCalcStep == 0) {
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (g_animationCalcStep != 0) {
|
if (g_animationCalcStep != 0) {
|
||||||
|
|||||||
@ -691,7 +691,7 @@ void LegoWorld::Enable(MxBool p_enable)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
if (CurrentWorld()) {
|
if (CurrentWorld()) {
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
CurrentWorld()->Enable(FALSE);
|
CurrentWorld()->Enable(FALSE);
|
||||||
|
|
||||||
LegoEntityListCursor cursor(m_entityList);
|
LegoEntityListCursor cursor(m_entityList);
|
||||||
|
|||||||
@ -457,7 +457,7 @@ MxBool LegoInputManager::ProcessOneEvent(LegoEventNotificationParam& p_param)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FUN_1005cdf0(p_param)) {
|
if (TranslateMouseEventToClickOrDrag(p_param)) {
|
||||||
if (processRoi && p_param.GetNotification() == c_notificationClick) {
|
if (processRoi && p_param.GetNotification() == c_notificationClick) {
|
||||||
LegoROI* roi = PickROI(p_param.GetX(), p_param.GetY());
|
LegoROI* roi = PickROI(p_param.GetX(), p_param.GetY());
|
||||||
p_param.SetROI(roi);
|
p_param.SetROI(roi);
|
||||||
@ -486,7 +486,7 @@ MxBool LegoInputManager::ProcessOneEvent(LegoEventNotificationParam& p_param)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1005cdf0
|
// FUNCTION: LEGO1 0x1005cdf0
|
||||||
// FUNCTION: BETA10 0x10089cc1
|
// FUNCTION: BETA10 0x10089cc1
|
||||||
MxBool LegoInputManager::FUN_1005cdf0(LegoEventNotificationParam& p_param)
|
MxBool LegoInputManager::TranslateMouseEventToClickOrDrag(LegoEventNotificationParam& p_param)
|
||||||
{
|
{
|
||||||
MxBool result = FALSE;
|
MxBool result = FALSE;
|
||||||
|
|
||||||
|
|||||||
@ -456,7 +456,7 @@ void LegoOmni::DeleteObject(MxDSAction& p_dsAction)
|
|||||||
m_currentWorld->Remove(entity);
|
m_currentWorld->Remove(entity);
|
||||||
|
|
||||||
if (entity->IsA("MxPresenter")) {
|
if (entity->IsA("MxPresenter")) {
|
||||||
Streamer()->FUN_100b98f0(((MxPresenter*) entity)->GetAction());
|
Streamer()->StopDiskAction(((MxPresenter*) entity)->GetAction());
|
||||||
((MxPresenter*) entity)->EndAction();
|
((MxPresenter*) entity)->EndAction();
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
|||||||
@ -356,7 +356,7 @@ MxU32 LegoPathBoundary::AddPresenterIfInRange(LegoAnimPresenter* p_presenter)
|
|||||||
|
|
||||||
// TODO: This only seems to match if the type is not the same as the type of the
|
// TODO: This only seems to match if the type is not the same as the type of the
|
||||||
// key value of the set. Figure out which type the set (or parameter) actually uses.
|
// key value of the set. Figure out which type the set (or parameter) actually uses.
|
||||||
// Also see call to .find in LegoPathController::FUN_10046050
|
// Also see call to .find in LegoPathController::PlaceActorWithPresenter
|
||||||
m_presenters.insert(static_cast<LegoLocomotionAnimPresenter*>(p_presenter));
|
m_presenters.insert(static_cast<LegoLocomotionAnimPresenter*>(p_presenter));
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
@ -368,7 +368,7 @@ MxU32 LegoPathBoundary::RemovePresenter(LegoAnimPresenter* p_presenter)
|
|||||||
if (p_presenter != NULL) {
|
if (p_presenter != NULL) {
|
||||||
// TODO: This only seems to match if the type is not the same as the type of the
|
// TODO: This only seems to match if the type is not the same as the type of the
|
||||||
// key value of the set. Figure out which type the set (or parameter) actually uses.
|
// key value of the set. Figure out which type the set (or parameter) actually uses.
|
||||||
// Also see call to .find in LegoPathController::FUN_10046050
|
// Also see call to .find in LegoPathController::PlaceActorWithPresenter
|
||||||
if (m_presenters.find(static_cast<LegoLocomotionAnimPresenter*>(p_presenter)) != m_presenters.end()) {
|
if (m_presenters.find(static_cast<LegoLocomotionAnimPresenter*>(p_presenter)) != m_presenters.end()) {
|
||||||
m_presenters.erase(static_cast<LegoLocomotionAnimPresenter*>(p_presenter));
|
m_presenters.erase(static_cast<LegoLocomotionAnimPresenter*>(p_presenter));
|
||||||
return 1;
|
return 1;
|
||||||
|
|||||||
@ -926,7 +926,7 @@ MxResult LegoPathController::FindPath(
|
|||||||
if (p_grec->size() > 0) {
|
if (p_grec->size() > 0) {
|
||||||
LegoPathCtrlEdge* edge = p_grec->front().m_edge;
|
LegoPathCtrlEdge* edge = p_grec->front().m_edge;
|
||||||
|
|
||||||
if (edge->FUN_10048c40(p_oldPosition)) {
|
if (edge->ContainsPointOnEdge(p_oldPosition)) {
|
||||||
p_grec->pop_front();
|
p_grec->pop_front();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -934,7 +934,7 @@ MxResult LegoPathController::FindPath(
|
|||||||
if (p_grec->size() > 0) {
|
if (p_grec->size() > 0) {
|
||||||
LegoPathCtrlEdge* edge = p_grec->back().m_edge;
|
LegoPathCtrlEdge* edge = p_grec->back().m_edge;
|
||||||
|
|
||||||
if (edge->FUN_10048c40(p_newPosition)) {
|
if (edge->ContainsPointOnEdge(p_newPosition)) {
|
||||||
if (edge->OtherFace(p_grec->back().m_boundary) != NULL &&
|
if (edge->OtherFace(p_grec->back().m_boundary) != NULL &&
|
||||||
edge->OtherFace(p_grec->back().m_boundary)->IsEqual(p_newBoundary)) {
|
edge->OtherFace(p_grec->back().m_boundary)->IsEqual(p_newBoundary)) {
|
||||||
p_grec->m_boundary = p_grec->back().m_boundary;
|
p_grec->m_boundary = p_grec->back().m_boundary;
|
||||||
|
|||||||
@ -130,7 +130,7 @@ void CarRace::ReadyWorld()
|
|||||||
m_introAnimation = g_introAnimations[rand() & 7];
|
m_introAnimation = g_introAnimations[rand() & 7];
|
||||||
|
|
||||||
AnimationManager()
|
AnimationManager()
|
||||||
->FUN_10060dc0(m_introAnimation, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, TRUE, FALSE, TRUE);
|
->StartManagedAnimation(m_introAnimation, NULL, TRUE, LegoAnimationManager::e_unk0, NULL, FALSE, TRUE, FALSE, TRUE);
|
||||||
|
|
||||||
m_opponent1Locator = (MxStillPresenter*) Find("MxPresenter", "CarLocator2");
|
m_opponent1Locator = (MxStillPresenter*) Find("MxPresenter", "CarLocator2");
|
||||||
m_opponent1Locator->SetPosition(m_progressBarRect.GetLeft(), m_progressBarRect.GetTop());
|
m_opponent1Locator->SetPosition(m_progressBarRect.GetLeft(), m_progressBarRect.GetTop());
|
||||||
@ -163,7 +163,7 @@ MxLong CarRace::HandleEndAction(MxEndActionNotificationParam& p_param)
|
|||||||
result = 1;
|
result = 1;
|
||||||
}
|
}
|
||||||
else if (m_firstFinishAnimation == objectId) {
|
else if (m_firstFinishAnimation == objectId) {
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
m_secondFinishAnimation,
|
m_secondFinishAnimation,
|
||||||
NULL,
|
NULL,
|
||||||
TRUE,
|
TRUE,
|
||||||
@ -268,7 +268,7 @@ MxLong CarRace::HandlePathStruct(LegoPathStructNotificationParam& p_param)
|
|||||||
raceState->m_score = score;
|
raceState->m_score = score;
|
||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
m_firstFinishAnimation,
|
m_firstFinishAnimation,
|
||||||
NULL,
|
NULL,
|
||||||
TRUE,
|
TRUE,
|
||||||
@ -426,7 +426,7 @@ MxBool CarRace::Escape()
|
|||||||
{
|
{
|
||||||
InvokeAction(Extra::e_stop, *g_carraceScript, CarraceScript::c_irtx08ra_PlayWav, NULL);
|
InvokeAction(Extra::e_stop, *g_carraceScript, CarraceScript::c_irtx08ra_PlayWav, NULL);
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
DeleteObjects(&m_atomId, 500, 999);
|
DeleteObjects(&m_atomId, 500, 999);
|
||||||
m_act1State->m_state = Act1State::e_none;
|
m_act1State->m_state = Act1State::e_none;
|
||||||
VariableTable()->SetVariable(g_strHIT_WALL_SOUND, "");
|
VariableTable()->SetVariable(g_strHIT_WALL_SOUND, "");
|
||||||
|
|||||||
@ -292,7 +292,7 @@ void JetskiRace::SetProgressPosition(MxS32 p_actorId, MxS16 p_progress)
|
|||||||
// FUNCTION: LEGO1 0x10016a10
|
// FUNCTION: LEGO1 0x10016a10
|
||||||
MxBool JetskiRace::Escape()
|
MxBool JetskiRace::Escape()
|
||||||
{
|
{
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
DeleteObjects(&m_atomId, 500, 999);
|
DeleteObjects(&m_atomId, 500, 999);
|
||||||
m_act1State->m_state = Act1State::e_none;
|
m_act1State->m_state = Act1State::e_none;
|
||||||
VariableTable()->SetVariable(g_raceState, "");
|
VariableTable()->SetVariable(g_raceState, "");
|
||||||
|
|||||||
@ -120,7 +120,7 @@ MxResult LegoRaceActor::HitActor(LegoPathActor* p_actor, MxBool p_bool)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10014aa0
|
// FUNCTION: LEGO1 0x10014aa0
|
||||||
// FUNCTION: BETA10 0x100ca038
|
// FUNCTION: BETA10 0x100ca038
|
||||||
MxResult LegoRaceActor::FUN_10014aa0()
|
MxResult LegoRaceActor::OnRaceActorAction()
|
||||||
{
|
{
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -52,7 +52,7 @@ void RaceSkel::ParseAction(char* p_extra)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10071c80
|
// FUNCTION: LEGO1 0x10071c80
|
||||||
// FUNCTION: BETA10 0x100f1531
|
// FUNCTION: BETA10 0x100f1531
|
||||||
void RaceSkel::FUN_10071c80(Vector3& p_vec)
|
void RaceSkel::GetFixedRaceSkeletonPosition(Vector3& p_vec)
|
||||||
{
|
{
|
||||||
p_vec[0] = -630.0f;
|
p_vec[0] = -630.0f;
|
||||||
p_vec[1] = -4.688f;
|
p_vec[1] = -4.688f;
|
||||||
|
|||||||
@ -250,7 +250,7 @@ void LegoAnimPresenter::CreateManagedActors()
|
|||||||
strlwr(baseName);
|
strlwr(baseName);
|
||||||
|
|
||||||
LegoChar* roiName = GetActorName(str);
|
LegoChar* roiName = GetActorName(str);
|
||||||
roi = CharacterManager()->FUN_10085a80(roiName, baseName, TRUE);
|
roi = CharacterManager()->CreateAutoROIWrapper(roiName, baseName, TRUE);
|
||||||
|
|
||||||
if (roi != NULL) {
|
if (roi != NULL) {
|
||||||
roi->SetVisibility(FALSE);
|
roi->SetVisibility(FALSE);
|
||||||
@ -547,10 +547,10 @@ void LegoAnimPresenter::ReleaseManagedActors()
|
|||||||
void LegoAnimPresenter::AppendManagedActors()
|
void LegoAnimPresenter::AppendManagedActors()
|
||||||
{
|
{
|
||||||
if (m_localActors) {
|
if (m_localActors) {
|
||||||
AnimationManager()->FUN_10063270(m_managedActors, this);
|
AnimationManager()->ClaimExtraActorsFromPresenterList(m_managedActors, this);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
AnimationManager()->FUN_10063780(m_managedActors);
|
AnimationManager()->StashPresenterActors(m_managedActors);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -829,7 +829,7 @@ void LegoAnimPresenter::StartingTickle()
|
|||||||
ProgressTickleState(e_streaming);
|
ProgressTickleState(e_streaming);
|
||||||
|
|
||||||
if (m_compositePresenter && m_compositePresenter->IsA("LegoAnimMMPresenter")) {
|
if (m_compositePresenter && m_compositePresenter->IsA("LegoAnimMMPresenter")) {
|
||||||
m_localActors = ((LegoAnimMMPresenter*) m_compositePresenter)->FUN_1004b8b0();
|
m_localActors = ((LegoAnimMMPresenter*) m_compositePresenter)->UsesLocalActors();
|
||||||
m_compositePresenter->AdvanceSerialAction(this);
|
m_compositePresenter->AdvanceSerialAction(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@ -119,7 +119,7 @@ MxResult LegoVideoManager::Create(MxVideoParam& p_videoParam, MxU32 p_frequencyM
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (deviceNum < 0) {
|
if (deviceNum < 0) {
|
||||||
deviceEnumerate.FUN_1009d210();
|
deviceEnumerate.FilterSupportedDrivers();
|
||||||
deviceNum = deviceEnumerate.GetBestDevice();
|
deviceNum = deviceEnumerate.GetBestDevice();
|
||||||
deviceNum = deviceEnumerate.GetDevice(deviceNum, driver, device);
|
deviceNum = deviceEnumerate.GetDevice(deviceNum, driver, device);
|
||||||
}
|
}
|
||||||
@ -424,7 +424,7 @@ void LegoVideoManager::DrawFPS()
|
|||||||
GetTextExtentPoint(dc, zeros, strlen(zeros), &m_fpsSize);
|
GetTextExtentPoint(dc, zeros, strlen(zeros), &m_fpsSize);
|
||||||
ReleaseDC(NULL, dc);
|
ReleaseDC(NULL, dc);
|
||||||
|
|
||||||
m_unk0x528 = m_displaySurface->FUN_100bc8b0(m_fpsSize.cx, m_fpsSize.cy);
|
m_unk0x528 = m_displaySurface->Create16BitOffscreenSurface(m_fpsSize.cx, m_fpsSize.cy);
|
||||||
SetRect(&m_fpsRect, 0, 0, m_fpsSize.cx, m_fpsSize.cy);
|
SetRect(&m_fpsRect, 0, 0, m_fpsSize.cx, m_fpsSize.cy);
|
||||||
|
|
||||||
if (m_unk0x528 == NULL) {
|
if (m_unk0x528 == NULL) {
|
||||||
@ -674,7 +674,7 @@ void LegoVideoManager::UpdateView(MxU32 p_x, MxU32 p_y, MxU32 p_width, MxU32 p_h
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1007c520
|
// FUNCTION: LEGO1 0x1007c520
|
||||||
void LegoVideoManager::FUN_1007c520()
|
void LegoVideoManager::PrepareCreditsScreen()
|
||||||
{
|
{
|
||||||
m_unk0xe5 = TRUE;
|
m_unk0xe5 = TRUE;
|
||||||
m_render3d = FALSE;
|
m_render3d = FALSE;
|
||||||
|
|||||||
@ -578,7 +578,7 @@ MxLong Act3::Notify(MxParam& p_param)
|
|||||||
action.SetObjectId(Act3Script::c_pzhitdn_PlayWav);
|
action.SetObjectId(Act3Script::c_pzhitdn_PlayWav);
|
||||||
|
|
||||||
BackgroundAudioManager()->PlayMusic(action, 5, MxPresenter::e_repeating);
|
BackgroundAudioManager()->PlayMusic(action, 5, MxPresenter::e_repeating);
|
||||||
m_brickster->FUN_100417c0();
|
m_brickster->ChooseBricksterDestination();
|
||||||
|
|
||||||
m_cop1->SetActorState(LegoPathActor::c_initial);
|
m_cop1->SetActorState(LegoPathActor::c_initial);
|
||||||
m_cop1->SetWorldSpeed(2.0f);
|
m_cop1->SetWorldSpeed(2.0f);
|
||||||
@ -633,7 +633,7 @@ MxLong Act3::Notify(MxParam& p_param)
|
|||||||
}
|
}
|
||||||
case c_notificationKeyPress:
|
case c_notificationKeyPress:
|
||||||
if (m_state->m_state == Act3State::e_ready && ((LegoEventNotificationParam&) p_param).GetKey() == ' ') {
|
if (m_state->m_state == Act3State::e_ready && ((LegoEventNotificationParam&) p_param).GetKey() == ' ') {
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -679,11 +679,11 @@ void Act3::ReadyWorld()
|
|||||||
{
|
{
|
||||||
PlantManager()->SetInitialCounters();
|
PlantManager()->SetInitialCounters();
|
||||||
BuildingManager()->SetInitialCounters();
|
BuildingManager()->SetInitialCounters();
|
||||||
AnimationManager()->FUN_1005f6d0(FALSE);
|
AnimationManager()->EnableExtras(FALSE);
|
||||||
VideoManager()->Get3DManager()->SetFrustrum(90.0f, 0.1f, 125.0f);
|
VideoManager()->Get3DManager()->SetFrustrum(90.0f, 0.1f, 125.0f);
|
||||||
|
|
||||||
m_explanationAnimation = g_explanationAnimations[rand() % 3];
|
m_explanationAnimation = g_explanationAnimations[rand() % 3];
|
||||||
AnimationManager()->FUN_10060dc0(
|
AnimationManager()->StartManagedAnimation(
|
||||||
m_explanationAnimation,
|
m_explanationAnimation,
|
||||||
NULL,
|
NULL,
|
||||||
TRUE,
|
TRUE,
|
||||||
@ -707,7 +707,7 @@ MxResult Act3::Tickle()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (m_explanationAnimation != (Act3Script::Script) 0) {
|
if (m_explanationAnimation != (Act3Script::Script) 0) {
|
||||||
if (AnimationManager()->FUN_10064ee0(m_explanationAnimation)) {
|
if (AnimationManager()->IsAnimationFinished(m_explanationAnimation)) {
|
||||||
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
|
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
|
||||||
TickleManager()->UnregisterClient(this);
|
TickleManager()->UnregisterClient(this);
|
||||||
m_explanationAnimation = (Act3Script::Script) 0;
|
m_explanationAnimation = (Act3Script::Script) 0;
|
||||||
@ -722,7 +722,7 @@ MxResult Act3::Tickle()
|
|||||||
MxResult Act3::HitBrickster(Act3Ammo& p_ammo, const Vector3& p_param2)
|
MxResult Act3::HitBrickster(Act3Ammo& p_ammo, const Vector3& p_param2)
|
||||||
{
|
{
|
||||||
assert(m_brickster);
|
assert(m_brickster);
|
||||||
m_brickster->FUN_100417a0(p_ammo, p_param2);
|
m_brickster->RespondToAmmoHit(p_ammo, p_param2);
|
||||||
TriggerHitSound(1);
|
TriggerHitSound(1);
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
@ -734,10 +734,10 @@ MxResult Act3::HitCop(Act3Ammo& p_ammo, const Vector3& p_param2)
|
|||||||
assert(m_cop1 && m_cop2);
|
assert(m_cop1 && m_cop2);
|
||||||
|
|
||||||
if (!(g_copSelector & 1)) {
|
if (!(g_copSelector & 1)) {
|
||||||
m_cop1->FUN_10040350(p_ammo, p_param2);
|
m_cop1->RespondToAmmoHit(p_ammo, p_param2);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
m_cop2->FUN_10040350(p_ammo, p_param2);
|
m_cop2->RespondToAmmoHit(p_ammo, p_param2);
|
||||||
}
|
}
|
||||||
|
|
||||||
TriggerHitSound(3);
|
TriggerHitSound(3);
|
||||||
@ -792,7 +792,7 @@ void Act3::GoodEnding(const Matrix4& p_destination)
|
|||||||
|
|
||||||
#ifndef BETA10
|
#ifndef BETA10
|
||||||
m_soundList.Clear();
|
m_soundList.Clear();
|
||||||
m_copter->FUN_10004640(p_destination);
|
m_copter->StartGoodEndingFlight(p_destination);
|
||||||
|
|
||||||
DebugPrintf("In Good Ending...");
|
DebugPrintf("In Good Ending...");
|
||||||
DebugCopter(
|
DebugCopter(
|
||||||
@ -875,7 +875,7 @@ void Act3::BadEnding(const Matrix4& p_destination)
|
|||||||
m_brickster->SetActorState(LegoPathActor::c_disabled);
|
m_brickster->SetActorState(LegoPathActor::c_disabled);
|
||||||
|
|
||||||
m_soundList.Clear();
|
m_soundList.Clear();
|
||||||
m_copter->FUN_10004670(p_destination);
|
m_copter->StartBadEndingFlight(p_destination);
|
||||||
|
|
||||||
DebugPrintf("In Bad Ending...");
|
DebugPrintf("In Bad Ending...");
|
||||||
DebugCopter(
|
DebugCopter(
|
||||||
@ -985,7 +985,7 @@ void Act3::VTable0x60()
|
|||||||
MxBool Act3::Escape()
|
MxBool Act3::Escape()
|
||||||
{
|
{
|
||||||
BackgroundAudioManager()->Stop();
|
BackgroundAudioManager()->Stop();
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
DeleteObjects(&m_atomId, Act3Script::c_tlp053in_RunAnim, 999);
|
DeleteObjects(&m_atomId, Act3Script::c_tlp053in_RunAnim, 999);
|
||||||
m_destLocation = LegoGameState::e_infomain;
|
m_destLocation = LegoGameState::e_infomain;
|
||||||
return TRUE;
|
return TRUE;
|
||||||
|
|||||||
@ -1483,7 +1483,7 @@ void Infocenter::StartCredits()
|
|||||||
i++;
|
i++;
|
||||||
} while (i < m_infocenterState->GetMaxNameLength());
|
} while (i < m_infocenterState->GetMaxNameLength());
|
||||||
|
|
||||||
VideoManager()->FUN_1007c520();
|
VideoManager()->PrepareCreditsScreen();
|
||||||
GetViewManager()->RemoveAll(NULL);
|
GetViewManager()->RemoveAll(NULL);
|
||||||
|
|
||||||
InvokeAction(Extra::e_opendisk, *g_creditsScript, CreditsScript::c_LegoCredits, NULL);
|
InvokeAction(Extra::e_opendisk, *g_creditsScript, CreditsScript::c_LegoCredits, NULL);
|
||||||
|
|||||||
@ -494,22 +494,22 @@ MxLong Isle::HandlePathStruct(LegoPathStructNotificationParam& p_param)
|
|||||||
// These values correspond to certain paths on the island
|
// These values correspond to certain paths on the island
|
||||||
switch (p_param.GetData()) {
|
switch (p_param.GetData()) {
|
||||||
case 0x12c:
|
case 0x12c:
|
||||||
AnimationManager()->FUN_10064670(NULL);
|
AnimationManager()->SpawnBricksterAtPoliceStation(NULL);
|
||||||
result = 1;
|
result = 1;
|
||||||
break;
|
break;
|
||||||
case 0x12d:
|
case 0x12d:
|
||||||
AnimationManager()->FUN_10064880("brickstr", 0, 20000);
|
AnimationManager()->SetExtraActorTiming("brickstr", 0, 20000);
|
||||||
result = 1;
|
result = 1;
|
||||||
break;
|
break;
|
||||||
case 0x131:
|
case 0x131:
|
||||||
if (m_act1state->m_state != Act1State::e_ambulance) {
|
if (m_act1state->m_state != Act1State::e_ambulance) {
|
||||||
AnimationManager()->FUN_10064740(NULL);
|
AnimationManager()->SpawnParentsAtHospital(NULL);
|
||||||
}
|
}
|
||||||
result = 1;
|
result = 1;
|
||||||
break;
|
break;
|
||||||
case 0x132:
|
case 0x132:
|
||||||
AnimationManager()->FUN_10064880("mama", 0, 20000);
|
AnimationManager()->SetExtraActorTiming("mama", 0, 20000);
|
||||||
AnimationManager()->FUN_10064880("papa", 0, 20000);
|
AnimationManager()->SetExtraActorTiming("papa", 0, 20000);
|
||||||
result = 1;
|
result = 1;
|
||||||
break;
|
break;
|
||||||
case 0x136:
|
case 0x136:
|
||||||
@ -710,7 +710,7 @@ void Isle::Enable(MxBool p_enable)
|
|||||||
m_act1state->m_state = Act1State::e_none;
|
m_act1state->m_state = Act1State::e_none;
|
||||||
|
|
||||||
if (GameState()->m_currentArea == LegoGameState::e_pizzeriaExterior) {
|
if (GameState()->m_currentArea == LegoGameState::e_pizzeriaExterior) {
|
||||||
AnimationManager()->FUN_10064740(NULL);
|
AnimationManager()->SpawnParentsAtHospital(NULL);
|
||||||
}
|
}
|
||||||
else if (GameState()->m_currentArea == LegoGameState::e_vehicleExited) {
|
else if (GameState()->m_currentArea == LegoGameState::e_vehicleExited) {
|
||||||
Mx3DPointFloat position(UserActor()->GetROI()->GetWorldPosition());
|
Mx3DPointFloat position(UserActor()->GetROI()->GetWorldPosition());
|
||||||
@ -718,13 +718,13 @@ void Isle::Enable(MxBool p_enable)
|
|||||||
Mx3DPointFloat sub(-21.375f, 0.0f, -41.75f);
|
Mx3DPointFloat sub(-21.375f, 0.0f, -41.75f);
|
||||||
sub -= position;
|
sub -= position;
|
||||||
if (sub.LenSquared() < 1024.0f) {
|
if (sub.LenSquared() < 1024.0f) {
|
||||||
AnimationManager()->FUN_10064740(NULL);
|
AnimationManager()->SpawnParentsAtHospital(NULL);
|
||||||
}
|
}
|
||||||
|
|
||||||
Mx3DPointFloat sub2(98.874992f, 0.0f, -46.156292f);
|
Mx3DPointFloat sub2(98.874992f, 0.0f, -46.156292f);
|
||||||
sub2 -= position;
|
sub2 -= position;
|
||||||
if (sub2.LenSquared() < 1024.0f) {
|
if (sub2.LenSquared() < 1024.0f) {
|
||||||
AnimationManager()->FUN_10064670(NULL);
|
AnimationManager()->SpawnBricksterAtPoliceStation(NULL);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
@ -753,12 +753,12 @@ void Isle::Enable(MxBool p_enable)
|
|||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()
|
AnimationManager()
|
||||||
->FUN_10060dc0(script, NULL, TRUE, LegoAnimationManager::e_unk1, NULL, FALSE, FALSE, TRUE, FALSE);
|
->StartManagedAnimation(script, NULL, TRUE, LegoAnimationManager::e_unk1, NULL, FALSE, FALSE, TRUE, FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
m_act1state->m_state = Act1State::e_none;
|
m_act1state->m_state = Act1State::e_none;
|
||||||
EnableAnimations(FALSE);
|
EnableAnimations(FALSE);
|
||||||
AnimationManager()->FUN_10064670(NULL);
|
AnimationManager()->SpawnBricksterAtPoliceStation(NULL);
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case Act1State::e_transitionToRacecar: {
|
case Act1State::e_transitionToRacecar: {
|
||||||
@ -787,7 +787,7 @@ void Isle::Enable(MxBool p_enable)
|
|||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()
|
AnimationManager()
|
||||||
->FUN_10060dc0(script, NULL, TRUE, LegoAnimationManager::e_unk1, NULL, FALSE, FALSE, TRUE, FALSE);
|
->StartManagedAnimation(script, NULL, TRUE, LegoAnimationManager::e_unk1, NULL, FALSE, FALSE, TRUE, FALSE);
|
||||||
}
|
}
|
||||||
|
|
||||||
m_act1state->m_state = Act1State::e_none;
|
m_act1state->m_state = Act1State::e_none;
|
||||||
@ -797,7 +797,7 @@ void Isle::Enable(MxBool p_enable)
|
|||||||
case Act1State::e_transitionToTowtrack:
|
case Act1State::e_transitionToTowtrack:
|
||||||
m_act1state->m_state = Act1State::e_towtrack;
|
m_act1state->m_state = Act1State::e_towtrack;
|
||||||
|
|
||||||
AnimationManager()->FUN_1005f6d0(FALSE);
|
AnimationManager()->EnableExtras(FALSE);
|
||||||
AnimationManager()->EnableCamAnims(FALSE);
|
AnimationManager()->EnableCamAnims(FALSE);
|
||||||
|
|
||||||
g_isleFlags &= ~c_playMusic;
|
g_isleFlags &= ~c_playMusic;
|
||||||
@ -806,7 +806,7 @@ void Isle::Enable(MxBool p_enable)
|
|||||||
case Act1State::e_transitionToAmbulance:
|
case Act1State::e_transitionToAmbulance:
|
||||||
m_act1state->m_state = Act1State::e_ambulance;
|
m_act1state->m_state = Act1State::e_ambulance;
|
||||||
|
|
||||||
AnimationManager()->FUN_1005f6d0(FALSE);
|
AnimationManager()->EnableExtras(FALSE);
|
||||||
AnimationManager()->EnableCamAnims(FALSE);
|
AnimationManager()->EnableCamAnims(FALSE);
|
||||||
|
|
||||||
g_isleFlags &= ~c_playMusic;
|
g_isleFlags &= ~c_playMusic;
|
||||||
@ -1237,7 +1237,7 @@ MxBool Isle::Escape()
|
|||||||
|
|
||||||
m_act1state->m_elevFloor = Act1State::c_floor1;
|
m_act1state->m_elevFloor = Act1State::c_floor1;
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
DeleteObjects(&m_atomId, IsleScript::c_sba001bu_RunAnim, IsleScript::c_FNS018EN_Wav_518);
|
DeleteObjects(&m_atomId, IsleScript::c_sba001bu_RunAnim, IsleScript::c_FNS018EN_Wav_518);
|
||||||
|
|
||||||
if (UserActor()) {
|
if (UserActor()) {
|
||||||
@ -1284,7 +1284,7 @@ void Isle::SwitchToInfocenter()
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
|
|
||||||
if (UserActor()) {
|
if (UserActor()) {
|
||||||
if (UserActor()->GetActorId() != GameState()->GetActorId()) {
|
if (UserActor()->GetActorId() != GameState()->GetActorId()) {
|
||||||
|
|||||||
@ -191,7 +191,7 @@ MxResult LegoAct2::Tickle()
|
|||||||
break;
|
break;
|
||||||
case LegoAct2::e_holdingSpeech:
|
case LegoAct2::e_holdingSpeech:
|
||||||
if (g_bricksterSpeech) {
|
if (g_bricksterSpeech) {
|
||||||
if (AnimationManager()->FUN_10064ee0(g_bricksterSpeech)) {
|
if (AnimationManager()->IsAnimationFinished(g_bricksterSpeech)) {
|
||||||
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
|
Disable(FALSE, LegoOmni::c_disableInput | LegoOmni::c_disable3d | LegoOmni::c_clearScreen);
|
||||||
g_bricksterSpeech = (Act2mainScript::Script) 0;
|
g_bricksterSpeech = (Act2mainScript::Script) 0;
|
||||||
}
|
}
|
||||||
@ -206,9 +206,9 @@ MxResult LegoAct2::Tickle()
|
|||||||
StartAction(Act2mainScript::c_tja009ni_RunAnim, TRUE, TRUE, NULL, NULL, NULL);
|
StartAction(Act2mainScript::c_tja009ni_RunAnim, TRUE, TRUE, NULL, NULL, NULL);
|
||||||
|
|
||||||
AnimationManager()->EnableCamAnims(TRUE);
|
AnimationManager()->EnableCamAnims(TRUE);
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
AnimationManager()->FUN_100604f0(g_animationsBricksterIsLoose, sizeOfArray(g_animationsBricksterIsLoose));
|
AnimationManager()->EnableAnimationsByObjectId(g_animationsBricksterIsLoose, sizeOfArray(g_animationsBricksterIsLoose));
|
||||||
AnimationManager()->FUN_10060480(g_charactersBricksterIsLoose, sizeOfArray(g_charactersBricksterIsLoose));
|
AnimationManager()->EnableCharactersByName(g_charactersBricksterIsLoose, sizeOfArray(g_charactersBricksterIsLoose));
|
||||||
break;
|
break;
|
||||||
case LegoAct2::e_explaining:
|
case LegoAct2::e_explaining:
|
||||||
m_timeSinceLastStage += 50;
|
m_timeSinceLastStage += 50;
|
||||||
@ -413,9 +413,9 @@ MxLong LegoAct2::HandleEndAction(MxEndActionNotificationParam& p_param)
|
|||||||
StartAction(Act2mainScript::c_tra045la_RunAnim, TRUE, TRUE, NULL, NULL, NULL);
|
StartAction(Act2mainScript::c_tra045la_RunAnim, TRUE, TRUE, NULL, NULL, NULL);
|
||||||
((LegoPathActor*) m_pepper->GetEntity())->SetActorState(LegoPathActor::c_disabled);
|
((LegoPathActor*) m_pepper->GetEntity())->SetActorState(LegoPathActor::c_disabled);
|
||||||
AnimationManager()->EnableCamAnims(TRUE);
|
AnimationManager()->EnableCamAnims(TRUE);
|
||||||
AnimationManager()->FUN_1005f6d0(TRUE);
|
AnimationManager()->EnableExtras(TRUE);
|
||||||
AnimationManager()->FUN_100604f0(g_animationsAfterChase, sizeOfArray(g_animationsAfterChase));
|
AnimationManager()->EnableAnimationsByObjectId(g_animationsAfterChase, sizeOfArray(g_animationsAfterChase));
|
||||||
AnimationManager()->FUN_10060480(g_charactersAfterChase, sizeOfArray(g_charactersAfterChase));
|
AnimationManager()->EnableCharactersByName(g_charactersAfterChase, sizeOfArray(g_charactersAfterChase));
|
||||||
break;
|
break;
|
||||||
case LegoAct2::e_distributeRemainingBricks: {
|
case LegoAct2::e_distributeRemainingBricks: {
|
||||||
LegoROI* roi;
|
LegoROI* roi;
|
||||||
@ -713,10 +713,10 @@ void LegoAct2::DisableAnimations()
|
|||||||
if (AnimationManager()) {
|
if (AnimationManager()) {
|
||||||
AnimationManager()->Suspend();
|
AnimationManager()->Suspend();
|
||||||
AnimationManager()->Resume();
|
AnimationManager()->Resume();
|
||||||
AnimationManager()->FUN_10060540(FALSE);
|
AnimationManager()->SetAllAnimationsEnabled(FALSE);
|
||||||
AnimationManager()->FUN_100604d0(FALSE);
|
AnimationManager()->SetAllCharactersAnimationEnabled(FALSE);
|
||||||
AnimationManager()->EnableCamAnims(FALSE);
|
AnimationManager()->EnableCamAnims(FALSE);
|
||||||
AnimationManager()->FUN_1005f6d0(FALSE);
|
AnimationManager()->EnableExtras(FALSE);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -754,7 +754,7 @@ void LegoAct2::VTable0x60()
|
|||||||
MxBool LegoAct2::Escape()
|
MxBool LegoAct2::Escape()
|
||||||
{
|
{
|
||||||
BackgroundAudioManager()->Stop();
|
BackgroundAudioManager()->Stop();
|
||||||
AnimationManager()->FUN_10061010(FALSE);
|
AnimationManager()->StopAnimations(FALSE);
|
||||||
DeleteObjects(&m_atomId, Act2mainScript::c_snsx50bu_RunAnim, 999);
|
DeleteObjects(&m_atomId, Act2mainScript::c_snsx50bu_RunAnim, 999);
|
||||||
|
|
||||||
if (UserActor() != NULL) {
|
if (UserActor() != NULL) {
|
||||||
@ -1162,7 +1162,7 @@ MxResult LegoAct2::StartAction(
|
|||||||
MxResult result;
|
MxResult result;
|
||||||
|
|
||||||
if (p_objectId == Act2mainScript::c_tja009ni_RunAnim) {
|
if (p_objectId == Act2mainScript::c_tja009ni_RunAnim) {
|
||||||
result = AnimationManager()->FUN_10060dc0(
|
result = AnimationManager()->StartManagedAnimation(
|
||||||
p_objectId,
|
p_objectId,
|
||||||
pmatrix,
|
pmatrix,
|
||||||
TRUE,
|
TRUE,
|
||||||
@ -1175,7 +1175,7 @@ MxResult LegoAct2::StartAction(
|
|||||||
);
|
);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
result = AnimationManager()->FUN_10060dc0(
|
result = AnimationManager()->StartManagedAnimation(
|
||||||
p_objectId,
|
p_objectId,
|
||||||
pmatrix,
|
pmatrix,
|
||||||
TRUE,
|
TRUE,
|
||||||
|
|||||||
@ -97,7 +97,7 @@ struct LegoOrientedEdge : public LegoEdge {
|
|||||||
// FUNCTION: BETA10 0x101841b0
|
// FUNCTION: BETA10 0x101841b0
|
||||||
void SetFlags(LegoU16 p_flags) { m_flags = p_flags; }
|
void SetFlags(LegoU16 p_flags) { m_flags = p_flags; }
|
||||||
|
|
||||||
inline LegoU32 FUN_10048c40(const Vector3& p_position);
|
inline LegoU32 ContainsPointOnEdge(const Vector3& p_position);
|
||||||
|
|
||||||
// SYNTHETIC: LEGO1 0x1009a6c0
|
// SYNTHETIC: LEGO1 0x1009a6c0
|
||||||
// SYNTHETIC: BETA10 0x101840f0
|
// SYNTHETIC: BETA10 0x101840f0
|
||||||
@ -113,7 +113,7 @@ struct LegoOrientedEdge : public LegoEdge {
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x10048c40
|
// FUNCTION: LEGO1 0x10048c40
|
||||||
// FUNCTION: BETA10 0x1001cc90
|
// FUNCTION: BETA10 0x1001cc90
|
||||||
inline LegoU32 LegoOrientedEdge::FUN_10048c40(const Vector3& p_position)
|
inline LegoU32 LegoOrientedEdge::ContainsPointOnEdge(const Vector3& p_position)
|
||||||
{
|
{
|
||||||
LegoFloat localc, local10;
|
LegoFloat localc, local10;
|
||||||
LegoU32 result = FALSE;
|
LegoU32 result = FALSE;
|
||||||
|
|||||||
@ -291,7 +291,7 @@ int LegoDeviceEnumerate::SupportsCPUID()
|
|||||||
// FUNCTION: CONFIG 0x004029a0
|
// FUNCTION: CONFIG 0x004029a0
|
||||||
// FUNCTION: LEGO1 0x1009d210
|
// FUNCTION: LEGO1 0x1009d210
|
||||||
// FUNCTION: BETA10 0x1011cfc4
|
// FUNCTION: BETA10 0x1011cfc4
|
||||||
int LegoDeviceEnumerate::FUN_1009d210()
|
int LegoDeviceEnumerate::FilterSupportedDrivers()
|
||||||
{
|
{
|
||||||
if (!IsInitialized()) {
|
if (!IsInitialized()) {
|
||||||
return -1;
|
return -1;
|
||||||
@ -306,7 +306,7 @@ int LegoDeviceEnumerate::FUN_1009d210()
|
|||||||
MxDriver& driver = *it;
|
MxDriver& driver = *it;
|
||||||
|
|
||||||
for (list<Direct3DDeviceInfo>::iterator it2 = driver.m_devices.begin(); it2 != driver.m_devices.end();) {
|
for (list<Direct3DDeviceInfo>::iterator it2 = driver.m_devices.begin(); it2 != driver.m_devices.end();) {
|
||||||
if (!FUN_1009d3d0(*it2)) {
|
if (!DeviceSupportsRequiredCaps(*it2)) {
|
||||||
driver.m_devices.erase(it2++);
|
driver.m_devices.erase(it2++);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -349,7 +349,7 @@ unsigned char LegoDeviceEnumerate::DriverSupportsRequiredDisplayMode(MxDriver& p
|
|||||||
// FUNCTION: CONFIG 0x00402b60
|
// FUNCTION: CONFIG 0x00402b60
|
||||||
// FUNCTION: LEGO1 0x1009d3d0
|
// FUNCTION: LEGO1 0x1009d3d0
|
||||||
// FUNCTION: BETA10 0x1011d235
|
// FUNCTION: BETA10 0x1011d235
|
||||||
unsigned char LegoDeviceEnumerate::FUN_1009d3d0(Direct3DDeviceInfo& p_device)
|
unsigned char LegoDeviceEnumerate::DeviceSupportsRequiredCaps(Direct3DDeviceInfo& p_device)
|
||||||
{
|
{
|
||||||
if (m_ddInfo.size() <= 0) {
|
if (m_ddInfo.size() <= 0) {
|
||||||
return FALSE;
|
return FALSE;
|
||||||
|
|||||||
@ -17,9 +17,9 @@ class LegoDeviceEnumerate : public MxDeviceEnumerate {
|
|||||||
int GetBestDevice();
|
int GetBestDevice();
|
||||||
static int SupportsMMX();
|
static int SupportsMMX();
|
||||||
static int SupportsCPUID();
|
static int SupportsCPUID();
|
||||||
int FUN_1009d210();
|
int FilterSupportedDrivers();
|
||||||
unsigned char DriverSupportsRequiredDisplayMode(MxDriver& p_driver);
|
unsigned char DriverSupportsRequiredDisplayMode(MxDriver& p_driver);
|
||||||
unsigned char FUN_1009d3d0(Direct3DDeviceInfo& p_device);
|
unsigned char DeviceSupportsRequiredCaps(Direct3DDeviceInfo& p_device);
|
||||||
|
|
||||||
// SYNTHETIC: BETA10 0x100d8d10
|
// SYNTHETIC: BETA10 0x100d8d10
|
||||||
// LegoDeviceEnumerate::LegoDeviceEnumerate
|
// LegoDeviceEnumerate::LegoDeviceEnumerate
|
||||||
|
|||||||
@ -71,7 +71,7 @@ BOOL MxDirect3D::Create(
|
|||||||
|
|
||||||
done:
|
done:
|
||||||
if (!success) {
|
if (!success) {
|
||||||
FUN_1009d920();
|
RestoreDisplayMode();
|
||||||
}
|
}
|
||||||
|
|
||||||
return success;
|
return success;
|
||||||
|
|||||||
@ -208,7 +208,7 @@ void MxDirectDraw::Destroy()
|
|||||||
{
|
{
|
||||||
DestroyButNotDirectDraw();
|
DestroyButNotDirectDraw();
|
||||||
|
|
||||||
FUN_1009d920();
|
RestoreDisplayMode();
|
||||||
|
|
||||||
RELEASE(m_pDirectDraw);
|
RELEASE(m_pDirectDraw);
|
||||||
|
|
||||||
@ -244,7 +244,7 @@ void MxDirectDraw::DestroyButNotDirectDraw()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x1009d920
|
// FUNCTION: LEGO1 0x1009d920
|
||||||
// FUNCTION: BETA10 0x10120b9e
|
// FUNCTION: BETA10 0x10120b9e
|
||||||
void MxDirectDraw::FUN_1009d920()
|
void MxDirectDraw::RestoreDisplayMode()
|
||||||
{
|
{
|
||||||
RestoreOriginalPaletteEntries();
|
RestoreOriginalPaletteEntries();
|
||||||
if (m_pDirectDraw != NULL) {
|
if (m_pDirectDraw != NULL) {
|
||||||
|
|||||||
@ -80,7 +80,7 @@ class MxDirectDraw {
|
|||||||
|
|
||||||
BOOL RecreateDirectDraw(GUID** a2);
|
BOOL RecreateDirectDraw(GUID** a2);
|
||||||
void ClearBackBuffers();
|
void ClearBackBuffers();
|
||||||
void FUN_1009d920();
|
void RestoreDisplayMode();
|
||||||
|
|
||||||
// SYNTHETIC: LEGO1 0x1009d510
|
// SYNTHETIC: LEGO1 0x1009d510
|
||||||
// SYNTHETIC: BETA10 0x10122f80
|
// SYNTHETIC: BETA10 0x10122f80
|
||||||
|
|||||||
@ -45,12 +45,12 @@ class MxDiskStreamController : public MxStreamController {
|
|||||||
|
|
||||||
MxBool GetUnk0xc4() const { return m_unk0xc4; }
|
MxBool GetUnk0xc4() const { return m_unk0xc4; }
|
||||||
|
|
||||||
MxResult FUN_100c7890(MxDSStreamingAction* p_action);
|
MxResult QueueReadAheadAction(MxDSStreamingAction* p_action);
|
||||||
void FUN_100c7cb0(MxDSStreamingAction* p_action);
|
void DeleteStreamingAction(MxDSStreamingAction* p_action);
|
||||||
void FUN_100c7f40(MxDSStreamingAction* p_streamingaction);
|
void QueueCompletedRead(MxDSStreamingAction* p_streamingaction);
|
||||||
void FUN_100c8120(MxDSAction* p_action);
|
void CancelDiskAction(MxDSAction* p_action);
|
||||||
void InsertToList74(MxDSBuffer* p_buffer);
|
void InsertToList74(MxDSBuffer* p_buffer);
|
||||||
void FUN_100c8670(MxDSStreamingAction* p_streamingAction);
|
void QueueActionForDeletion(MxDSStreamingAction* p_streamingAction);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
MxDSObjectList m_list0x64; // 0x64
|
MxDSObjectList m_list0x64; // 0x64
|
||||||
@ -63,14 +63,14 @@ class MxDiskStreamController : public MxStreamController {
|
|||||||
MxDSObjectList m_list0xb8; // 0xb8
|
MxDSObjectList m_list0xb8; // 0xb8
|
||||||
MxBool m_unk0xc4; // 0xc4
|
MxBool m_unk0xc4; // 0xc4
|
||||||
|
|
||||||
void FUN_100c7970();
|
void OnReadAheadQueued();
|
||||||
void FUN_100c7ce0(MxDSBuffer* p_buffer);
|
void ReleaseStreamBuffer(MxDSBuffer* p_buffer);
|
||||||
MxResult FUN_100c7d10();
|
MxResult ProcessNextCachedRead();
|
||||||
void FUN_100c7980();
|
void ScheduleNextDiskRead();
|
||||||
MxDSStreamingAction* FUN_100c7db0();
|
MxDSStreamingAction* PopReadyStreamingAction();
|
||||||
MxResult FUN_100c8360(MxDSStreamingAction* p_action);
|
MxResult ConsumeStreamBuffer(MxDSStreamingAction* p_action);
|
||||||
void FUN_100c8540();
|
void PurgeReleasedBuffers();
|
||||||
void FUN_100c8720();
|
void DeleteQueuedActions();
|
||||||
};
|
};
|
||||||
|
|
||||||
// TEMPLATE: LEGO1 0x100c14d0
|
// TEMPLATE: LEGO1 0x100c14d0
|
||||||
|
|||||||
@ -44,10 +44,10 @@ class MxDiskStreamProvider : public MxStreamProvider {
|
|||||||
}
|
}
|
||||||
|
|
||||||
MxResult WaitForWorkToComplete();
|
MxResult WaitForWorkToComplete();
|
||||||
MxResult FUN_100d1780(MxDSStreamingAction* p_action);
|
MxResult QueueDiskRead(MxDSStreamingAction* p_action);
|
||||||
void PerformWork();
|
void PerformWork();
|
||||||
static MxBool FUN_100d1af0(MxDSStreamingAction* p_action);
|
static MxBool CanStartReadNow(MxDSStreamingAction* p_action);
|
||||||
MxResult FUN_100d1b20(MxDSStreamingAction* p_action);
|
MxResult StitchSplitStreamBuffer(MxDSStreamingAction* p_action);
|
||||||
|
|
||||||
MxResult SetResourceToGet(MxStreamController* p_resource) override; // vtable+0x14
|
MxResult SetResourceToGet(MxStreamController* p_resource) override; // vtable+0x14
|
||||||
MxU32 GetFileSize() override; // vtable+0x18
|
MxU32 GetFileSize() override; // vtable+0x18
|
||||||
|
|||||||
@ -109,7 +109,7 @@ class MxDisplaySurface : public MxCore {
|
|||||||
MxU8 p_bpp
|
MxU8 p_bpp
|
||||||
);
|
);
|
||||||
|
|
||||||
LPDIRECTDRAWSURFACE FUN_100bc8b0(MxS32 p_width, MxS32 p_height);
|
LPDIRECTDRAWSURFACE Create16BitOffscreenSurface(MxS32 p_width, MxS32 p_height);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
MxU8 CountTotalBitsSetTo1(MxU32 p_param);
|
MxU8 CountTotalBitsSetTo1(MxU32 p_param);
|
||||||
|
|||||||
@ -35,7 +35,7 @@ class MxDSBuffer : public MxCore {
|
|||||||
|
|
||||||
MxResult AllocateBuffer(MxU32 p_bufferSize, Type p_mode);
|
MxResult AllocateBuffer(MxU32 p_bufferSize, Type p_mode);
|
||||||
MxResult SetBufferPointer(MxU8* p_buffer, MxU32 p_size);
|
MxResult SetBufferPointer(MxU8* p_buffer, MxU32 p_size);
|
||||||
MxResult FUN_100c67b0(
|
MxResult ParseDataChunks(
|
||||||
MxStreamController* p_controller,
|
MxStreamController* p_controller,
|
||||||
MxDSAction* p_action,
|
MxDSAction* p_action,
|
||||||
MxDSStreamingAction** p_streamingAction
|
MxDSStreamingAction** p_streamingAction
|
||||||
@ -58,9 +58,9 @@ class MxDSBuffer : public MxCore {
|
|||||||
MxU8 ReleaseRef(MxDSChunk*);
|
MxU8 ReleaseRef(MxDSChunk*);
|
||||||
void AddRef(MxDSChunk* p_chunk);
|
void AddRef(MxDSChunk* p_chunk);
|
||||||
MxResult CalcBytesRemaining(MxU8* p_data);
|
MxResult CalcBytesRemaining(MxU8* p_data);
|
||||||
void FUN_100c6f80(MxU32 p_writeOffset);
|
void SeekBufferCursor(MxU32 p_writeOffset);
|
||||||
MxU8* FUN_100c6fa0(MxU8* p_data);
|
MxU8* FindNextChunk(MxU8* p_data);
|
||||||
MxResult FUN_100c7090(MxDSBuffer* p_buf);
|
MxResult CopyBufferStateFrom(MxDSBuffer* p_buf);
|
||||||
|
|
||||||
static MxCore* ReadChunk(MxDSBuffer* p_buffer, MxU32* p_chunkData, MxU16 p_flags);
|
static MxCore* ReadChunk(MxDSBuffer* p_buffer, MxU32* p_chunkData, MxU16 p_flags);
|
||||||
static MxResult Append(MxU8* p_buffer1, MxU8* p_buffer2);
|
static MxResult Append(MxU8* p_buffer1, MxU8* p_buffer2);
|
||||||
|
|||||||
@ -20,7 +20,7 @@ class MxDSStreamingAction : public MxDSAction {
|
|||||||
|
|
||||||
void Init();
|
void Init();
|
||||||
void SetInternalAction(MxDSAction* p_dsAction);
|
void SetInternalAction(MxDSAction* p_dsAction);
|
||||||
void FUN_100cd2d0();
|
void AdvanceLoopPlaybackWindow();
|
||||||
|
|
||||||
// FUNCTION: BETA10 0x10156530
|
// FUNCTION: BETA10 0x10156530
|
||||||
MxU32 GetUnknown94() { return m_unk0x94; }
|
MxU32 GetUnknown94() { return m_unk0x94; }
|
||||||
|
|||||||
@ -62,10 +62,10 @@ class MxStreamController : public MxCore {
|
|||||||
|
|
||||||
void AddSubscriber(MxDSSubscriber* p_subscriber);
|
void AddSubscriber(MxDSSubscriber* p_subscriber);
|
||||||
void RemoveSubscriber(MxDSSubscriber* p_subscriber);
|
void RemoveSubscriber(MxDSSubscriber* p_subscriber);
|
||||||
MxResult FUN_100c1800(MxDSAction* p_action, MxU32 p_val);
|
MxResult QueueNextActionDataStart(MxDSAction* p_action, MxU32 p_val);
|
||||||
MxResult FUN_100c1a00(MxDSAction* p_action, MxU32 p_offset);
|
MxResult CreateStreamingAction(MxDSAction* p_action, MxU32 p_offset);
|
||||||
MxPresenter* FUN_100c1e70(MxDSAction& p_action);
|
MxPresenter* FindPresenterForAction(MxDSAction& p_action);
|
||||||
MxResult FUN_100c1f00(MxDSAction* p_action);
|
MxResult SendEndOfStreamChunk(MxDSAction* p_action);
|
||||||
MxBool IsStoped(MxDSObject* p_obj);
|
MxBool IsStoped(MxDSObject* p_obj);
|
||||||
MxResult InsertActionToList54(MxDSAction* p_action);
|
MxResult InsertActionToList54(MxDSAction* p_action);
|
||||||
MxNextActionDataStart* FindNextActionDataStartFromStreamingAction(MxDSStreamingAction* p_action);
|
MxNextActionDataStart* FindNextActionDataStartFromStreamingAction(MxDSStreamingAction* p_action);
|
||||||
|
|||||||
@ -72,11 +72,11 @@ class MxStreamer : public MxCore {
|
|||||||
|
|
||||||
virtual MxResult Create(); // vtable+0x14
|
virtual MxResult Create(); // vtable+0x14
|
||||||
|
|
||||||
MxBool FUN_100b9b30(MxDSObject& p_dsObject);
|
MxBool IsObjectStopped(MxDSObject& p_dsObject);
|
||||||
MxStreamController* GetOpenStream(const char* p_name);
|
MxStreamController* GetOpenStream(const char* p_name);
|
||||||
void FUN_100b98f0(MxDSAction* p_action);
|
void StopDiskAction(MxDSAction* p_action);
|
||||||
MxResult AddStreamControllerToOpenList(MxStreamController* p_stream);
|
MxResult AddStreamControllerToOpenList(MxStreamController* p_stream);
|
||||||
MxResult FUN_100b99b0(MxDSAction* p_action);
|
MxResult StartObjectStreaming(MxDSAction* p_action);
|
||||||
MxResult DeleteObject(MxDSAction* p_dsAction);
|
MxResult DeleteObject(MxDSAction* p_dsAction);
|
||||||
|
|
||||||
// FUNCTION: BETA10 0x10158db0
|
// FUNCTION: BETA10 0x10158db0
|
||||||
|
|||||||
@ -87,7 +87,7 @@ void MxDSStreamingAction::SetInternalAction(MxDSAction* p_dsAction)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100cd2d0
|
// FUNCTION: LEGO1 0x100cd2d0
|
||||||
void MxDSStreamingAction::FUN_100cd2d0()
|
void MxDSStreamingAction::AdvanceLoopPlaybackWindow()
|
||||||
{
|
{
|
||||||
if (m_duration == -1) {
|
if (m_duration == -1) {
|
||||||
return;
|
return;
|
||||||
|
|||||||
@ -232,7 +232,7 @@ MxResult MxOmni::Start(MxDSAction* p_dsAction)
|
|||||||
{
|
{
|
||||||
MxResult result = FAILURE;
|
MxResult result = FAILURE;
|
||||||
if (p_dsAction->GetAtomId().GetInternal() != NULL && p_dsAction->GetObjectId() != -1 && m_streamer != NULL) {
|
if (p_dsAction->GetAtomId().GetInternal() != NULL && p_dsAction->GetObjectId() != -1 && m_streamer != NULL) {
|
||||||
result = m_streamer->FUN_100b99b0(p_dsAction);
|
result = m_streamer->StartObjectStreaming(p_dsAction);
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
@ -259,7 +259,7 @@ MxResult MxOmni::CreatePresenter(MxStreamController* p_controller, MxDSAction& p
|
|||||||
if (object->AddToManager() == SUCCESS) {
|
if (object->AddToManager() == SUCCESS) {
|
||||||
MxPresenter* sender = p_action.GetUnknown28();
|
MxPresenter* sender = p_action.GetUnknown28();
|
||||||
if (!sender) {
|
if (!sender) {
|
||||||
sender = p_controller->FUN_100c1e70(p_action);
|
sender = p_controller->FindPresenterForAction(p_action);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (sender) {
|
if (sender) {
|
||||||
@ -407,7 +407,7 @@ void MxOmni::SetSound3D(MxBool p_use3dSound)
|
|||||||
// FUNCTION: BETA10 0x101309f5
|
// FUNCTION: BETA10 0x101309f5
|
||||||
MxBool MxOmni::DoesEntityExist(MxDSAction& p_dsAction)
|
MxBool MxOmni::DoesEntityExist(MxDSAction& p_dsAction)
|
||||||
{
|
{
|
||||||
if (m_streamer->FUN_100b9b30(p_dsAction)) {
|
if (m_streamer->IsObjectStopped(p_dsAction)) {
|
||||||
MxNotificationPtrList* notifications = m_notificationManager->GetQueue();
|
MxNotificationPtrList* notifications = m_notificationManager->GetQueue();
|
||||||
|
|
||||||
if (!notifications || notifications->size() == 0) {
|
if (!notifications || notifications->size() == 0) {
|
||||||
|
|||||||
@ -50,20 +50,20 @@ MxDiskStreamController::~MxDiskStreamController()
|
|||||||
m_provider = NULL;
|
m_provider = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_100c8720();
|
DeleteQueuedActions();
|
||||||
|
|
||||||
while (m_list0x80.PopFront(object)) {
|
while (m_list0x80.PopFront(object)) {
|
||||||
FUN_100c7cb0((MxDSStreamingAction*) object);
|
DeleteStreamingAction((MxDSStreamingAction*) object);
|
||||||
}
|
}
|
||||||
|
|
||||||
while (m_list0x64.PopFront(object)) {
|
while (m_list0x64.PopFront(object)) {
|
||||||
FUN_100c7cb0((MxDSStreamingAction*) object);
|
DeleteStreamingAction((MxDSStreamingAction*) object);
|
||||||
}
|
}
|
||||||
|
|
||||||
while (!m_list0x74.empty()) {
|
while (!m_list0x74.empty()) {
|
||||||
MxDSBuffer* buffer = m_list0x74.front();
|
MxDSBuffer* buffer = m_list0x74.front();
|
||||||
m_list0x74.pop_front();
|
m_list0x74.pop_front();
|
||||||
FUN_100c7ce0(buffer);
|
ReleaseStreamBuffer(buffer);
|
||||||
}
|
}
|
||||||
|
|
||||||
TickleManager()->UnregisterClient(this);
|
TickleManager()->UnregisterClient(this);
|
||||||
@ -107,7 +107,7 @@ MxResult MxDiskStreamController::VTable0x18(undefined4, undefined4)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7890
|
// FUNCTION: LEGO1 0x100c7890
|
||||||
// FUNCTION: BETA10 0x101543bb
|
// FUNCTION: BETA10 0x101543bb
|
||||||
MxResult MxDiskStreamController::FUN_100c7890(MxDSStreamingAction* p_action)
|
MxResult MxDiskStreamController::QueueReadAheadAction(MxDSStreamingAction* p_action)
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
if (p_action == NULL) {
|
if (p_action == NULL) {
|
||||||
@ -115,7 +115,7 @@ MxResult MxDiskStreamController::FUN_100c7890(MxDSStreamingAction* p_action)
|
|||||||
}
|
}
|
||||||
|
|
||||||
m_list0x80.PushBack(p_action);
|
m_list0x80.PushBack(p_action);
|
||||||
FUN_100c7970();
|
OnReadAheadQueued();
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -126,14 +126,14 @@ MxResult MxDiskStreamController::VTable0x34(undefined4)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7970
|
// FUNCTION: LEGO1 0x100c7970
|
||||||
void MxDiskStreamController::FUN_100c7970()
|
void MxDiskStreamController::OnReadAheadQueued()
|
||||||
{
|
{
|
||||||
// Empty
|
// Empty
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7980
|
// FUNCTION: LEGO1 0x100c7980
|
||||||
// FUNCTION: BETA10 0x10154848
|
// FUNCTION: BETA10 0x10154848
|
||||||
void MxDiskStreamController::FUN_100c7980()
|
void MxDiskStreamController::ScheduleNextDiskRead()
|
||||||
{
|
{
|
||||||
MxDSBuffer* buffer;
|
MxDSBuffer* buffer;
|
||||||
MxDSStreamingAction* action = NULL;
|
MxDSStreamingAction* action = NULL;
|
||||||
@ -165,7 +165,7 @@ void MxDiskStreamController::FUN_100c7980()
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (action) {
|
if (action) {
|
||||||
((MxDiskStreamProvider*) m_provider)->FUN_100d1780(action);
|
((MxDiskStreamProvider*) m_provider)->QueueDiskRead(action);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -211,7 +211,7 @@ MxResult MxDiskStreamController::VTable0x30(MxDSAction* p_action)
|
|||||||
if (item == NULL) {
|
if (item == NULL) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
FUN_100c7cb0(item);
|
DeleteStreamingAction(item);
|
||||||
}
|
}
|
||||||
|
|
||||||
while (TRUE) {
|
while (TRUE) {
|
||||||
@ -219,24 +219,24 @@ MxResult MxDiskStreamController::VTable0x30(MxDSAction* p_action)
|
|||||||
if (item == NULL) {
|
if (item == NULL) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
FUN_100c7cb0(item);
|
DeleteStreamingAction(item);
|
||||||
}
|
}
|
||||||
|
|
||||||
return result;
|
return result;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7cb0
|
// FUNCTION: LEGO1 0x100c7cb0
|
||||||
void MxDiskStreamController::FUN_100c7cb0(MxDSStreamingAction* p_action)
|
void MxDiskStreamController::DeleteStreamingAction(MxDSStreamingAction* p_action)
|
||||||
{
|
{
|
||||||
if (p_action->GetUnknowna0()) {
|
if (p_action->GetUnknowna0()) {
|
||||||
FUN_100c7ce0(p_action->GetUnknowna0());
|
ReleaseStreamBuffer(p_action->GetUnknowna0());
|
||||||
}
|
}
|
||||||
p_action->SetUnknowna0(NULL);
|
p_action->SetUnknowna0(NULL);
|
||||||
delete p_action;
|
delete p_action;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7ce0
|
// FUNCTION: LEGO1 0x100c7ce0
|
||||||
void MxDiskStreamController::FUN_100c7ce0(MxDSBuffer* p_buffer)
|
void MxDiskStreamController::ReleaseStreamBuffer(MxDSBuffer* p_buffer)
|
||||||
{
|
{
|
||||||
switch (p_buffer->GetMode()) {
|
switch (p_buffer->GetMode()) {
|
||||||
case MxDSBuffer::e_chunk:
|
case MxDSBuffer::e_chunk:
|
||||||
@ -249,18 +249,18 @@ void MxDiskStreamController::FUN_100c7ce0(MxDSBuffer* p_buffer)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7d10
|
// FUNCTION: LEGO1 0x100c7d10
|
||||||
MxResult MxDiskStreamController::FUN_100c7d10()
|
MxResult MxDiskStreamController::ProcessNextCachedRead()
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
MxDSStreamingAction* action = FUN_100c7db0();
|
MxDSStreamingAction* action = PopReadyStreamingAction();
|
||||||
|
|
||||||
if (!action) {
|
if (!action) {
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (FUN_100c8360(action) != SUCCESS) {
|
if (ConsumeStreamBuffer(action) != SUCCESS) {
|
||||||
VTable0x24(action);
|
VTable0x24(action);
|
||||||
FUN_100c7cb0(action);
|
DeleteStreamingAction(action);
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -269,7 +269,7 @@ MxResult MxDiskStreamController::FUN_100c7d10()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7db0
|
// FUNCTION: LEGO1 0x100c7db0
|
||||||
// FUNCTION: BETA10 0x101551d0
|
// FUNCTION: BETA10 0x101551d0
|
||||||
MxDSStreamingAction* MxDiskStreamController::FUN_100c7db0()
|
MxDSStreamingAction* MxDiskStreamController::PopReadyStreamingAction()
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
|
|
||||||
@ -298,7 +298,7 @@ MxDSStreamingAction* MxDiskStreamController::FUN_100c7db0()
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7f40
|
// FUNCTION: LEGO1 0x100c7f40
|
||||||
// FUNCTION: BETA10 0x101553e0
|
// FUNCTION: BETA10 0x101553e0
|
||||||
void MxDiskStreamController::FUN_100c7f40(MxDSStreamingAction* p_streamingaction)
|
void MxDiskStreamController::QueueCompletedRead(MxDSStreamingAction* p_streamingaction)
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
if (p_streamingaction) {
|
if (p_streamingaction) {
|
||||||
@ -320,7 +320,7 @@ MxResult MxDiskStreamController::VTable0x20(MxDSAction* p_action)
|
|||||||
action->SetOrigin(entry->GetOrigin());
|
action->SetOrigin(entry->GetOrigin());
|
||||||
action->SetUnknowna0(entry->GetUnknowna4());
|
action->SetUnknowna0(entry->GetUnknowna4());
|
||||||
|
|
||||||
FUN_100c7f40(action);
|
QueueCompletedRead(action);
|
||||||
|
|
||||||
if (VTable0x2c(p_action, entry->GetUnknown94()) != SUCCESS) {
|
if (VTable0x2c(p_action, entry->GetUnknown94()) != SUCCESS) {
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
@ -336,7 +336,7 @@ MxResult MxDiskStreamController::VTable0x20(MxDSAction* p_action)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c8120
|
// FUNCTION: LEGO1 0x100c8120
|
||||||
void MxDiskStreamController::FUN_100c8120(MxDSAction* p_action)
|
void MxDiskStreamController::CancelDiskAction(MxDSAction* p_action)
|
||||||
{
|
{
|
||||||
VTable0x30(p_action);
|
VTable0x30(p_action);
|
||||||
|
|
||||||
@ -389,13 +389,13 @@ MxResult MxDiskStreamController::VTable0x24(MxDSAction* p_action)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c8360
|
// FUNCTION: LEGO1 0x100c8360
|
||||||
MxResult MxDiskStreamController::FUN_100c8360(MxDSStreamingAction* p_action)
|
MxResult MxDiskStreamController::ConsumeStreamBuffer(MxDSStreamingAction* p_action)
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
MxDSBuffer* buffer = p_action->GetUnknowna0();
|
MxDSBuffer* buffer = p_action->GetUnknowna0();
|
||||||
MxDSStreamingAction* action2 = (MxDSStreamingAction*) m_list0x90.FindAndErase(p_action);
|
MxDSStreamingAction* action2 = (MxDSStreamingAction*) m_list0x90.FindAndErase(p_action);
|
||||||
buffer->FUN_100c6f80(p_action->GetUnknown94() - p_action->GetBufferOffset());
|
buffer->SeekBufferCursor(p_action->GetUnknown94() - p_action->GetBufferOffset());
|
||||||
buffer->FUN_100c67b0(this, p_action, &action2);
|
buffer->ParseDataChunks(this, p_action, &action2);
|
||||||
|
|
||||||
if (buffer->GetRefCount()) {
|
if (buffer->GetRefCount()) {
|
||||||
p_action->SetUnknowna0(NULL);
|
p_action->SetUnknowna0(NULL);
|
||||||
@ -404,7 +404,7 @@ MxResult MxDiskStreamController::FUN_100c8360(MxDSStreamingAction* p_action)
|
|||||||
|
|
||||||
if (action2) {
|
if (action2) {
|
||||||
if (action2->GetUnknowna0() == NULL) {
|
if (action2->GetUnknowna0() == NULL) {
|
||||||
FUN_100c7cb0(action2);
|
DeleteStreamingAction(action2);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (action2->GetObjectId() == -1) {
|
if (action2->GetObjectId() == -1) {
|
||||||
@ -415,7 +415,7 @@ MxResult MxDiskStreamController::FUN_100c8360(MxDSStreamingAction* p_action)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_100c7cb0(p_action);
|
DeleteStreamingAction(p_action);
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -428,14 +428,14 @@ void MxDiskStreamController::InsertToList74(MxDSBuffer* p_buffer)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c8540
|
// FUNCTION: LEGO1 0x100c8540
|
||||||
// FUNCTION: BETA10 0x10155a05
|
// FUNCTION: BETA10 0x10155a05
|
||||||
void MxDiskStreamController::FUN_100c8540()
|
void MxDiskStreamController::PurgeReleasedBuffers()
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
for (list<MxDSBuffer*>::iterator it = m_list0x74.begin(); it != m_list0x74.end();) {
|
for (list<MxDSBuffer*>::iterator it = m_list0x74.begin(); it != m_list0x74.end();) {
|
||||||
MxDSBuffer* buf = *it;
|
MxDSBuffer* buf = *it;
|
||||||
if (buf->GetRefCount() == 0) {
|
if (buf->GetRefCount() == 0) {
|
||||||
m_list0x74.erase(it++);
|
m_list0x74.erase(it++);
|
||||||
FUN_100c7ce0(buf);
|
ReleaseStreamBuffer(buf);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
it++;
|
it++;
|
||||||
@ -446,7 +446,7 @@ void MxDiskStreamController::FUN_100c8540()
|
|||||||
while (!m_list0x64.empty()) {
|
while (!m_list0x64.empty()) {
|
||||||
MxDSStreamingAction* action = (MxDSStreamingAction*) m_list0x64.front();
|
MxDSStreamingAction* action = (MxDSStreamingAction*) m_list0x64.front();
|
||||||
m_list0x64.pop_front();
|
m_list0x64.pop_front();
|
||||||
FUN_100c7cb0(action);
|
DeleteStreamingAction(action);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -456,28 +456,28 @@ void MxDiskStreamController::FUN_100c8540()
|
|||||||
MxResult MxDiskStreamController::Tickle()
|
MxResult MxDiskStreamController::Tickle()
|
||||||
{
|
{
|
||||||
if (m_unk0xc4) {
|
if (m_unk0xc4) {
|
||||||
FUN_100c7d10();
|
ProcessNextCachedRead();
|
||||||
}
|
}
|
||||||
|
|
||||||
FUN_100c8540();
|
PurgeReleasedBuffers();
|
||||||
FUN_100c8720();
|
DeleteQueuedActions();
|
||||||
|
|
||||||
if (m_unk0x70) {
|
if (m_unk0x70) {
|
||||||
FUN_100c7980();
|
ScheduleNextDiskRead();
|
||||||
}
|
}
|
||||||
|
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c8670
|
// FUNCTION: LEGO1 0x100c8670
|
||||||
void MxDiskStreamController::FUN_100c8670(MxDSStreamingAction* p_streamingAction)
|
void MxDiskStreamController::QueueActionForDeletion(MxDSStreamingAction* p_streamingAction)
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_critical9c);
|
AUTOLOCK(m_critical9c);
|
||||||
m_list0xb8.push_back(p_streamingAction);
|
m_list0xb8.push_back(p_streamingAction);
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c8720
|
// FUNCTION: LEGO1 0x100c8720
|
||||||
void MxDiskStreamController::FUN_100c8720()
|
void MxDiskStreamController::DeleteQueuedActions()
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_critical9c);
|
AUTOLOCK(m_critical9c);
|
||||||
|
|
||||||
@ -485,6 +485,6 @@ void MxDiskStreamController::FUN_100c8720()
|
|||||||
while (!m_list0xb8.empty()) {
|
while (!m_list0xb8.empty()) {
|
||||||
action = (MxDSStreamingAction*) m_list0xb8.front();
|
action = (MxDSStreamingAction*) m_list0xb8.front();
|
||||||
m_list0xb8.pop_front();
|
m_list0xb8.pop_front();
|
||||||
FUN_100c7cb0(action);
|
DeleteStreamingAction(action);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -65,7 +65,7 @@ MxDiskStreamProvider::~MxDiskStreamProvider()
|
|||||||
g_unk0x10102878--;
|
g_unk0x10102878--;
|
||||||
}
|
}
|
||||||
|
|
||||||
((MxDiskStreamController*) m_pLookup)->FUN_100c8670((MxDSStreamingAction*) action);
|
((MxDiskStreamController*) m_pLookup)->QueueActionForDeletion((MxDSStreamingAction*) action);
|
||||||
} while (action);
|
} while (action);
|
||||||
|
|
||||||
if (m_remainingWork) {
|
if (m_remainingWork) {
|
||||||
@ -137,7 +137,7 @@ void MxDiskStreamProvider::VTable0x20(MxDSAction* p_action)
|
|||||||
g_unk0x10102878--;
|
g_unk0x10102878--;
|
||||||
}
|
}
|
||||||
|
|
||||||
((MxDiskStreamController*) m_pLookup)->FUN_100c8670((MxDSStreamingAction*) action);
|
((MxDiskStreamController*) m_pLookup)->QueueActionForDeletion((MxDSStreamingAction*) action);
|
||||||
} while (action);
|
} while (action);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -155,7 +155,7 @@ void MxDiskStreamProvider::VTable0x20(MxDSAction* p_action)
|
|||||||
g_unk0x10102878--;
|
g_unk0x10102878--;
|
||||||
}
|
}
|
||||||
|
|
||||||
((MxDiskStreamController*) m_pLookup)->FUN_100c8670((MxDSStreamingAction*) action);
|
((MxDiskStreamController*) m_pLookup)->QueueActionForDeletion((MxDSStreamingAction*) action);
|
||||||
} while (action);
|
} while (action);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@ -175,7 +175,7 @@ MxResult MxDiskStreamProvider::WaitForWorkToComplete()
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100d1780
|
// FUNCTION: LEGO1 0x100d1780
|
||||||
MxResult MxDiskStreamProvider::FUN_100d1780(MxDSStreamingAction* p_action)
|
MxResult MxDiskStreamProvider::QueueDiskRead(MxDSStreamingAction* p_action)
|
||||||
{
|
{
|
||||||
if (!m_remainingWork) {
|
if (!m_remainingWork) {
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
@ -221,7 +221,7 @@ void MxDiskStreamProvider::PerformWork()
|
|||||||
if (!m_list.empty()) {
|
if (!m_list.empty()) {
|
||||||
streamingAction = m_list.front();
|
streamingAction = m_list.front();
|
||||||
|
|
||||||
if (streamingAction && !FUN_100d1af0((MxDSStreamingAction*) streamingAction)) {
|
if (streamingAction && !CanStartReadNow((MxDSStreamingAction*) streamingAction)) {
|
||||||
m_thread.Sleep(500);
|
m_thread.Sleep(500);
|
||||||
m_busySemaphore.Release(1);
|
m_busySemaphore.Release(1);
|
||||||
return;
|
return;
|
||||||
@ -253,14 +253,14 @@ void MxDiskStreamProvider::PerformWork()
|
|||||||
buffer->SetUnknown1c(m_pFile->GetPosition());
|
buffer->SetUnknown1c(m_pFile->GetPosition());
|
||||||
|
|
||||||
if (((MxDSStreamingAction*) streamingAction)->GetUnknown9c() > 0) {
|
if (((MxDSStreamingAction*) streamingAction)->GetUnknown9c() > 0) {
|
||||||
FUN_100d1b20(((MxDSStreamingAction*) streamingAction));
|
StitchSplitStreamBuffer(((MxDSStreamingAction*) streamingAction));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
if (m_pLookup == NULL || !((MxDiskStreamController*) m_pLookup)->GetUnk0xc4()) {
|
if (m_pLookup == NULL || !((MxDiskStreamController*) m_pLookup)->GetUnk0xc4()) {
|
||||||
controller->FUN_100c8670(((MxDSStreamingAction*) streamingAction));
|
controller->QueueActionForDeletion(((MxDSStreamingAction*) streamingAction));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
controller->FUN_100c7f40(((MxDSStreamingAction*) streamingAction));
|
controller->QueueCompletedRead(((MxDSStreamingAction*) streamingAction));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -270,14 +270,14 @@ void MxDiskStreamProvider::PerformWork()
|
|||||||
|
|
||||||
done:
|
done:
|
||||||
if (streamingAction) {
|
if (streamingAction) {
|
||||||
controller->FUN_100c8670(((MxDSStreamingAction*) streamingAction));
|
controller->QueueActionForDeletion(((MxDSStreamingAction*) streamingAction));
|
||||||
}
|
}
|
||||||
|
|
||||||
m_thread.Sleep(0);
|
m_thread.Sleep(0);
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100d1af0
|
// FUNCTION: LEGO1 0x100d1af0
|
||||||
MxBool MxDiskStreamProvider::FUN_100d1af0(MxDSStreamingAction* p_action)
|
MxBool MxDiskStreamProvider::CanStartReadNow(MxDSStreamingAction* p_action)
|
||||||
{
|
{
|
||||||
if (p_action->GetUnknowna0()->GetWriteOffset() == 0x20000) {
|
if (p_action->GetUnknowna0()->GetWriteOffset() == 0x20000) {
|
||||||
return g_unk0x10102878 == 0;
|
return g_unk0x10102878 == 0;
|
||||||
@ -288,7 +288,7 @@ MxBool MxDiskStreamProvider::FUN_100d1af0(MxDSStreamingAction* p_action)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100d1b20
|
// FUNCTION: LEGO1 0x100d1b20
|
||||||
// FUNCTION: BETA10 0x10163712
|
// FUNCTION: BETA10 0x10163712
|
||||||
MxResult MxDiskStreamProvider::FUN_100d1b20(MxDSStreamingAction* p_action)
|
MxResult MxDiskStreamProvider::StitchSplitStreamBuffer(MxDSStreamingAction* p_action)
|
||||||
{
|
{
|
||||||
MxDSBuffer* buffer = new MxDSBuffer();
|
MxDSBuffer* buffer = new MxDSBuffer();
|
||||||
|
|
||||||
@ -307,7 +307,7 @@ MxResult MxDiskStreamProvider::FUN_100d1b20(MxDSStreamingAction* p_action)
|
|||||||
MxU8* data;
|
MxU8* data;
|
||||||
|
|
||||||
if (p_action->GetUnknowna4()) {
|
if (p_action->GetUnknowna4()) {
|
||||||
buffer->FUN_100c7090(p_action->GetUnknowna4());
|
buffer->CopyBufferStateFrom(p_action->GetUnknowna4());
|
||||||
data = buffer->GetBuffer() + p_action->GetUnknowna4()->GetWriteOffset();
|
data = buffer->GetBuffer() + p_action->GetUnknowna4()->GetWriteOffset();
|
||||||
|
|
||||||
memcpy(data, p_action->GetUnknowna0()->GetBuffer(), p_action->GetUnknowna0()->GetWriteOffset());
|
memcpy(data, p_action->GetUnknowna0()->GetBuffer(), p_action->GetUnknowna0()->GetWriteOffset());
|
||||||
@ -362,16 +362,16 @@ MxResult MxDiskStreamProvider::FUN_100d1b20(MxDSStreamingAction* p_action)
|
|||||||
p_action->SetBufferOffset(p_action->GetUnknowna0()->GetUnknown14());
|
p_action->SetBufferOffset(p_action->GetUnknowna0()->GetUnknown14());
|
||||||
delete p_action->GetUnknowna0();
|
delete p_action->GetUnknowna0();
|
||||||
p_action->ClearUnknowna0();
|
p_action->ClearUnknowna0();
|
||||||
((MxDiskStreamController*) m_pLookup)->FUN_100c7890(p_action);
|
((MxDiskStreamController*) m_pLookup)->QueueReadAheadAction(p_action);
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
data = buffer->FUN_100c6fa0(data);
|
data = buffer->FindNextChunk(data);
|
||||||
}
|
}
|
||||||
|
|
||||||
p_action->SetUnknown94(GetFileSize() + p_action->GetBufferOffset());
|
p_action->SetUnknown94(GetFileSize() + p_action->GetBufferOffset());
|
||||||
p_action->SetBufferOffset(GetFileSize() + p_action->GetBufferOffset());
|
p_action->SetBufferOffset(GetFileSize() + p_action->GetBufferOffset());
|
||||||
FUN_100d1780(p_action);
|
QueueDiskRead(p_action);
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
|
|
||||||
#undef IntoType
|
#undef IntoType
|
||||||
|
|||||||
@ -99,7 +99,7 @@ MxResult MxDSBuffer::SetBufferPointer(MxU8* p_buffer, MxU32 p_size)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c67b0
|
// FUNCTION: LEGO1 0x100c67b0
|
||||||
// FUNCTION: BETA10 0x10157295
|
// FUNCTION: BETA10 0x10157295
|
||||||
MxResult MxDSBuffer::FUN_100c67b0(
|
MxResult MxDSBuffer::ParseDataChunks(
|
||||||
MxStreamController* p_controller,
|
MxStreamController* p_controller,
|
||||||
MxDSAction* p_action,
|
MxDSAction* p_action,
|
||||||
MxDSStreamingAction** p_streamingAction
|
MxDSStreamingAction** p_streamingAction
|
||||||
@ -132,7 +132,7 @@ MxResult MxDSBuffer::FUN_100c67b0(
|
|||||||
(*p_streamingAction)->ClearUnknowna0();
|
(*p_streamingAction)->ClearUnknowna0();
|
||||||
}
|
}
|
||||||
|
|
||||||
((MxDiskStreamController*) p_controller)->FUN_100c7cb0(*p_streamingAction);
|
((MxDiskStreamController*) p_controller)->DeleteStreamingAction(*p_streamingAction);
|
||||||
*p_streamingAction = NULL;
|
*p_streamingAction = NULL;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@ -291,7 +291,7 @@ MxResult MxDSBuffer::ParseChunk(
|
|||||||
data->SetData(m_unk0x30->GetBufferOffset());
|
data->SetData(m_unk0x30->GetBufferOffset());
|
||||||
}
|
}
|
||||||
|
|
||||||
m_unk0x30->FUN_100cd2d0();
|
m_unk0x30->AdvanceLoopPlaybackWindow();
|
||||||
}
|
}
|
||||||
|
|
||||||
delete p_header;
|
delete p_header;
|
||||||
@ -447,7 +447,7 @@ MxResult MxDSBuffer::CalcBytesRemaining(MxU8* p_data)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c6f80
|
// FUNCTION: LEGO1 0x100c6f80
|
||||||
void MxDSBuffer::FUN_100c6f80(MxU32 p_writeOffset)
|
void MxDSBuffer::SeekBufferCursor(MxU32 p_writeOffset)
|
||||||
{
|
{
|
||||||
if (p_writeOffset < m_writeOffset) {
|
if (p_writeOffset < m_writeOffset) {
|
||||||
m_pIntoBuffer2 = m_pBuffer + p_writeOffset;
|
m_pIntoBuffer2 = m_pBuffer + p_writeOffset;
|
||||||
@ -457,7 +457,7 @@ void MxDSBuffer::FUN_100c6f80(MxU32 p_writeOffset)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c6fa0
|
// FUNCTION: LEGO1 0x100c6fa0
|
||||||
// FUNCTION: BETA10 0x101582f2
|
// FUNCTION: BETA10 0x101582f2
|
||||||
MxU8* MxDSBuffer::FUN_100c6fa0(MxU8* p_data)
|
MxU8* MxDSBuffer::FindNextChunk(MxU8* p_data)
|
||||||
{
|
{
|
||||||
MxU8* volatile current = p_data ? p_data : m_pBuffer;
|
MxU8* volatile current = p_data ? p_data : m_pBuffer;
|
||||||
|
|
||||||
@ -495,7 +495,7 @@ MxU8* MxDSBuffer::FUN_100c6fa0(MxU8* p_data)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c7090
|
// FUNCTION: LEGO1 0x100c7090
|
||||||
// FUNCTION: BETA10 0x1015842d
|
// FUNCTION: BETA10 0x1015842d
|
||||||
MxResult MxDSBuffer::FUN_100c7090(MxDSBuffer* p_buf)
|
MxResult MxDSBuffer::CopyBufferStateFrom(MxDSBuffer* p_buf)
|
||||||
{
|
{
|
||||||
MxResult result = FAILURE;
|
MxResult result = FAILURE;
|
||||||
|
|
||||||
|
|||||||
@ -86,9 +86,9 @@ MxResult MxRAMStreamController::DeserializeObject(MxDSStreamingAction& p_action)
|
|||||||
MxDSStreamingAction* value = NULL;
|
MxDSStreamingAction* value = NULL;
|
||||||
|
|
||||||
do {
|
do {
|
||||||
m_buffer.FUN_100c6f80(p_action.GetUnknown94());
|
m_buffer.SeekBufferCursor(p_action.GetUnknown94());
|
||||||
// Probably not MxResult, see below
|
// Probably not MxResult, see below
|
||||||
result = m_buffer.FUN_100c67b0(this, &p_action, &value);
|
result = m_buffer.ParseDataChunks(this, &p_action, &value);
|
||||||
} while (m_unk0x3c.Find(&p_action) != NULL);
|
} while (m_unk0x3c.Find(&p_action) != NULL);
|
||||||
|
|
||||||
return result == SUCCESS ? SUCCESS : FAILURE;
|
return result == SUCCESS ? SUCCESS : FAILURE;
|
||||||
|
|||||||
@ -129,13 +129,13 @@ MxResult MxStreamController::VTable0x24(MxDSAction* p_action)
|
|||||||
else {
|
else {
|
||||||
p_action->SetUnknown24(m_action0x60->GetUnknown24());
|
p_action->SetUnknown24(m_action0x60->GetUnknown24());
|
||||||
p_action->SetObjectId(m_action0x60->GetObjectId());
|
p_action->SetObjectId(m_action0x60->GetObjectId());
|
||||||
return FUN_100c1f00(m_action0x60);
|
return SendEndOfStreamChunk(m_action0x60);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c1800
|
// FUNCTION: LEGO1 0x100c1800
|
||||||
// FUNCTION: BETA10 0x1014ea36
|
// FUNCTION: BETA10 0x1014ea36
|
||||||
MxResult MxStreamController::FUN_100c1800(MxDSAction* p_action, MxU32 p_val)
|
MxResult MxStreamController::QueueNextActionDataStart(MxDSAction* p_action, MxU32 p_val)
|
||||||
{
|
{
|
||||||
MxNextActionDataStart* dataActionStart =
|
MxNextActionDataStart* dataActionStart =
|
||||||
new MxNextActionDataStart(p_action->GetObjectId(), p_action->GetUnknown24(), p_val);
|
new MxNextActionDataStart(p_action->GetObjectId(), p_action->GetUnknown24(), p_val);
|
||||||
@ -149,7 +149,7 @@ MxResult MxStreamController::FUN_100c1800(MxDSAction* p_action, MxU32 p_val)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c1a00
|
// FUNCTION: LEGO1 0x100c1a00
|
||||||
// FUNCTION: BETA10 0x1014eb04
|
// FUNCTION: BETA10 0x1014eb04
|
||||||
MxResult MxStreamController::FUN_100c1a00(MxDSAction* p_action, MxU32 p_offset)
|
MxResult MxStreamController::CreateStreamingAction(MxDSAction* p_action, MxU32 p_offset)
|
||||||
{
|
{
|
||||||
if (p_action->GetUnknown24() == -1) {
|
if (p_action->GetUnknown24() == -1) {
|
||||||
MxS16 newUnknown24 = -1;
|
MxS16 newUnknown24 = -1;
|
||||||
@ -214,11 +214,11 @@ MxResult MxStreamController::VTable0x2c(MxDSAction* p_action, MxU32 p_bufferval)
|
|||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
|
|
||||||
if (FUN_100c1a00(p_action, p_bufferval) != SUCCESS) {
|
if (CreateStreamingAction(p_action, p_bufferval) != SUCCESS) {
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
}
|
}
|
||||||
|
|
||||||
return FUN_100c1800(p_action, (p_bufferval / m_provider->GetFileSize()) * m_provider->GetFileSize());
|
return QueueNextActionDataStart(p_action, (p_bufferval / m_provider->GetFileSize()) * m_provider->GetFileSize());
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c1ce0
|
// FUNCTION: LEGO1 0x100c1ce0
|
||||||
@ -257,7 +257,7 @@ MxResult MxStreamController::InsertActionToList54(MxDSAction* p_action)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c1e70
|
// FUNCTION: LEGO1 0x100c1e70
|
||||||
// FUNCTION: BETA10 0x1014f0a1
|
// FUNCTION: BETA10 0x1014f0a1
|
||||||
MxPresenter* MxStreamController::FUN_100c1e70(MxDSAction& p_action)
|
MxPresenter* MxStreamController::FindPresenterForAction(MxDSAction& p_action)
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
MxPresenter* result = NULL;
|
MxPresenter* result = NULL;
|
||||||
@ -274,7 +274,7 @@ MxPresenter* MxStreamController::FUN_100c1e70(MxDSAction& p_action)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100c1f00
|
// FUNCTION: LEGO1 0x100c1f00
|
||||||
// FUNCTION: BETA10 0x1014f162
|
// FUNCTION: BETA10 0x1014f162
|
||||||
MxResult MxStreamController::FUN_100c1f00(MxDSAction* p_action)
|
MxResult MxStreamController::SendEndOfStreamChunk(MxDSAction* p_action)
|
||||||
{
|
{
|
||||||
AUTOLOCK(m_criticalSection);
|
AUTOLOCK(m_criticalSection);
|
||||||
|
|
||||||
@ -298,7 +298,7 @@ MxResult MxStreamController::FUN_100c1f00(MxDSAction* p_action)
|
|||||||
MxDSAction* action;
|
MxDSAction* action;
|
||||||
|
|
||||||
while (cursor.Next(action)) {
|
while (cursor.Next(action)) {
|
||||||
if (FUN_100c1f00(action) != SUCCESS) {
|
if (SendEndOfStreamChunk(action) != SUCCESS) {
|
||||||
return FAILURE;
|
return FAILURE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -141,11 +141,11 @@ MxStreamController* MxStreamer::GetOpenStream(const char* p_name)
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100b98f0
|
// FUNCTION: LEGO1 0x100b98f0
|
||||||
void MxStreamer::FUN_100b98f0(MxDSAction* p_action)
|
void MxStreamer::StopDiskAction(MxDSAction* p_action)
|
||||||
{
|
{
|
||||||
MxStreamController* controller = GetOpenStream(p_action->GetAtomId().GetInternal());
|
MxStreamController* controller = GetOpenStream(p_action->GetAtomId().GetInternal());
|
||||||
if (controller && controller->IsA("MxDiskStreamController")) {
|
if (controller && controller->IsA("MxDiskStreamController")) {
|
||||||
((MxDiskStreamController*) controller)->FUN_100c8120(p_action);
|
((MxDiskStreamController*) controller)->CancelDiskAction(p_action);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -168,7 +168,7 @@ MxResult MxStreamer::AddStreamControllerToOpenList(MxStreamController* p_stream)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100b99b0
|
// FUNCTION: LEGO1 0x100b99b0
|
||||||
// FUNCTION: BETA10 0x101459ad
|
// FUNCTION: BETA10 0x101459ad
|
||||||
MxResult MxStreamer::FUN_100b99b0(MxDSAction* p_action)
|
MxResult MxStreamer::StartObjectStreaming(MxDSAction* p_action)
|
||||||
{
|
{
|
||||||
// TODO: MxAtomId operator== used here for NULL test. BETA10 0x1007dc20
|
// TODO: MxAtomId operator== used here for NULL test. BETA10 0x1007dc20
|
||||||
if (p_action == NULL || p_action->GetAtomId().GetInternal() == NULL || p_action->GetObjectId() == -1) {
|
if (p_action == NULL || p_action->GetAtomId().GetInternal() == NULL || p_action->GetObjectId() == -1) {
|
||||||
@ -212,7 +212,7 @@ MxResult MxStreamer::DeleteObject(MxDSAction* p_dsAction)
|
|||||||
|
|
||||||
// FUNCTION: LEGO1 0x100b9b30
|
// FUNCTION: LEGO1 0x100b9b30
|
||||||
// FUNCTION: BETA10 0x10145d01
|
// FUNCTION: BETA10 0x10145d01
|
||||||
MxBool MxStreamer::FUN_100b9b30(MxDSObject& p_dsObject)
|
MxBool MxStreamer::IsObjectStopped(MxDSObject& p_dsObject)
|
||||||
{
|
{
|
||||||
MxStreamController* controller = GetOpenStream(p_dsObject.GetAtomId().GetInternal());
|
MxStreamController* controller = GetOpenStream(p_dsObject.GetAtomId().GetInternal());
|
||||||
if (controller) {
|
if (controller) {
|
||||||
|
|||||||
@ -1371,7 +1371,7 @@ void MxDisplaySurface::VTable0x2c(
|
|||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100bc8b0
|
// FUNCTION: LEGO1 0x100bc8b0
|
||||||
LPDIRECTDRAWSURFACE MxDisplaySurface::FUN_100bc8b0(MxS32 p_width, MxS32 p_height)
|
LPDIRECTDRAWSURFACE MxDisplaySurface::Create16BitOffscreenSurface(MxS32 p_width, MxS32 p_height)
|
||||||
{
|
{
|
||||||
LPDIRECTDRAWSURFACE surface = NULL;
|
LPDIRECTDRAWSURFACE surface = NULL;
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user