function debugInformation(entity)
local entityType = GetEntityType(entity);
if entityType < 1 or entityType > 3 then
return;
end
local netId = NetworkGetNetworkIdFromEntity(entity);
local modelName = Citizen.InvokeNative(0x47B870F5, entity);
local coords = GetEntityCoords(entity);
local text = ('NetId: %s \nModel:%s\nCoords:%s'):format(netId, modelName, coords);
print(text);
end
The analog that I found also doesn’t work with many things, maybe I’m doing it wrong, but I was able to make it work only with weapons
This native return always empty string
function debugInformation(entity)
local entityType = GetEntityType(entity);
if entityType < 1 or entityType > 3 then
return;
end
local netId = NetworkGetNetworkIdFromEntity(entity);
local name = Citizen.InvokeNative(0xBD5DD5EAE2B6CE14, GetEntityModel(entity), Citizen.ResultAsString()); -- GetStringFromHashKey
local coords = GetEntityCoords(entity);
local text = ('NetId: %s \nModel:%s\nCoords:%s'):format(netId, name, coords);
print(text);
end