Hi. As title says I want to know what is the difference between these two, because I see that some people use the first one and the others the seconds one in same natives (for example TaskPlayAnim).
GetPlayerPed(-1) is an old habit from the older games like GTA IV and before, in V there’s PlayerPedId() which should be used and is also much faster.
Hence in newer games such as RDR3 (Red Dead Redemption 2) GetPlayerPed(-1) doesn’t even work anymore.
23 Likes
Hi!
Could you tell me the program or how to know the ms from the code?
Thanks
profiler
in the console
How did you test this? Could you maybe post your code for both? Or is it just:
Citizen.CreateThread(function()
local a = GetPlayerPedId(-1)
end)
and
Citizen.CreateThread(function()
local a = PlayerPedId()
end)