Try this ( untested ):
function theLocator()
local allLocation = {"Las Venturas",
"San Fierro",
"Whetstone",
"Flint County",
"Red County",
"Los Santos"}
local players = getElementsByType ( "player" )
for i, source in ipairs ( players ) do
local theLocation = getElementZoneName(source, true)
for theKey, allLocation in ipairs(allLocation) do
if (theLocation == allLocation) then
killPed(source)
end
end
end
end
function startLocator()
setTimer ( theLocator, 1000, 0 )
end
addEventHandler ( "onResourceStart", getResourceRootElement(getThisResource()), startLocator )