Skip to content

Commit

Permalink
Small cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
Sora-yx committed Apr 5, 2023
1 parent bb53952 commit ea8abca
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 22 deletions.
2 changes: 0 additions & 2 deletions sadx-randomizer/07_LostWorld.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -8,10 +8,8 @@ void LW_Layout() {
else
{
CurrentStageVersion = KnucklesVersion;

}

return;
}

bool isPlayerInWaterSlide = false;
Expand Down
4 changes: 2 additions & 2 deletions sadx-randomizer/08_IceCap.cpp
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
#include "stdafx.h"
#include "IceCap.h"

void IC_Layout() {

void IC_Layout()
{

if (CurrentStageVersion != BigVersion)
{
Expand Down
4 changes: 2 additions & 2 deletions sadx-randomizer/09_Casino.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -117,8 +117,8 @@ void Fix_PlayerPositionInPinball(Uint8 charIndex, float x, float y, float z) {
if (CurrentCharacter >= Characters_Gamma)
{
x = 0;
y = 192.295;
z = 51.5;
y = 192.295f;
z = 51.5f;
}

return PositionPlayer(charIndex, x, y, z);
Expand Down
8 changes: 2 additions & 6 deletions sadx-randomizer/10_FinalEgg.cpp
Original file line number Diff line number Diff line change
@@ -1,24 +1,21 @@
#include "stdafx.h"
#include "FE.h"

void FinalEgg_Layout() {
void FinalEgg_Layout()
{

if (CurrentStageVersion != AmyVersion && CurrentStageVersion != GammaVersion)
CurrentStageVersion = SonicVersion;

if (CurrentAct == 2)
CurrentStageVersion = GammaVersion;

return;
}


void __cdecl FinalEggObjects_Init(const char* path, const HelperFunctions& helperFunctions) {
//Change the objectlist

ObjLists[LevelIDs_FinalEgg * 8 + 0] = &FinalEggObjectList;
ObjLists[LevelIDs_FinalEgg * 8 + 2] = &FinalEggObjectList;
return;
}

void __cdecl FinalEgg_Init(const char* path, const HelperFunctions& helperFunctions) {
Expand All @@ -38,5 +35,4 @@ void __cdecl FinalEgg_Init(const char* path, const HelperFunctions& helperFuncti
AddCam("C1002");
AddCam("C1003");
AddCam("C1004");
return;
}
14 changes: 4 additions & 10 deletions sadx-randomizer/12_HotShelter.cpp
Original file line number Diff line number Diff line change
@@ -1,25 +1,24 @@
#include "stdafx.h"
#include "HS.h"

void HotShelter_Layout() {

if (CurrentMission == Mission3_LostChao && CurrentStageVersion == BigVersion) {
void HotShelter_Layout()
{
if (CurrentMission == Mission3_LostChao && CurrentStageVersion == BigVersion)
{

if (SA2M2)
CurrentMission = Mission2_100Rings;
else
CurrentMission = SADX_Mission;
}


if (CurrentStageVersion != BigVersion && CurrentStageVersion != GammaVersion)
CurrentStageVersion = AmyVersion;

if (CurrentAct == 2)
CurrentStageVersion = GammaVersion;

CheckAndSet_HotShelterLayoutFeatures();
return;
}

void HotShelterSecretSwitch() { //used for Big Hot Shelter when not Big for secret path.
Expand All @@ -30,7 +29,6 @@ void HotShelterSecretSwitch() { //used for Big Hot Shelter when not Big for secr
if (SecretWaterSwitch == 3 && FirstHotShelterSwitch == 1)
SomethingAboutHotShelterSwitch = 1;

return;
}

void CheckAndSet_HotShelterLayoutFeatures() {
Expand All @@ -53,8 +51,6 @@ void CheckAndSet_HotShelterLayoutFeatures() {
WriteData<1>((int*)0x59a126, 0x75);
WriteData<6>((int*)0x442249, 0x90); //Fix Puzzle Box drop
}

return;
}


Expand All @@ -66,7 +62,6 @@ void __cdecl HSObjects_Init(const char* path, const HelperFunctions& helperFunct
ObjLists[LevelIDs_HotShelter * 8 + 2] = &HotShelter3ObjectList;

HotShelterDeathZones[2] = HotShelter3DeathZones;
return;
}

void __cdecl HotShelter_Init(const char* path, const HelperFunctions& helperFunctions)
Expand Down Expand Up @@ -95,5 +90,4 @@ void __cdecl HotShelter_Init(const char* path, const HelperFunctions& helperFunc
AddCam("C1201");
AddCam("C1202");
AddCam("C1203");
return;
}

0 comments on commit ea8abca

Please sign in to comment.