More refs removed

This commit is contained in:
Sergeanur 2020-04-16 15:30:47 +03:00
parent 7bd12f4a48
commit 83cbe4e39e
19 changed files with 88 additions and 89 deletions

View File

@ -7,8 +7,8 @@
#include "main.h"
#include "Population.h"
float &CIniFile::PedNumberMultiplier = *(float*)0x6182F4;
float &CIniFile::CarNumberMultiplier = *(float*)0x6182F8;
float CIniFile::PedNumberMultiplier = 1.0f;// = *(float*)0x6182F4;
float CIniFile::CarNumberMultiplier = 1.0f;// = *(float*)0x6182F8;
void CIniFile::LoadIniFile()
{

View File

@ -5,6 +5,6 @@ class CIniFile
public:
static void LoadIniFile();
static float& PedNumberMultiplier;
static float& CarNumberMultiplier;
static float PedNumberMultiplier;
static float CarNumberMultiplier;
};

View File

@ -5,13 +5,13 @@
#include "Camera.h"
#include "Sprite2d.h"
RwIm2DVertex *CSprite2d::maVertices = (RwIm2DVertex*)0x6E9168;
float &CSprite2d::RecipNearClip = *(float*)0x880DB4;
int32 &CSprite2d::mCurrentBank = *(int32*)0x8F1AF4;
RwTexture **CSprite2d::mpBankTextures = (RwTexture**)0x774DC0;
int32 *CSprite2d::mCurrentSprite = (int32*)0x6F4500;
int32 *CSprite2d::mBankStart = (int32*)0x774BE8;
RwIm2DVertex *CSprite2d::maBankVertices = (RwIm2DVertex*)0x8429F8;
RwIm2DVertex CSprite2d::maVertices[4];
float CSprite2d::RecipNearClip;
int32 CSprite2d::mCurrentBank;
RwTexture *CSprite2d::mpBankTextures[10];
int32 CSprite2d::mCurrentSprite[10];
int32 CSprite2d::mBankStart[10];
RwIm2DVertex CSprite2d::maBankVertices[500];
void
CSprite2d::SetRecipNearClip(void)

View File

