Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- ; CurZone[1] - Zone Name
- ; CurZone[2] - Zone ID
- ; CurZone[3] - Array of arrays points positions
- ; CurZone[3,1] - Array of thirst point position
- ; CurZone[3,1,1] - Zone X1
- ; CurZone[3,1,2] - Zone Y1
- ; CurZone[3,1,3] - Zone Z1
- ; CurZone[3,2] - Array of second point position
- ; CurZone[3,2,1] - Zone X2
- ; CurZone[3,2,2] - Zone Y2
- ; CurZone[3,2,3] - Zone Z2
- getZoneByName(zName, ByRef 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 "Unbekannt"
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement