mirror of
https://github.com/isledecomp/isle.git
synced 2024-11-22 15:48:09 -05:00
Refactor: Replace magic values by enum values (#865)
Co-authored-by: jonschz <jonschz@users.noreply.github.com>
This commit is contained in:
parent
dede20000f
commit
b17d76c2cc
2 changed files with 5 additions and 5 deletions
|
@ -80,7 +80,7 @@ void Radio::Stop()
|
|||
if (m_state->IsActive()) {
|
||||
LegoWorld* world = CurrentWorld();
|
||||
|
||||
MxControlPresenter* presenter = (MxControlPresenter*) world->Find(world->GetAtom(), 18);
|
||||
MxControlPresenter* presenter = (MxControlPresenter*) world->Find(world->GetAtom(), IsleScript::c_Radio_Ctl);
|
||||
|
||||
if (presenter) {
|
||||
presenter->VTable0x6c(0);
|
||||
|
|
|
@ -1083,28 +1083,28 @@ void LegoGameState::Init()
|
|||
if (m_loadedAct == e_act1) {
|
||||
Isle* isle = (Isle*) FindWorld(*g_isleScript, 0);
|
||||
|
||||
Helicopter* copter = (Helicopter*) isle->Find(*g_copterScript, 1);
|
||||
Helicopter* copter = (Helicopter*) isle->Find(*g_copterScript, CopterScript::c_Helicopter_Actor);
|
||||
if (copter) {
|
||||
isle->FUN_1001fc80(copter);
|
||||
isle->VTable0x6c(copter);
|
||||
delete copter;
|
||||
}
|
||||
|
||||
DuneBuggy* dunebuggy = (DuneBuggy*) isle->Find(*g_dunecarScript, 2);
|
||||
DuneBuggy* dunebuggy = (DuneBuggy*) isle->Find(*g_dunecarScript, DunecarScript::c_DuneBugy_Actor);
|
||||
if (dunebuggy) {
|
||||
isle->FUN_1001fc80(dunebuggy);
|
||||
isle->VTable0x6c(dunebuggy);
|
||||
delete dunebuggy;
|
||||
}
|
||||
|
||||
Jetski* jetski = (Jetski*) isle->Find(*g_jetskiScript, 3);
|
||||
Jetski* jetski = (Jetski*) isle->Find(*g_jetskiScript, JetskiScript::c_Jetski_Actor);
|
||||
if (jetski) {
|
||||
isle->FUN_1001fc80(jetski);
|
||||
isle->VTable0x6c(jetski);
|
||||
delete jetski;
|
||||
}
|
||||
|
||||
RaceCar* racecar = (RaceCar*) isle->Find(*g_racecarScript, 4);
|
||||
RaceCar* racecar = (RaceCar*) isle->Find(*g_racecarScript, RacecarScript::c_RaceCar_Actor);
|
||||
if (racecar) {
|
||||
isle->FUN_1001fc80(racecar);
|
||||
isle->VTable0x6c(racecar);
|
||||
|
|
Loading…
Reference in a new issue