@ -2,13 +2,13 @@
class CSprite2d
{
static float &RecipNearClip;
static int32 &mCurrentBank;
static RwTexture **mpBankTextures; //[10];
static int32 *mCurrentSprite; //[10];
static int32 *mBankStart; //[10];
static RwIm2DVertex *maBankVertices; //[500];
static RwIm2DVertex *maVertices; //[4];
static float RecipNearClip;
static int32 mCurrentBank;
static RwTexture *mpBankTextures[10];
static int32 mCurrentSprite[10];
static int32 mBankStart[10];
static RwIm2DVertex maBankVertices[500];
static RwIm2DVertex maVertices[4];
public:
RwTexture *m_pTexture;

View File

@ -49,7 +49,7 @@ bool bAllCarCheat; // unused
RwObject *GetCurrentAtomicObjectCB(RwObject *object, void *data);
bool &CAutomobile::m_sAllTaxiLights = *(bool*)0x95CD21;
bool CAutomobile::m_sAllTaxiLights;// = *(bool*)0x95CD21;
CAutomobile::CAutomobile(int32 id, uint8 CreatedBy)
: CVehicle(CreatedBy)

View File

@ -120,7 +120,7 @@ public:
float m_fGasPedalAudio;
tWheelState m_aWheelState[4];
static bool &m_sAllTaxiLights;
static bool m_sAllTaxiLights;
CAutomobile(int32 id, uint8 CreatedBy);

View File

@ -21,16 +21,16 @@
#define INVALID_ORIENTATION (-9999.99f)
float &fShapeLength = *(float*)0x600E78;
float &fShapeTime = *(float*)0x600E7C;
float &fRangeMult = *(float*)0x600E80; //0.6f; // 0.75f gta 3
float &fTimeMult = *(float*)0x943008;
float fShapeLength = 0.4f;// *(float*)0x600E78;
float fShapeTime = 0.05f;// *(float*)0x600E7C;
float fRangeMult = 0.75f; // = *(float*)0x600E80; //0.6f; // 0.75f gta 3
float fTimeMult;// = *(float*)0x943008;
float MAX_WAKE_LENGTH = 50.0f;
float MIN_WAKE_INTERVAL = 1.0f;
float WAKE_LIFETIME = 400.0f;
CBoat * (&CBoat::apFrameWakeGeneratingBoats)[4] = *(CBoat * (*)[4])*(uintptr*)0x8620E0;
CBoat *CBoat::apFrameWakeGeneratingBoats[4];// = *(CBoat * (*)[4]) * (uintptr*)0x8620E0;
CBoat::CBoat(int mi, uint8 owner) : CVehicle(owner)
{

View File

@ -58,7 +58,7 @@ public:
void PruneWakeTrail(void);
void AddWakePoint(CVector point);
static CBoat *(&apFrameWakeGeneratingBoats)[4];
static CBoat *apFrameWakeGeneratingBoats[4];
static bool IsSectorAffectedByWake(CVector2D sector, float fSize, CBoat **apBoats);
static float IsVertexAffectedByWake(CVector vecVertex, CBoat *pBoat);

View File

@ -7,10 +7,9 @@
#include "Vehicle.h"
#include "Floater.h"
cBuoyancy &mod_Buoyancy = *(cBuoyancy*)0x8F2674;
cBuoyancy mod_Buoyancy;// = *(cBuoyancy*)0x8F2674;
//static float fVolMultiplier = 1.0f;
static float &fVolMultiplier = *(float*)0x601394;
static float fVolMultiplier = 1.0f; // 0x601394;
// amount of boat volume in bounding box
// 1.0-volume is the empty space in the bbox
static float fBoatVolumeDistribution[9] = {

View File

@ -42,4 +42,4 @@ public:
void FindWaterLevel(const CVector &zpos, CVector *waterLevel, tWaterLevel *waterPosition);
bool CalcBuoyancyForce(CPhysical *phys, CVector *impulse, CVector *point);
};
extern cBuoyancy &mod_Buoyancy;
extern cBuoyancy mod_Buoyancy;

View File

@ -4,7 +4,7 @@
#include "FileMgr.h"
#include "HandlingMgr.h"
cHandlingDataMgr &mod_HandlingManager = *(cHandlingDataMgr*)0x728060;
cHandlingDataMgr mod_HandlingManager;// = *(cHandlingDataMgr*)0x728060;
const char *HandlingFilename = "HANDLING.CFG";

View File

@ -140,4 +140,4 @@ public:
bool HasFrontWheelDrive(eHandlingId id) { return HandlingData[id].Transmission.nDriveType == 'F'; }
};
VALIDATE_SIZE(cHandlingDataMgr, 0x3030);
extern cHandlingDataMgr &mod_HandlingManager;
extern cHandlingDataMgr mod_HandlingManager;

View File

@ -34,13 +34,13 @@ enum
HELI_STATUS_HOVER2,
};
CHeli **CHeli::pHelis = (CHeli**)0x72CF50;
int16 &CHeli::NumRandomHelis = *(int16*)0x95CCAA;
uint32 &CHeli::TestForNewRandomHelisTimer = *(uint32*)0x8F1A7C;
CHeli *CHeli::pHelis[NUM_HELIS];// = (CHeli**)0x72CF50;
int16 CHeli::NumRandomHelis;// = *(int16*)0x95CCAA;
uint32 CHeli::TestForNewRandomHelisTimer;// = *(uint32*)0x8F1A7C;
int16 CHeli::NumScriptHelis; // unused
bool &CHeli::CatalinaHeliOn = *(bool*)0x95CD85;
bool &CHeli::CatalinaHasBeenShotDown = *(bool*)0x95CD56;
bool &CHeli::ScriptHeliOn = *(bool*)0x95CD43;
bool CHeli::CatalinaHeliOn;// = *(bool*)0x95CD85;
bool CHeli::CatalinaHasBeenShotDown;// = *(bool*)0x95CD56;
bool CHeli::ScriptHeliOn;// = *(bool*)0x95CD43;
CHeli::CHeli(int32 id, uint8 CreatedBy)
: CVehicle(CreatedBy)

