mirror of
https://gitlab.com/GaryOderNichts/re3-wiiu.git
synced 2024-12-25 17:21:49 +01:00
int8 enums fixed
This commit is contained in:
parent
16ed00aede
commit
912e71be53
@ -9020,7 +9020,7 @@ cAudioManager::ProcessGarages()
|
||||
const float SOUND_INTENSITY = 80.0f;
|
||||
|
||||
CEntity *entity;
|
||||
eGarageState state;
|
||||
uint8 state;
|
||||
uint32 sampleIndex;
|
||||
uint8 j;
|
||||
float distSquared;
|
||||
|
@ -192,7 +192,7 @@ void CGarages::Update(void)
|
||||
aGarages[GarageToBeTidied].TidyUpGarage();
|
||||
}
|
||||
|
||||
int16 CGarages::AddOne(float X1, float Y1, float Z1, float X2, float Y2, float X3, float Y3, float Z2, eGarageType type, int32 targetId)
|
||||
int16 CGarages::AddOne(float X1, float Y1, float Z1, float X2, float Y2, float X3, float Y3, float Z2, uint8 type, int32 targetId)
|
||||
{
|
||||
if (NumGarages >= NUM_GARAGES) {
|
||||
assert(0);
|
||||
@ -293,7 +293,7 @@ int16 CGarages::AddOne(float X1, float Y1, float Z1, float X2, float Y2, float X
|
||||
return NumGarages++;
|
||||
}
|
||||
|
||||
void CGarages::ChangeGarageType(int16 garage, eGarageType type, int32 mi)
|
||||
void CGarages::ChangeGarageType(int16 garage, uint8 type, int32 mi)
|
||||
{
|
||||
CGarage* pGarage = &aGarages[garage];
|
||||
pGarage->m_eGarageType = type;
|
||||
@ -2074,7 +2074,7 @@ void CGarages::CloseHideOutGaragesBeforeSave()
|
||||
}
|
||||
}
|
||||
|
||||
int32 CGarages::CountCarsInHideoutGarage(eGarageType type)
|
||||
int32 CGarages::CountCarsInHideoutGarage(uint8 type)
|
||||
{
|
||||
int32 total = 0;
|
||||
for (int i = 0; i < NUM_GARAGE_STORED_CARS; i++) {
|
||||
|
@ -7,7 +7,7 @@
|
||||
class CVehicle;
|
||||
class CCamera;
|
||||
|
||||
enum eGarageState : int8
|
||||
enum eGarageState
|
||||
{
|
||||
GS_FULLYCLOSED,
|
||||
GS_OPENED,
|
||||
@ -18,7 +18,7 @@ enum eGarageState : int8
|
||||
GS_AFTERDROPOFF,
|
||||
};
|
||||
|
||||
enum eGarageType : int8
|
||||
enum eGarageType
|
||||
{
|
||||
GARAGE_NONE,
|
||||
GARAGE_MISSION,
|
||||
@ -93,8 +93,8 @@ VALIDATE_SIZE(CStoredCar, 0x28);
|
||||
|
||||
class CGarage
|
||||
{
|
||||
eGarageType m_eGarageType;
|
||||
eGarageState m_eGarageState;
|
||||
uint8 m_eGarageType;
|
||||
uint8 m_eGarageState;
|
||||
uint8 m_nMaxStoredCars;
|
||||
bool field_2; // unused
|
||||
bool m_bClosingWithoutTargetCar;
|
||||
@ -227,8 +227,8 @@ public:
|
||||
#endif
|
||||
static void Update(void);
|
||||
|
||||
static int16 AddOne(float X1, float Y1, float Z1, float X2, float Y2, float X3, float Y3, float Z2, eGarageType type, int32 targetId);
|
||||
static void ChangeGarageType(int16, eGarageType, int32);
|
||||
static int16 AddOne(float X1, float Y1, float Z1, float X2, float Y2, float X3, float Y3, float Z2, uint8 type, int32 targetId);
|
||||
static void ChangeGarageType(int16, uint8, int32);
|
||||
static void PrintMessages(void);
|
||||
static void TriggerMessage(const char* text, int16, uint16 time, int16);
|
||||
static void SetTargetCarForMissonGarage(int16, CVehicle*);
|
||||
@ -265,9 +265,9 @@ private:
|
||||
static bool IsCarSprayable(CVehicle*);
|
||||
static float FindDoorHeightForMI(int32);
|
||||
static void CloseHideOutGaragesBeforeSave(void);
|
||||
static int32 CountCarsInHideoutGarage(eGarageType);
|
||||
static int32 GetBombTypeForGarageType(eGarageType type) { return type - GARAGE_BOMBSHOP1 + 1; }
|
||||
static int32 GetCarsCollectedIndexForGarageType(eGarageType type)
|
||||
static int32 CountCarsInHideoutGarage(uint8);
|
||||
static int32 GetBombTypeForGarageType(uint8 type) { return type - GARAGE_BOMBSHOP1 + 1; }
|
||||
static int32 GetCarsCollectedIndexForGarageType(uint8 type)
|
||||
{
|
||||
switch (type) {
|
||||
case GARAGE_COLLECTCARS_1: return 0;
|
||||
@ -278,7 +278,7 @@ private:
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
static int32 FindSafeHouseIndexForGarageType(eGarageType type)
|
||||
static int32 FindSafeHouseIndexForGarageType(uint8 type)
|
||||
{
|
||||
switch (type) {
|
||||
case GARAGE_HIDEOUT_ONE: return 0;
|
||||
@ -296,7 +296,7 @@ private:
|
||||
}
|
||||
return -1;
|
||||
}
|
||||
static bool IsThisGarageTypeSafehouse(eGarageType type) { return FindSafeHouseIndexForGarageType(type) >= 0; }
|
||||
static bool IsThisGarageTypeSafehouse(uint8 type) { return FindSafeHouseIndexForGarageType(type) >= 0; }
|
||||
|
||||
friend class cAudioManager;
|
||||
friend class CReplay;
|
||||
|
@ -286,7 +286,7 @@ int8 CRunningScript::ProcessCommands500To599(int32 command)
|
||||
float supX = *(float*)&ScriptParams[5];
|
||||
float supY = *(float*)&ScriptParams[6];
|
||||
float supZ = *(float*)&ScriptParams[7];
|
||||
ScriptParams[0] = CGarages::AddOne(infX, infY, infZ, X2, Y2, supX, supY, supZ, (eGarageType)ScriptParams[8], 0);
|
||||
ScriptParams[0] = CGarages::AddOne(infX, infY, infZ, X2, Y2, supX, supY, supZ, ScriptParams[8], 0);
|
||||
StoreParameters(&m_nIp, 1);
|
||||
return 0;
|
||||
}
|
||||
@ -302,7 +302,7 @@ int8 CRunningScript::ProcessCommands500To599(int32 command)
|
||||
float supX = *(float*)&ScriptParams[5];
|
||||
float supY = *(float*)&ScriptParams[6];
|
||||
float supZ = *(float*)&ScriptParams[7];
|
||||
ScriptParams[0] = CGarages::AddOne(infX, infY, infZ, X2, Y2, supX, supY, supZ, (eGarageType)ScriptParams[8], ScriptParams[9]);
|
||||
ScriptParams[0] = CGarages::AddOne(infX, infY, infZ, X2, Y2, supX, supY, supZ, ScriptParams[8], ScriptParams[9]);
|
||||
StoreParameters(&m_nIp, 1);
|
||||
return 0;
|
||||
}
|
||||
@ -1848,7 +1848,7 @@ int8 CRunningScript::ProcessCommands700To799(int32 command)
|
||||
}
|
||||
case COMMAND_CHANGE_GARAGE_TYPE:
|
||||
CollectParameters(&m_nIp, 2);
|
||||
CGarages::ChangeGarageType(ScriptParams[0], (eGarageType)ScriptParams[1], 0);
|
||||
CGarages::ChangeGarageType(ScriptParams[0], ScriptParams[1], 0);
|
||||
return 0;
|
||||
/*
|
||||
case COMMAND_ACTIVATE_CRUSHER_CRANE:
|
||||
|
@ -1537,7 +1537,7 @@ int8 CRunningScript::ProcessCommands900To999(int32 command)
|
||||
case COMMAND_CHANGE_GARAGE_TYPE_WITH_CAR_MODEL:
|
||||
{
|
||||
CollectParameters(&m_nIp, 3);
|
||||
CGarages::ChangeGarageType(ScriptParams[0], (eGarageType)ScriptParams[1], ScriptParams[2]);
|
||||
CGarages::ChangeGarageType(ScriptParams[0], ScriptParams[1], ScriptParams[2]);
|
||||
return 0;
|
||||
}
|
||||
case COMMAND_FIND_DRUG_PLANE_COORDINATES:
|
||||
|
@ -52,7 +52,7 @@ enum eFormation
|
||||
FORMATION_FRONT
|
||||
};
|
||||
|
||||
enum FightState : int8 {
|
||||
enum FightState {
|
||||
FIGHTSTATE_MOVE_FINISHED = -2,
|
||||
FIGHTSTATE_JUST_ATTACKED,
|
||||
FIGHTSTATE_NO_MOVE,
|
||||
@ -598,7 +598,7 @@ public:
|
||||
uint32 m_curFightMove;
|
||||
uint32 m_lastFightMove;
|
||||
uint8 m_fightButtonPressure;
|
||||
FightState m_fightState;
|
||||
int8 m_fightState;
|
||||
bool m_takeAStepAfterAttack;
|
||||
uint8 m_bleedCounter;
|
||||
CFire *m_pFire;
|
||||
|
Loading…
Reference in New Issue
Block a user