mirror of
https://github.com/isledecomp/isle.git
synced 2026-01-24 00:31:16 +00:00
Address review comments, part 1
This commit is contained in:
parent
9ae3e78836
commit
a065aa10ad
@ -2,8 +2,10 @@
|
|||||||
|
|
||||||
#include "copter_actions.h"
|
#include "copter_actions.h"
|
||||||
#include "dunebuggy.h"
|
#include "dunebuggy.h"
|
||||||
|
#include "dunecar_actions.h"
|
||||||
#include "helicopter.h"
|
#include "helicopter.h"
|
||||||
#include "jetski.h"
|
#include "jetski.h"
|
||||||
|
#include "jetski_actions.h"
|
||||||
#include "jukebox_actions.h"
|
#include "jukebox_actions.h"
|
||||||
#include "legocarbuildpresenter.h"
|
#include "legocarbuildpresenter.h"
|
||||||
#include "legocontrolmanager.h"
|
#include "legocontrolmanager.h"
|
||||||
@ -22,16 +24,18 @@
|
|||||||
#include "mxticklemanager.h"
|
#include "mxticklemanager.h"
|
||||||
#include "mxtransitionmanager.h"
|
#include "mxtransitionmanager.h"
|
||||||
#include "racecar.h"
|
#include "racecar.h"
|
||||||
|
#include "racecar_actions.h"
|
||||||
#include "scripts.h"
|
#include "scripts.h"
|
||||||
|
|
||||||
#include <isle.h>
|
#include <isle.h>
|
||||||
#include <vec.h>
|
#include <vec.h>
|
||||||
|
|
||||||
// names and values verified by BETA10 0x1006d742
|
// Names and values verified by BETA10 0x1006d742.
|
||||||
#define Helicopter_Actor 1
|
// Note that these were probably hard-coded numbers in the original.
|
||||||
#define DuneBugy_Actor 2
|
#define Helicopter_Actor CopterScript::c_Helicopter_Actor
|
||||||
#define Jetski_Actor 3
|
#define DuneBugy_Actor DunecarScript::c_DuneBugy_Actor
|
||||||
#define RaceCar_Actor 4
|
#define Jetski_Actor JetskiScript::c_Jetski_Actor
|
||||||
|
#define RaceCar_Actor RacecarScript::c_RaceCar_Actor
|
||||||
|
|
||||||
DECOMP_SIZE_ASSERT(LegoCarBuild, 0x34c)
|
DECOMP_SIZE_ASSERT(LegoCarBuild, 0x34c)
|
||||||
DECOMP_SIZE_ASSERT(LegoVehicleBuildState, 0x50)
|
DECOMP_SIZE_ASSERT(LegoVehicleBuildState, 0x50)
|
||||||
|
|||||||
@ -47,20 +47,20 @@ MxTransitionManager::~MxTransitionManager()
|
|||||||
MxResult MxTransitionManager::GetDDrawSurfaceFromVideoManager() // vtable+0x14
|
MxResult MxTransitionManager::GetDDrawSurfaceFromVideoManager() // vtable+0x14
|
||||||
{
|
{
|
||||||
LegoVideoManager* videoManager = VideoManager();
|
LegoVideoManager* videoManager = VideoManager();
|
||||||
this->m_ddSurface = videoManager->GetDisplaySurface()->GetDirectDrawSurface2();
|
m_ddSurface = videoManager->GetDisplaySurface()->GetDirectDrawSurface2();
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1004bac0
|
// FUNCTION: LEGO1 0x1004bac0
|
||||||
MxResult MxTransitionManager::Tickle()
|
MxResult MxTransitionManager::Tickle()
|
||||||
{
|
{
|
||||||
if (this->m_animationSpeed + this->m_systemTime > timeGetTime()) {
|
if (m_animationSpeed + m_systemTime > timeGetTime()) {
|
||||||
return SUCCESS;
|
return SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
this->m_systemTime = timeGetTime();
|
m_systemTime = timeGetTime();
|
||||||
|
|
||||||
switch (this->m_mode) {
|
switch (m_mode) {
|
||||||
case e_noAnimation:
|
case e_noAnimation:
|
||||||
NoTransition();
|
NoTransition();
|
||||||
break;
|
break;
|
||||||
@ -94,13 +94,13 @@ MxResult MxTransitionManager::StartTransition(
|
|||||||
{
|
{
|
||||||
assert(m_mode == e_idle);
|
assert(m_mode == e_idle);
|
||||||
|
|
||||||
if (this->m_mode == e_idle) {
|
if (m_mode == e_idle) {
|
||||||
if (!p_playMusicInAnim) {
|
if (!p_playMusicInAnim) {
|
||||||
MxBackgroundAudioManager* backgroundAudioManager = BackgroundAudioManager();
|
MxBackgroundAudioManager* backgroundAudioManager = BackgroundAudioManager();
|
||||||
backgroundAudioManager->Stop();
|
backgroundAudioManager->Stop();
|
||||||
}
|
}
|
||||||
|
|
||||||
this->m_mode = p_animationType;
|
m_mode = p_animationType;
|
||||||
|
|
||||||
m_copyFlags.m_bit0 = p_doCopy;
|
m_copyFlags.m_bit0 = p_doCopy;
|
||||||
|
|
||||||
@ -113,9 +113,9 @@ MxResult MxTransitionManager::StartTransition(
|
|||||||
}
|
}
|
||||||
|
|
||||||
MxU32 time = timeGetTime();
|
MxU32 time = timeGetTime();
|
||||||
this->m_systemTime = time;
|
m_systemTime = time;
|
||||||
|
|
||||||
this->m_animationSpeed = p_speed;
|
m_animationSpeed = p_speed;
|
||||||
|
|
||||||
MxTickleManager* tickleManager = TickleManager();
|
MxTickleManager* tickleManager = TickleManager();
|
||||||
tickleManager->RegisterClient(this, p_speed);
|
tickleManager->RegisterClient(this, p_speed);
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user