View File

@ -61,13 +61,13 @@ public:
float m_fTargetOffset;
bool m_bTestRight;
static CHeli **pHelis; //[NUM_HELIS]
static int16 &NumRandomHelis;
static uint32 &TestForNewRandomHelisTimer;
static CHeli *pHelis[NUM_HELIS];
static int16 NumRandomHelis;
static uint32 TestForNewRandomHelisTimer;
static int16 NumScriptHelis; // unused
static bool &CatalinaHeliOn;
static bool &CatalinaHasBeenShotDown;
static bool &ScriptHeliOn;
static bool CatalinaHeliOn;
static bool CatalinaHasBeenShotDown;
static bool ScriptHeliOn;
CHeli(int32 id, uint8 CreatedBy);
CHeli* ctor(int, uint8);

View File

@ -16,35 +16,35 @@
#include "HandlingMgr.h"
#include "Plane.h"
CPlaneNode *&pPathNodes = *(CPlaneNode**)0x8F1B68;
CPlaneNode *&pPath2Nodes = *(CPlaneNode**)0x885B8C;
CPlaneNode *&pPath3Nodes = *(CPlaneNode**)0x885B78;
CPlaneNode *&pPath4Nodes = *(CPlaneNode**)0x885AD8;
int32 &NumPathNodes = *(int32*)0x8F2BE4;
int32 &NumPath2Nodes = *(int32*)0x941498;
int32 &NumPath3Nodes = *(int32*)0x9414D8;
int32 &NumPath4Nodes = *(int32*)0x9412C8;
float &TotalLengthOfFlightPath = *(float*)0x8F2C6C;
float &TotalLengthOfFlightPath2 = *(float*)0x64CFBC;
float &TotalLengthOfFlightPath3 = *(float*)0x64CFD0;
float &TotalLengthOfFlightPath4 = *(float*)0x64CFDC;
float &TotalDurationOfFlightPath = *(float*)0x64CFB8;
float &TotalDurationOfFlightPath2 = *(float*)0x64CFC0;
float &TotalDurationOfFlightPath3 = *(float*)0x64CFD4;
float &TotalDurationOfFlightPath4 = *(float*)0x64CFE0;
float &LandingPoint = *(float*)0x8F2C7C;
float &TakeOffPoint = *(float*)0x8E28A4;
CPlaneInterpolationLine *aPlaneLineBits = (CPlaneInterpolationLine*)0x734168; //[6]
CPlaneNode *pPathNodes;// = *(CPlaneNode**)0x8F1B68;
CPlaneNode *pPath2Nodes;// = *(CPlaneNode**)0x885B8C;
CPlaneNode *pPath3Nodes;// = *(CPlaneNode**)0x885B78;
CPlaneNode *pPath4Nodes;// = *(CPlaneNode**)0x885AD8;
int32 NumPathNodes;// = *(int32*)0x8F2BE4;
int32 NumPath2Nodes;// = *(int32*)0x941498;
int32 NumPath3Nodes;// = *(int32*)0x9414D8;
int32 NumPath4Nodes;// = *(int32*)0x9412C8;
float TotalLengthOfFlightPath;// = *(float*)0x8F2C6C;
float TotalLengthOfFlightPath2;// = *(float*)0x64CFBC;
float TotalLengthOfFlightPath3;// = *(float*)0x64CFD0;
float TotalLengthOfFlightPath4;// = *(float*)0x64CFDC;
float TotalDurationOfFlightPath;// = *(float*)0x64CFB8;
float TotalDurationOfFlightPath2;// = *(float*)0x64CFC0;
float TotalDurationOfFlightPath3;// = *(float*)0x64CFD4;
float TotalDurationOfFlightPath4;// = *(float*)0x64CFE0;
float LandingPoint;// = *(float*)0x8F2C7C;
float TakeOffPoint;// = *(float*)0x8E28A4;
CPlaneInterpolationLine aPlaneLineBits[6]; // = (CPlaneInterpolationLine*)0x734168;
float *PlanePathPosition = (float*)0x8F5FC8; //[3]
float *OldPlanePathPosition = (float*)0x8F5FBC; //[3]
float *PlanePathSpeed = (float*)0x941538; //[3]
float *PlanePath2Position = (float*)0x64CFC4; //[3]
float &PlanePath3Position = *(float*)0x64CFD8;
float &PlanePath4Position = *(float*)0x64CFE4;
float *PlanePath2Speed = (float*)0x8F1A54; //[3]
float &PlanePath3Speed = *(float*)0x8F1A94;
float &PlanePath4Speed = *(float*)0x8F1AFC;
float PlanePathPosition[3];// = (float*)0x8F5FC8; //[3]
float OldPlanePathPosition[3];// = (float*)0x8F5FBC; //[3]
float PlanePathSpeed[3];// = (float*)0x941538; //[3]
float PlanePath2Position[3];// = (float*)0x64CFC4; //[3]
float PlanePath3Position;// = *(float*)0x64CFD8;
float PlanePath4Position;// = *(float*)0x64CFE4;
float PlanePath2Speed[3];// = (float*)0x8F1A54; //[3]
float PlanePath3Speed;// = *(float*)0x8F1A94;
float PlanePath4Speed;// = *(float*)0x8F1AFC;
enum

