#SingleInstance Force
#Persistent
#NoEnv
#Include UDF.ahk
F4::
if (getZoneByName2("Los Santos", CurZone) <> "Unknown")
{
addChatMessage(CurZone[1])
addChatMessage(CurZone[2])
addChatMessage(CurZone[3,1,1])
addChatMessage(CurZone[3,1,2])
addChatMessage(CurZone[3,1,3])
addChatMessage(CurZone[3,2,1])
addChatMessage(CurZone[3,2,2])
addChatMessage(CurZone[3,2,3])
}
else addChatMessage("Unknown")
return
getZoneByName2(zName, ByRef CurZone ) {
CurZone := []
if ( bInitZaC == 0 )
{
initZonesAndCities()
bInitZaC := 1
}
Loop % nZone-1
{
if (zone%A_Index%_name == zName)
{
ErrorLevel := ERROR_OK
CurZone[1] := zone%A_Index%_name
CurZone[2] := A_Index
CurZone[3,1,1] := zone%A_Index%_x1
CurZone[3,1,2] := zone%A_Index%_y1
CurZone[3,1,3] := zone%A_Index%_z1
CurZone[3,2,1] := zone%A_Index%_x2
CurZone[3,2,2] := zone%A_Index%_y2
CurZone[3,2,3] := zone%A_Index%_z2
return true
}
}
ErrorLevel := ERROR_ZONE_NOT_FOUND
return "Unknown"
}