Help me to disable the Default trainer Natives?

i got something working here, apparantly false for invisibility means true lol

And the citizen wait needs to be inside the while loop.

So far, ive had to remove the space in between the element name and the target process toggle for it to even work. But the game keeps loading forever with that invisibility fix he gave me. It is indeed trying to work tho, just something is acting weird! Currently am loaded in with this and it works fine, but its like the explosive ammo and invisibility are automatically on instead of off, so they need to be true maybe, God mode and radar seem to be correct, but anything ammunition wise is a opposite effect.

Edit> Note that when you set them to true, the game will not load. Trying to set to a value of 0 instead

Citizen.CreateThread(function()
    while true do
		DisplayRadar(false)
		SetExplosiveAmmoThisFrame(false)
		SetExplosiveMeleeThisFrame(false)
		SetFireAmmoThisFrame(false)
		SetPlayerInvincible(false)
		Citizen.Wait(1)		
	 end			 
end)

1 Saves the day! But explosive ammo and invisibility(may need more native calls) do not seem to be sticking if you change them on client side

Citizen.CreateThread(function()
    while true do
		DisplayRadar(false)
		SetExplosiveAmmoThisFrame(1)
		SetExplosiveMeleeThisFrame(1)
		SetFireAmmoThisFrame(1)
		SetPlayerInvisibleLocally(1)
		SetPlayerInvincible(false)
		Citizen.Wait(0)		
	 end			 
end)
local Player = (GetPlayerPed(-1)

Citizen.CreateThread(function()
    while true do
		DisplayRadar(false)
		SetExplosiveAmmoThisFrame(Player, 1)
		SetExplosiveMeleeThisFrame(Player, 1)
		SetFireAmmoThisFrame(Player, 1)
		SetPlayerInvisibleLocally(Player, true)
		SetPlayerInvincible(false)
		Citizen.Wait(0)		
	 end			 
end)

NativeDB

NETWORK::SET_PLAYER_INVISIBLE_LOCALLY

Hashes: 0x12B37D54667DB0B8 0x18227209
void SET_PLAYER_INVISIBLE_LOCALLY(Player player, BOOL toggle)
// 0x12B37D54667DB0B8 0x18227209

GAMEPLAY::SET_FIRE_AMMO_THIS_FRAME

Hashes: 0x11879CDD803D30F4 0x7C18FC8A
void SET_FIRE_AMMO_THIS_FRAME(Player player) // 0x11879CDD803D30F4 0x7C18FC8A

GAMEPLAY::SET_EXPLOSIVE_MELEE_THIS_FRAME

Hashes: 0xFF1BED81BFDC0FE0 0x96663D56
void SET_EXPLOSIVE_MELEE_THIS_FRAME(Player player)
// 0xFF1BED81BFDC0FE0 0x96663D56

GAMEPLAY::SET_EXPLOSIVE_AMMO_THIS_FRAME

Hashes: 0xA66C71C98D5F2CFB 0x2EAFA1D1
void SET_EXPLOSIVE_AMMO_THIS_FRAME(Player player)
// 0xA66C71C98D5F2CFB 0x2EAFA1D1

It requires the ‘Player’ to be defined as far as I would say… (GetPlayerPed(-1) = is always the Player.

GetPlayerPed(-1) returns the player PED, which isn’t required here.

PlayerId() is what he needs.

1 Like

GetPlayerFromServerId() returns a “usable” player ID.