I am trying to get some basic statistics from the game such as civilians killed, cops killed, etc. Every stat I try to fetch is returning 0.
function killStats()
ret, inn = StatGetInt(GetHashKey("KILLS_INNOCENTS"), -1)
ret, cop = StatGetInt(GetHashKey("KILLS_COP"), -1)
ret, swat = StatGetInt(GetHashKey("KILLS_SWAT"), -1)
ret, gang1 = StatGetInt(GetHashKey("KILLS_ENEMY_GANG_MEMBERS"), -1)
ret, gang2 = StatGetInt(GetHashKey("KILLS_FRIENDLY_GANG_MEMBERS"), -1)
ret, car = StatGetFloat(GetHashKey("DIST_CAR"), -1)
print('Innocents: '..inn)
print('Cops: '..cop)
print('Swat: '..swat)
print('Enemy Gang: '..gang1)
print('Friendly Gang: '..gang2)
print('car dist: '..car)
end
Am I missing something here? Is this the correct usage?
I want to create some mini-games and these numbers are crucial before I can move on.
Thanks