View File

@ -67,6 +67,6 @@ public:
};
static_assert(sizeof(CPlane) == 0x29C, "CPlane: error");
extern float &LandingPoint;
extern float &TakeOffPoint;
extern float *PlanePathPosition; //[3]
extern float LandingPoint;
extern float TakeOffPoint;
extern float PlanePathPosition[3];

View File

@ -14,23 +14,23 @@
#include "HandlingMgr.h"
#include "Train.h"
static CTrainNode *&pTrackNodes = *(CTrainNode**)0x8F4338;
static int16 &NumTrackNodes = *(int16*)0x95CC5C;
static CTrainNode* pTrackNodes;
static int16 NumTrackNodes;
static float StationDist[3] = { 873.0f, 1522.0f, 2481.0f };
static float &TotalLengthOfTrack = *(float*)0x64D000;
static float &TotalDurationOfTrack = *(float*)0x64D004;
static CTrainInterpolationLine *aLineBits = (CTrainInterpolationLine*)0x70D838; // [17]
static float *EngineTrackPosition = (float*)0x64D008; //[2]
static float *EngineTrackSpeed = (float*)0x880848; //[2]
static float TotalLengthOfTrack;
static float TotalDurationOfTrack;
static CTrainInterpolationLine aLineBits[17];
static float EngineTrackPosition[2];
static float EngineTrackSpeed[2];
static CTrainNode *&pTrackNodes_S = *(CTrainNode**)0x8F2560;
static int16 &NumTrackNodes_S = *(int16*)0x95CC6A;
static CTrainNode* pTrackNodes_S;
static int16 NumTrackNodes_S;
static float StationDist_S[4] = { 55.0f, 1388.0f, 2337.0f, 3989.0f };
static float &TotalLengthOfTrack_S = *(float*)0x64D010;
static float &TotalDurationOfTrack_S = *(float*)0x64D014;
static CTrainInterpolationLine *aLineBits_S = (CTrainInterpolationLine*)0x726600; // [18]
static float *EngineTrackPosition_S = (float*)0x64D018; //[4]
static float *EngineTrackSpeed_S = (float*)0x87C7C8; //[4]
static float TotalLengthOfTrack_S;
static float TotalDurationOfTrack_S;
static CTrainInterpolationLine aLineBits_S[18];
static float EngineTrackPosition_S[4];
static float EngineTrackSpeed_S[4];
CVector CTrain::aStationCoors[3];
CVector CTrain::aStationCoors_S[4];