Solved Instantiatng a gameobjct to the given pos

Hexui Undetected CSGO Cheats Sinkicheat PUBG Cheat

petruherro

Newbie
Full Member
Mar 10, 2016
17
104
0
Hi! I am currently trying to "hack" gta: san andreas.
I have already got some variables(pointers) like health, money, armour, weapons, etc. But how can i spawn a car for example?
 

Nazalas

Coder
Dank Tier VIP
Dank Tier Donator
May 20, 2015
99
3,963
3
After looking around for a few minutes, I see that GTA:SA has been documented like crazy. You can find function pointers to just about anything you want with google. I am not sure if these will still work or not but a quick search gave me these.

C++:
// model functions
#define ARRAY_ModelLoaded				0x8E4CD0
#define ARRAY_ModelInfo					0xA9B0C8
#define FUNC_CStreaming__HasModelLoaded 0x4044C0
#define FUNC_GetModelFlags				0x4044E0
#define FUNC_GetBoundingBox				0x4082F0
#define FUNC_RequestModel				0x4087e0
#define FUNC_RemoveModel				0x4089a0
#define FUNC_LoadAllRequestedModels		0x40ea10
#define FUNC_FlushRequestList			0x40E4E0

// vehicle functions
#define FUNC_IsBoatModel				0x4c5a70
#define FUNC_IsCarModel					0x4c5aa0
#define FUNC_IsTrainModel				0x4c5ad0
#define FUNC_IsHeliModel				0x4c5b00
#define FUNC_IsPlaneModel				0x4c5b30
#define FUNC_IsBikeModel				0x4c5b60
#define FUNC_IsFakePlaneModel			0x4c5b90
#define FUNC_IsMonsterTruckModel		0x4c5bc0
#define FUNC_IsQuadBikeModel			0x4c5bf0
#define FUNC_IsBmxModel					0x4c5c20
#define FUNC_IsTrailerModel				0x4c5c50
#define FUNC_IsVehicleModelType			0x4c5c80
#define FUNC_HasVehicleUpgradeLoaded	0x407820
#define FUNC_RequestMyVehicleUpgrade	0x408C70
#define FUNC_RequestAnyVehicleUpgrade	0x6E3290

//#define		FUNC_CVehicle__SetRemapTexDictionary 0x6D0BC0
#define FUNC_CVehicle__GetRemapIndex	0x6D0B70
#define FUNC_CVehicle__SetRemap			0x6D0C00

// new vehicle functions
#define FUNC_CVehicle_IsUpsideDown			0x6D1D90
#define FUNC_CVehicle_IsOnItsSide			0x6D1DD0
#define FUNC_CVehicle_RecalcOnRailDistance	0x6F6CC0

// VideoMode functions
#define GFUNC_SetCurrentVideoMode	0x745C70
#define GFUNC_GetCurrentVideoMode	0x7F2D20
#define GFUNC_GetNumVideoModes		0x7F2CC0
#define GFUNC_GetVideoModeInfo		0x7F2CF0
#define FUNC_RwD3D9ChangeVideoMode	0x7F8640

// entity gravity/movement functions
#define FUNC_GetMoveSpeed	0x404460

// CWorld functions
#define FUNC_IsLineOfSightClear 0x56A490	// ##SA##
#define FUNC_ProcessLineOfSight 0x56BA00	// ##SA##

// gta class addresses
#define CLASS_CMenuManager	0xBA6748
 

Nazalas

Coder
Dank Tier VIP
Dank Tier Donator
May 20, 2015
99
3,963
3
I believe that the easiest way to do something like this would to be call the in game methods directly that already do these things. I would try to see if you can find the vtable and go from there.
 

petruherro

Newbie
Full Member
Mar 10, 2016
17
104
0
After looking around for a few minutes, I see that GTA:SA has been documented like crazy. You can find function pointers to just about anything you want with google. I am not sure if these will still work or not but a quick search gave me these.

C++:
// model functions
#define ARRAY_ModelLoaded				0x8E4CD0
#define ARRAY_ModelInfo					0xA9B0C8
#define FUNC_CStreaming__HasModelLoaded 0x4044C0
#define FUNC_GetModelFlags				0x4044E0
#define FUNC_GetBoundingBox				0x4082F0
#define FUNC_RequestModel				0x4087e0
#define FUNC_RemoveModel				0x4089a0
#define FUNC_LoadAllRequestedModels		0x40ea10
#define FUNC_FlushRequestList			0x40E4E0

// vehicle functions
#define FUNC_IsBoatModel				0x4c5a70
#define FUNC_IsCarModel					0x4c5aa0
#define FUNC_IsTrainModel				0x4c5ad0
#define FUNC_IsHeliModel				0x4c5b00
#define FUNC_IsPlaneModel				0x4c5b30
#define FUNC_IsBikeModel				0x4c5b60
#define FUNC_IsFakePlaneModel			0x4c5b90
#define FUNC_IsMonsterTruckModel		0x4c5bc0
#define FUNC_IsQuadBikeModel			0x4c5bf0
#define FUNC_IsBmxModel					0x4c5c20
#define FUNC_IsTrailerModel				0x4c5c50
#define FUNC_IsVehicleModelType			0x4c5c80
#define FUNC_HasVehicleUpgradeLoaded	0x407820
#define FUNC_RequestMyVehicleUpgrade	0x408C70
#define FUNC_RequestAnyVehicleUpgrade	0x6E3290

//#define		FUNC_CVehicle__SetRemapTexDictionary 0x6D0BC0
#define FUNC_CVehicle__GetRemapIndex	0x6D0B70
#define FUNC_CVehicle__SetRemap			0x6D0C00

// new vehicle functions
#define FUNC_CVehicle_IsUpsideDown			0x6D1D90
#define FUNC_CVehicle_IsOnItsSide			0x6D1DD0
#define FUNC_CVehicle_RecalcOnRailDistance	0x6F6CC0

// VideoMode functions
#define GFUNC_SetCurrentVideoMode	0x745C70
#define GFUNC_GetCurrentVideoMode	0x7F2D20
#define GFUNC_GetNumVideoModes		0x7F2CC0
#define GFUNC_GetVideoModeInfo		0x7F2CF0
#define FUNC_RwD3D9ChangeVideoMode	0x7F8640

// entity gravity/movement functions
#define FUNC_GetMoveSpeed	0x404460

// CWorld functions
#define FUNC_IsLineOfSightClear 0x56A490	// ##SA##
#define FUNC_ProcessLineOfSight 0x56BA00	// ##SA##

// gta class addresses
#define CLASS_CMenuManager	0xBA6748
Thanks a lot!
 
Attention! Before you post:

Read the How to Ask Questions Guide
99% of questions are answered in the Beginner's Guide, do it before asking a question.

No Hack Requests. Post in the correct section.  Search the forum first. Read the rules.

How to make a good post:

  • Fill out the form correctly
  • Tell us the game name & coding language
  • Post everything we need to know to help you
  • Ask specific questions, be descriptive
  • Post errors, line numbers & screenshots
  • Post code snippets using code tags
  • If it's a large project, zip it up and attach it

If you do not comply, your post may be deleted.  We want to help, please make a good post and we will do our best to help you.

Community Mods