Begin A1_DAT_SRT_CoE_V_Lo

Short Teleport
Short CellX
Short CellY
Float Pos

; only run If Teleporting
Set Teleport to "A1_DAT_SRT_TeleState"
If ( Teleport != 1 )
  Return
EndIf

; calculate destination Cells
Set Pos to "A1_DAT_SRT_RecPosX"
Set CellX to ( Pos / 8192 )
Set Pos to "A1_DAT_SRT_RecPosY"
Set CellY to ( Pos / 8192 )

; try to Teleport

; Range (0,-11) to (0,23)
If ( CellY == 0 )
 If ( CellX == -11 )
  CoE -11 0
 ElseIf ( CellX == -10 )
  CoE -10 0
 ElseIf ( CellX == -9 )
  CoE -9 0
 ElseIf ( CellX == -8 )
  CoE -8 0
 ElseIf ( CellX == -7 )
  CoE -7 0
 ElseIf ( CellX == -6 )
  CoE -6 0
 ElseIf ( CellX == -5 )
  CoE -5 0
 ElseIf ( CellX == -4 )
  CoE -4 0
 ElseIf ( CellX == -3 )
  CoE -3 0
 ElseIf ( CellX == -2 )
  CoE -2 0
 ElseIf ( CellX == -1 )
  CoE -1 0
 ElseIf ( CellX == 0 )
  CoE 0 0
 ElseIf ( CellX == 1 )
  CoE 1 0
 ElseIf ( CellX == 2 )
  CoE 2 0
 ElseIf ( CellX == 3 )
  CoE 3 0
 ElseIf ( CellX == 4 )
  CoE 4 0
 ElseIf ( CellX == 5 )
  CoE 5 0
 ElseIf ( CellX == 6 )
  CoE 6 0
 ElseIf ( CellX == 7 )
  CoE 7 0
 ElseIf ( CellX == 8 )
  CoE 8 0
 ElseIf ( CellX == 9 )
  CoE 9 0
 ElseIf ( CellX == 10 )
  CoE 10 0
 ElseIf ( CellX == 11 )
  CoE 11 0
 ElseIf ( CellX == 12 )
  CoE 12 0
 ElseIf ( CellX == 13 )
  CoE 13 0
 ElseIf ( CellX == 14 )
  CoE 14 0
 ElseIf ( CellX == 15 )
  CoE 15 0
 ElseIf ( CellX == 16 )
  CoE 16 0
 ElseIf ( CellX == 17 )
  CoE 17 0
 ElseIf ( CellX == 18 )
  CoE 18 0
 ElseIf ( CellX == 19 )
  CoE 19 0
 ElseIf ( CellX == 20 )
  CoE 20 0
 ElseIf ( CellX == 21 )
  CoE 21 0
 ElseIf ( CellX == 22 )
  CoE 22 0
 ElseIf ( CellX == 23 )
  CoE 23 0
 EndIf
EndIf

; Range (-1,-11) to (-1,23)
If ( CellY == -1 )
 If ( CellX == -11 )
  CoE -11 -1
 ElseIf ( CellX == -10 )
  CoE -10 -1
 ElseIf ( CellX == -9 )
  CoE -9 -1
 ElseIf ( CellX == -8 )
  CoE -8 -1
 ElseIf ( CellX == -7 )
  CoE -7 -1
 ElseIf ( CellX == -6 )
  CoE -6 -1
 ElseIf ( CellX == -5 )
  CoE -5 -1
 ElseIf ( CellX == -4 )
  CoE -4 -1
 ElseIf ( CellX == -3 )
  CoE -3 -1
 ElseIf ( CellX == -2 )
  CoE -2 -1
 ElseIf ( CellX == -1 )
  CoE -1 -1
 ElseIf ( CellX == 0 )
  CoE 0 -1
 ElseIf ( CellX == 1 )
  CoE 1 -1
 ElseIf ( CellX == 2 )
  CoE 2 -1
 ElseIf ( CellX == 3 )
  CoE 3 -1
 ElseIf ( CellX == 4 )
  CoE 4 -1
 ElseIf ( CellX == 5 )
  CoE 5 -1
 ElseIf ( CellX == 6 )
  CoE 6 -1
 ElseIf ( CellX == 7 )
  CoE 7 -1
 ElseIf ( CellX == 8 )
  CoE 8 -1
 ElseIf ( CellX == 9 )
  CoE 9 -1
 ElseIf ( CellX == 10 )
  CoE 10 -1
 ElseIf ( CellX == 11 )
  CoE 11 -1
 ElseIf ( CellX == 12 )
  CoE 12 -1
 ElseIf ( CellX == 13 )
  CoE 13 -1
 ElseIf ( CellX == 14 )
  CoE 14 -1
 ElseIf ( CellX == 15 )
  CoE 15 -1
 ElseIf ( CellX == 16 )
  CoE 16 -1
 ElseIf ( CellX == 17 )
  CoE 17 -1
 ElseIf ( CellX == 18 )
  CoE 18 -1
 ElseIf ( CellX == 19 )
  CoE 19 -1
 ElseIf ( CellX == 20 )
  CoE 20 -1
 ElseIf ( CellX == 21 )
  CoE 21 -1
 ElseIf ( CellX == 22 )
  CoE 22 -1
 ElseIf ( CellX == 23 )
  CoE 23 -1
 EndIf
EndIf

; Range (-2,-10) to (-2,23)
If ( CellY == -2 )
 If ( CellX == -10 )
  CoE -10 -2
 ElseIf ( CellX == -9 )
  CoE -9 -2
 ElseIf ( CellX == -8 )
  CoE -8 -2
 ElseIf ( CellX == -7 )
  CoE -7 -2
 ElseIf ( CellX == -6 )
  CoE -6 -2
 ElseIf ( CellX == -5 )
  CoE -5 -2
 ElseIf ( CellX == -4 )
  CoE -4 -2
 ElseIf ( CellX == -3 )
  CoE -3 -2
 ElseIf ( CellX == -2 )
  CoE -2 -2
 ElseIf ( CellX == -1 )
  CoE -1 -2
 ElseIf ( CellX == 0 )
  CoE 0 -2
 ElseIf ( CellX == 1 )
  CoE 1 -2
 ElseIf ( CellX == 2 )
  CoE 2 -2
 ElseIf ( CellX == 3 )
  CoE 3 -2
 ElseIf ( CellX == 4 )
  CoE 4 -2
 ElseIf ( CellX == 5 )
  CoE 5 -2
 ElseIf ( CellX == 6 )
  CoE 6 -2
 ElseIf ( CellX == 7 )
  CoE 7 -2
 ElseIf ( CellX == 8 )
  CoE 8 -2
 ElseIf ( CellX == 9 )
  CoE 9 -2
 ElseIf ( CellX == 10 )
  CoE 10 -2
 ElseIf ( CellX == 11 )
  CoE 11 -2
 ElseIf ( CellX == 12 )
  CoE 12 -2
 ElseIf ( CellX == 13 )
  CoE 13 -2
 ElseIf ( CellX == 14 )
  CoE 14 -2
 ElseIf ( CellX == 15 )
  CoE 15 -2
 ElseIf ( CellX == 16 )
  CoE 16 -2
 ElseIf ( CellX == 17 )
  CoE 17 -2
 ElseIf ( CellX == 18 )
  CoE 18 -2
 ElseIf ( CellX == 19 )
  CoE 19 -2
 ElseIf ( CellX == 20 )
  CoE 20 -2
 ElseIf ( CellX == 21 )
  CoE 21 -2
 ElseIf ( CellX == 22 )
  CoE 22 -2
 ElseIf ( CellX == 23 )
  CoE 23 -2
 EndIf
EndIf

; Range (-3,-10) to (-3,23)
If ( CellY == -3 )
 If ( CellX == -10 )
  CoE -10 -3
 ElseIf ( CellX == -9 )
  CoE -9 -3
 ElseIf ( CellX == -8 )
  CoE -8 -3
 ElseIf ( CellX == -7 )
  CoE -7 -3
 ElseIf ( CellX == -6 )
  CoE -6 -3
 ElseIf ( CellX == -5 )
  CoE -5 -3
 ElseIf ( CellX == -4 )
  CoE -4 -3
 ElseIf ( CellX == -3 )
  CoE -3 -3
 ElseIf ( CellX == -2 )
  CoE -2 -3
 ElseIf ( CellX == -1 )
  CoE -1 -3
 ElseIf ( CellX == 0 )
  CoE 0 -3
 ElseIf ( CellX == 1 )
  CoE 1 -3
 ElseIf ( CellX == 2 )
  CoE 2 -3
 ElseIf ( CellX == 3 )
  CoE 3 -3
 ElseIf ( CellX == 4 )
  CoE 4 -3
 ElseIf ( CellX == 5 )
  CoE 5 -3
 ElseIf ( CellX == 6 )
  CoE 6 -3
 ElseIf ( CellX == 7 )
  CoE 7 -3
 ElseIf ( CellX == 8 )
  CoE 8 -3
 ElseIf ( CellX == 9 )
  CoE 9 -3
 ElseIf ( CellX == 10 )
  CoE 10 -3
 ElseIf ( CellX == 11 )
  CoE 11 -3
 ElseIf ( CellX == 12 )
  CoE 12 -3
 ElseIf ( CellX == 13 )
  CoE 13 -3
 ElseIf ( CellX == 14 )
  CoE 14 -3
 ElseIf ( CellX == 15 )
  CoE 15 -3
 ElseIf ( CellX == 16 )
  CoE 16 -3
 ElseIf ( CellX == 17 )
  CoE 17 -3
 ElseIf ( CellX == 18 )
  CoE 18 -3
 ElseIf ( CellX == 19 )
  CoE 19 -3
 ElseIf ( CellX == 20 )
  CoE 20 -3
 ElseIf ( CellX == 21 )
  CoE 21 -3
 ElseIf ( CellX == 22 )
  CoE 22 -3
 ElseIf ( CellX == 23 )
  CoE 23 -3
 EndIf
EndIf

; Range (-4,-10) to (-4,23)
If ( CellY == -4 )
 If ( CellX == -10 )
  CoE -10 -4
 ElseIf ( CellX == -9 )
  CoE -9 -4
 ElseIf ( CellX == -8 )
  CoE -8 -4
 ElseIf ( CellX == -7 )
  CoE -7 -4
 ElseIf ( CellX == -6 )
  CoE -6 -4
 ElseIf ( CellX == -5 )
  CoE -5 -4
 ElseIf ( CellX == -4 )
  CoE -4 -4
 ElseIf ( CellX == -3 )
  CoE -3 -4
 ElseIf ( CellX == -2 )
  CoE -2 -4
 ElseIf ( CellX == -1 )
  CoE -1 -4
 ElseIf ( CellX == 0 )
  CoE 0 -4
 ElseIf ( CellX == 1 )
  CoE 1 -4
 ElseIf ( CellX == 2 )
  CoE 2 -4
 ElseIf ( CellX == 3 )
  CoE 3 -4
 ElseIf ( CellX == 4 )
  CoE 4 -4
 ElseIf ( CellX == 5 )
  CoE 5 -4
 ElseIf ( CellX == 6 )
  CoE 6 -4
 ElseIf ( CellX == 7 )
  CoE 7 -4
 ElseIf ( CellX == 8 )
  CoE 8 -4
 ElseIf ( CellX == 9 )
  CoE 9 -4
 ElseIf ( CellX == 10 )
  CoE 10 -4
 ElseIf ( CellX == 11 )
  CoE 11 -4
 ElseIf ( CellX == 12 )
  CoE 12 -4
 ElseIf ( CellX == 13 )
  CoE 13 -4
 ElseIf ( CellX == 14 )
  CoE 14 -4
 ElseIf ( CellX == 15 )
  CoE 15 -4
 ElseIf ( CellX == 16 )
  CoE 16 -4
 ElseIf ( CellX == 17 )
  CoE 17 -4
 ElseIf ( CellX == 18 )
  CoE 18 -4
 ElseIf ( CellX == 19 )
  CoE 19 -4
 ElseIf ( CellX == 20 )
  CoE 20 -4
 ElseIf ( CellX == 21 )
  CoE 21 -4
 ElseIf ( CellX == 22 )
  CoE 22 -4
 ElseIf ( CellX == 23 )
  CoE 23 -4
 EndIf
EndIf

; Range (-5,-10) to (-5,23)
If ( CellY == -5 )
 If ( CellX == -10 )
  CoE -10 -5
 ElseIf ( CellX == -9 )
  CoE -9 -5
 ElseIf ( CellX == -8 )
  CoE -8 -5
 ElseIf ( CellX == -7 )
  CoE -7 -5
 ElseIf ( CellX == -6 )
  CoE -6 -5
 ElseIf ( CellX == -5 )
  CoE -5 -5
 ElseIf ( CellX == -4 )
  CoE -4 -5
 ElseIf ( CellX == -3 )
  CoE -3 -5
 ElseIf ( CellX == -2 )
  CoE -2 -5
 ElseIf ( CellX == -1 )
  CoE -1 -5
 ElseIf ( CellX == 0 )
  CoE 0 -5
 ElseIf ( CellX == 1 )
  CoE 1 -5
 ElseIf ( CellX == 2 )
  CoE 2 -5
 ElseIf ( CellX == 3 )
  CoE 3 -5
 ElseIf ( CellX == 4 )
  CoE 4 -5
 ElseIf ( CellX == 5 )
  CoE 5 -5
 ElseIf ( CellX == 6 )
  CoE 6 -5
 ElseIf ( CellX == 7 )
  CoE 7 -5
 ElseIf ( CellX == 8 )
  CoE 8 -5
 ElseIf ( CellX == 9 )
  CoE 9 -5
 ElseIf ( CellX == 10 )
  CoE 10 -5
 ElseIf ( CellX == 11 )
  CoE 11 -5
 ElseIf ( CellX == 12 )
  CoE 12 -5
 ElseIf ( CellX == 13 )
  CoE 13 -5
 ElseIf ( CellX == 14 )
  CoE 14 -5
 ElseIf ( CellX == 15 )
  CoE 15 -5
 ElseIf ( CellX == 16 )
  CoE 16 -5
 ElseIf ( CellX == 17 )
  CoE 17 -5
 ElseIf ( CellX == 18 )
  CoE 18 -5
 ElseIf ( CellX == 19 )
  CoE 19 -5
 ElseIf ( CellX == 20 )
  CoE 20 -5
 ElseIf ( CellX == 21 )
  CoE 21 -5
 ElseIf ( CellX == 22 )
  CoE 22 -5
 ElseIf ( CellX == 23 )
  CoE 23 -5
 EndIf
EndIf

; Range (-6,-10) to (-6,23)
If ( CellY == -6 )
 If ( CellX == -10 )
  CoE -10 -6
 ElseIf ( CellX == -9 )
  CoE -9 -6
 ElseIf ( CellX == -8 )
  CoE -8 -6
 ElseIf ( CellX == -7 )
  CoE -7 -6
 ElseIf ( CellX == -6 )
  CoE -6 -6
 ElseIf ( CellX == -5 )
  CoE -5 -6
 ElseIf ( CellX == -4 )
  CoE -4 -6
 ElseIf ( CellX == -3 )
  CoE -3 -6
 ElseIf ( CellX == -2 )
  CoE -2 -6
 ElseIf ( CellX == -1 )
  CoE -1 -6
 ElseIf ( CellX == 0 )
  CoE 0 -6
 ElseIf ( CellX == 1 )
  CoE 1 -6
 ElseIf ( CellX == 2 )
  CoE 2 -6
 ElseIf ( CellX == 3 )
  CoE 3 -6
 ElseIf ( CellX == 4 )
  CoE 4 -6
 ElseIf ( CellX == 5 )
  CoE 5 -6
 ElseIf ( CellX == 6 )
  CoE 6 -6
 ElseIf ( CellX == 7 )
  CoE 7 -6
 ElseIf ( CellX == 8 )
  CoE 8 -6
 ElseIf ( CellX == 9 )
  CoE 9 -6
 ElseIf ( CellX == 10 )
  CoE 10 -6
 ElseIf ( CellX == 11 )
  CoE 11 -6
 ElseIf ( CellX == 12 )
  CoE 12 -6
 ElseIf ( CellX == 13 )
  CoE 13 -6
 ElseIf ( CellX == 14 )
  CoE 14 -6
 ElseIf ( CellX == 15 )
  CoE 15 -6
 ElseIf ( CellX == 16 )
  CoE 16 -6
 ElseIf ( CellX == 17 )
  CoE 17 -6
 ElseIf ( CellX == 18 )
  CoE 18 -6
 ElseIf ( CellX == 19 )
  CoE 19 -6
 ElseIf ( CellX == 20 )
  CoE 20 -6
 ElseIf ( CellX == 21 )
  CoE 21 -6
 ElseIf ( CellX == 22 )
  CoE 22 -6
 ElseIf ( CellX == 23 )
  CoE 23 -6
 EndIf
EndIf

; Range (-7,-10) to (-7,23)
If ( CellY == -7 )
 If ( CellX == -10 )
  CoE -10 -7
 ElseIf ( CellX == -9 )
  CoE -9 -7
 ElseIf ( CellX == -8 )
  CoE -8 -7
 ElseIf ( CellX == -7 )
  CoE -7 -7
 ElseIf ( CellX == -6 )
  CoE -6 -7
 ElseIf ( CellX == -5 )
  CoE -5 -7
 ElseIf ( CellX == -4 )
  CoE -4 -7
 ElseIf ( CellX == -3 )
  CoE -3 -7
 ElseIf ( CellX == -2 )
  CoE -2 -7
 ElseIf ( CellX == -1 )
  CoE -1 -7
 ElseIf ( CellX == 0 )
  CoE 0 -7
 ElseIf ( CellX == 1 )
  CoE 1 -7
 ElseIf ( CellX == 2 )
  CoE 2 -7
 ElseIf ( CellX == 3 )
  CoE 3 -7
 ElseIf ( CellX == 4 )
  CoE 4 -7
 ElseIf ( CellX == 5 )
  CoE 5 -7
 ElseIf ( CellX == 6 )
  CoE 6 -7
 ElseIf ( CellX == 7 )
  CoE 7 -7
 ElseIf ( CellX == 8 )
  CoE 8 -7
 ElseIf ( CellX == 9 )
  CoE 9 -7
 ElseIf ( CellX == 10 )
  CoE 10 -7
 ElseIf ( CellX == 11 )
  CoE 11 -7
 ElseIf ( CellX == 12 )
  CoE 12 -7
 ElseIf ( CellX == 13 )
  CoE 13 -7
 ElseIf ( CellX == 14 )
  CoE 14 -7
 ElseIf ( CellX == 15 )
  CoE 15 -7
 ElseIf ( CellX == 16 )
  CoE 16 -7
 ElseIf ( CellX == 17 )
  CoE 17 -7
 ElseIf ( CellX == 18 )
  CoE 18 -7
 ElseIf ( CellX == 19 )
  CoE 19 -7
 ElseIf ( CellX == 20 )
  CoE 20 -7
 ElseIf ( CellX == 21 )
  CoE 21 -7
 ElseIf ( CellX == 22 )
  CoE 22 -7
 ElseIf ( CellX == 23 )
  CoE 23 -7
 EndIf
EndIf

; Range (-8,-10) to (-8,23)
If ( CellY == -8 )
 If ( CellX == -10 )
  CoE -10 -8
 ElseIf ( CellX == -9 )
  CoE -9 -8
 ElseIf ( CellX == -8 )
  CoE -8 -8
 ElseIf ( CellX == -7 )
  CoE -7 -8
 ElseIf ( CellX == -6 )
  CoE -6 -8
 ElseIf ( CellX == -5 )
  CoE -5 -8
 ElseIf ( CellX == -4 )
  CoE -4 -8
 ElseIf ( CellX == -3 )
  CoE -3 -8
 ElseIf ( CellX == -2 )
  CoE -2 -8
 ElseIf ( CellX == -1 )
  CoE -1 -8
 ElseIf ( CellX == 0 )
  CoE 0 -8
 ElseIf ( CellX == 1 )
  CoE 1 -8
 ElseIf ( CellX == 2 )
  CoE 2 -8
 ElseIf ( CellX == 3 )
  CoE 3 -8
 ElseIf ( CellX == 4 )
  CoE 4 -8
 ElseIf ( CellX == 5 )
  CoE 5 -8
 ElseIf ( CellX == 6 )
  CoE 6 -8
 ElseIf ( CellX == 7 )
  CoE 7 -8
 ElseIf ( CellX == 8 )
  CoE 8 -8
 ElseIf ( CellX == 9 )
  CoE 9 -8
 ElseIf ( CellX == 10 )
  CoE 10 -8
 ElseIf ( CellX == 11 )
  CoE 11 -8
 ElseIf ( CellX == 12 )
  CoE 12 -8
 ElseIf ( CellX == 13 )
  CoE 13 -8
 ElseIf ( CellX == 14 )
  CoE 14 -8
 ElseIf ( CellX == 15 )
  CoE 15 -8
 ElseIf ( CellX == 16 )
  CoE 16 -8
 ElseIf ( CellX == 17 )
  CoE 17 -8
 ElseIf ( CellX == 18 )
  CoE 18 -8
 ElseIf ( CellX == 19 )
  CoE 19 -8
 ElseIf ( CellX == 20 )
  CoE 20 -8
 ElseIf ( CellX == 21 )
  CoE 21 -8
 ElseIf ( CellX == 22 )
  CoE 22 -8
 ElseIf ( CellX == 23 )
  CoE 23 -8
 EndIf
EndIf

; Range (-9,-10) to (-9,23)
If ( CellY == -9 )
 If ( CellX == -10 )
  CoE -10 -9
 ElseIf ( CellX == -9 )
  CoE -9 -9
 ElseIf ( CellX == -8 )
  CoE -8 -9
 ElseIf ( CellX == -7 )
  CoE -7 -9
 ElseIf ( CellX == -6 )
  CoE -6 -9
 ElseIf ( CellX == -5 )
  CoE -5 -9
 ElseIf ( CellX == -4 )
  CoE -4 -9
 ElseIf ( CellX == -3 )
  CoE -3 -9
 ElseIf ( CellX == -2 )
  CoE -2 -9
 ElseIf ( CellX == -1 )
  CoE -1 -9
 ElseIf ( CellX == 0 )
  CoE 0 -9
 ElseIf ( CellX == 1 )
  CoE 1 -9
 ElseIf ( CellX == 2 )
  CoE 2 -9
 ElseIf ( CellX == 3 )
  CoE 3 -9
 ElseIf ( CellX == 4 )
  CoE 4 -9
 ElseIf ( CellX == 5 )
  CoE 5 -9
 ElseIf ( CellX == 6 )
  CoE 6 -9
 ElseIf ( CellX == 7 )
  CoE 7 -9
 ElseIf ( CellX == 8 )
  CoE 8 -9
 ElseIf ( CellX == 9 )
  CoE 9 -9
 ElseIf ( CellX == 10 )
  CoE 10 -9
 ElseIf ( CellX == 11 )
  CoE 11 -9
 ElseIf ( CellX == 12 )
  CoE 12 -9
 ElseIf ( CellX == 13 )
  CoE 13 -9
 ElseIf ( CellX == 14 )
  CoE 14 -9
 ElseIf ( CellX == 15 )
  CoE 15 -9
 ElseIf ( CellX == 16 )
  CoE 16 -9
 ElseIf ( CellX == 17 )
  CoE 17 -9
 ElseIf ( CellX == 18 )
  CoE 18 -9
 ElseIf ( CellX == 19 )
  CoE 19 -9
 ElseIf ( CellX == 20 )
  CoE 20 -9
 ElseIf ( CellX == 21 )
  CoE 21 -9
 ElseIf ( CellX == 22 )
  CoE 22 -9
 ElseIf ( CellX == 23 )
  CoE 23 -9
 EndIf
EndIf

; Range (-10,-9) to (-10,23)
If ( CellY == -10 )
 If ( CellX == -9 )
  CoE -9 -10
 ElseIf ( CellX == -8 )
  CoE -8 -10
 ElseIf ( CellX == -7 )
  CoE -7 -10
 ElseIf ( CellX == -6 )
  CoE -6 -10
 ElseIf ( CellX == -5 )
  CoE -5 -10
 ElseIf ( CellX == -4 )
  CoE -4 -10
 ElseIf ( CellX == -3 )
  CoE -3 -10
 ElseIf ( CellX == -2 )
  CoE -2 -10
 ElseIf ( CellX == -1 )
  CoE -1 -10
 ElseIf ( CellX == 0 )
  CoE 0 -10
 ElseIf ( CellX == 1 )
  CoE 1 -10
 ElseIf ( CellX == 2 )
  CoE 2 -10
 ElseIf ( CellX == 3 )
  CoE 3 -10
 ElseIf ( CellX == 4 )
  CoE 4 -10
 ElseIf ( CellX == 5 )
  CoE 5 -10
 ElseIf ( CellX == 6 )
  CoE 6 -10
 ElseIf ( CellX == 7 )
  CoE 7 -10
 ElseIf ( CellX == 8 )
  CoE 8 -10
 ElseIf ( CellX == 9 )
  CoE 9 -10
 ElseIf ( CellX == 10 )
  CoE 10 -10
 ElseIf ( CellX == 11 )
  CoE 11 -10
 ElseIf ( CellX == 12 )
  CoE 12 -10
 ElseIf ( CellX == 13 )
  CoE 13 -10
 ElseIf ( CellX == 14 )
  CoE 14 -10
 ElseIf ( CellX == 15 )
  CoE 15 -10
 ElseIf ( CellX == 16 )
  CoE 16 -10
 ElseIf ( CellX == 17 )
  CoE 17 -10
 ElseIf ( CellX == 18 )
  CoE 18 -10
 ElseIf ( CellX == 19 )
  CoE 19 -10
 ElseIf ( CellX == 20 )
  CoE 20 -10
 ElseIf ( CellX == 21 )
  CoE 21 -10
 ElseIf ( CellX == 22 )
  CoE 22 -10
 ElseIf ( CellX == 23 )
  CoE 23 -10
 EndIf
EndIf

; Range (-11,-9) to (-11,23)
If ( CellY == -11 )
 If ( CellX == -9 )
  CoE -9 -11
 ElseIf ( CellX == -8 )
  CoE -8 -11
 ElseIf ( CellX == -7 )
  CoE -7 -11
 ElseIf ( CellX == -6 )
  CoE -6 -11
 ElseIf ( CellX == -5 )
  CoE -5 -11
 ElseIf ( CellX == -4 )
  CoE -4 -11
 ElseIf ( CellX == -3 )
  CoE -3 -11
 ElseIf ( CellX == -2 )
  CoE -2 -11
 ElseIf ( CellX == -1 )
  CoE -1 -11
 ElseIf ( CellX == 0 )
  CoE 0 -11
 ElseIf ( CellX == 1 )
  CoE 1 -11
 ElseIf ( CellX == 2 )
  CoE 2 -11
 ElseIf ( CellX == 3 )
  CoE 3 -11
 ElseIf ( CellX == 4 )
  CoE 4 -11
 ElseIf ( CellX == 5 )
  CoE 5 -11
 ElseIf ( CellX == 6 )
  CoE 6 -11
 ElseIf ( CellX == 7 )
  CoE 7 -11
 ElseIf ( CellX == 8 )
  CoE 8 -11
 ElseIf ( CellX == 9 )
  CoE 9 -11
 ElseIf ( CellX == 10 )
  CoE 10 -11
 ElseIf ( CellX == 11 )
  CoE 11 -11
 ElseIf ( CellX == 12 )
  CoE 12 -11
 ElseIf ( CellX == 13 )
  CoE 13 -11
 ElseIf ( CellX == 14 )
  CoE 14 -11
 ElseIf ( CellX == 15 )
  CoE 15 -11
 ElseIf ( CellX == 16 )
  CoE 16 -11
 ElseIf ( CellX == 17 )
  CoE 17 -11
 ElseIf ( CellX == 18 )
  CoE 18 -11
 ElseIf ( CellX == 19 )
  CoE 19 -11
 ElseIf ( CellX == 20 )
  CoE 20 -11
 ElseIf ( CellX == 21 )
  CoE 21 -11
 ElseIf ( CellX == 22 )
  CoE 22 -11
 ElseIf ( CellX == 23 )
  CoE 23 -11
 EndIf
EndIf

; Range (-12,-9) to (-12,23)
If ( CellY == -12 )
 If ( CellX == -9 )
  CoE -9 -12
 ElseIf ( CellX == -8 )
  CoE -8 -12
 ElseIf ( CellX == -7 )
  CoE -7 -12
 ElseIf ( CellX == -6 )
  CoE -6 -12
 ElseIf ( CellX == -5 )
  CoE -5 -12
 ElseIf ( CellX == -4 )
  CoE -4 -12
 ElseIf ( CellX == -3 )
  CoE -3 -12
 ElseIf ( CellX == -2 )
  CoE -2 -12
 ElseIf ( CellX == -1 )
  CoE -1 -12
 ElseIf ( CellX == 0 )
  CoE 0 -12
 ElseIf ( CellX == 1 )
  CoE 1 -12
 ElseIf ( CellX == 2 )
  CoE 2 -12
 ElseIf ( CellX == 3 )
  CoE 3 -12
 ElseIf ( CellX == 4 )
  CoE 4 -12
 ElseIf ( CellX == 5 )
  CoE 5 -12
 ElseIf ( CellX == 6 )
  CoE 6 -12
 ElseIf ( CellX == 7 )
  CoE 7 -12
 ElseIf ( CellX == 8 )
  CoE 8 -12
 ElseIf ( CellX == 9 )
  CoE 9 -12
 ElseIf ( CellX == 10 )
  CoE 10 -12
 ElseIf ( CellX == 11 )
  CoE 11 -12
 ElseIf ( CellX == 12 )
  CoE 12 -12
 ElseIf ( CellX == 13 )
  CoE 13 -12
 ElseIf ( CellX == 14 )
  CoE 14 -12
 ElseIf ( CellX == 15 )
  CoE 15 -12
 ElseIf ( CellX == 16 )
  CoE 16 -12
 ElseIf ( CellX == 17 )
  CoE 17 -12
 ElseIf ( CellX == 18 )
  CoE 18 -12
 ElseIf ( CellX == 19 )
  CoE 19 -12
 ElseIf ( CellX == 20 )
  CoE 20 -12
 ElseIf ( CellX == 21 )
  CoE 21 -12
 ElseIf ( CellX == 22 )
  CoE 22 -12
 ElseIf ( CellX == 23 )
  CoE 23 -12
 EndIf
EndIf

; Range (-13,-9) to (-13,18)
If ( CellY == -13 )
 If ( CellX == -9 )
  CoE -9 -13
 ElseIf ( CellX == -8 )
  CoE -8 -13
 ElseIf ( CellX == -7 )
  CoE -7 -13
 ElseIf ( CellX == -6 )
  CoE -6 -13
 ElseIf ( CellX == -5 )
  CoE -5 -13
 ElseIf ( CellX == -4 )
  CoE -4 -13
 ElseIf ( CellX == -3 )
  CoE -3 -13
 ElseIf ( CellX == -2 )
  CoE -2 -13
 ElseIf ( CellX == -1 )
  CoE -1 -13
 ElseIf ( CellX == 0 )
  CoE 0 -13
 ElseIf ( CellX == 1 )
  CoE 1 -13
 ElseIf ( CellX == 2 )
  CoE 2 -13
 ElseIf ( CellX == 3 )
  CoE 3 -13
 ElseIf ( CellX == 4 )
  CoE 4 -13
 ElseIf ( CellX == 5 )
  CoE 5 -13
 ElseIf ( CellX == 6 )
  CoE 6 -13
 ElseIf ( CellX == 7 )
  CoE 7 -13
 ElseIf ( CellX == 8 )
  CoE 8 -13
 ElseIf ( CellX == 9 )
  CoE 9 -13
 ElseIf ( CellX == 10 )
  CoE 10 -13
 ElseIf ( CellX == 11 )
  CoE 11 -13
 ElseIf ( CellX == 12 )
  CoE 12 -13
 ElseIf ( CellX == 13 )
  CoE 13 -13
 ElseIf ( CellX == 14 )
  CoE 14 -13
 ElseIf ( CellX == 15 )
  CoE 15 -13
 ElseIf ( CellX == 16 )
  CoE 16 -13
 ElseIf ( CellX == 17 )
  CoE 17 -13
 ElseIf ( CellX == 18 )
  CoE 18 -13
 EndIf
EndIf

; Range (-14,-9) to (-14,18)
If ( CellY == -14 )
 If ( CellX == -9 )
  CoE -9 -14
 ElseIf ( CellX == -8 )
  CoE -8 -14
 ElseIf ( CellX == -7 )
  CoE -7 -14
 ElseIf ( CellX == -6 )
  CoE -6 -14
 ElseIf ( CellX == -5 )
  CoE -5 -14
 ElseIf ( CellX == -4 )
  CoE -4 -14
 ElseIf ( CellX == -3 )
  CoE -3 -14
 ElseIf ( CellX == -2 )
  CoE -2 -14
 ElseIf ( CellX == -1 )
  CoE -1 -14
 ElseIf ( CellX == 0 )
  CoE 0 -14
 ElseIf ( CellX == 1 )
  CoE 1 -14
 ElseIf ( CellX == 2 )
  CoE 2 -14
 ElseIf ( CellX == 3 )
  CoE 3 -14
 ElseIf ( CellX == 4 )
  CoE 4 -14
 ElseIf ( CellX == 5 )
  CoE 5 -14
 ElseIf ( CellX == 6 )
  CoE 6 -14
 ElseIf ( CellX == 7 )
  CoE 7 -14
 ElseIf ( CellX == 8 )
  CoE 8 -14
 ElseIf ( CellX == 9 )
  CoE 9 -14
 ElseIf ( CellX == 10 )
  CoE 10 -14
 ElseIf ( CellX == 11 )
  CoE 11 -14
 ElseIf ( CellX == 12 )
  CoE 12 -14
 ElseIf ( CellX == 13 )
  CoE 13 -14
 ElseIf ( CellX == 14 )
  CoE 14 -14
 ElseIf ( CellX == 15 )
  CoE 15 -14
 ElseIf ( CellX == 16 )
  CoE 16 -14
 ElseIf ( CellX == 17 )
  CoE 17 -14
 ElseIf ( CellX == 18 )
  CoE 18 -14
 EndIf
EndIf

; Range (-15,-2) to (-15,18)
If ( CellY == -15 )
 If ( CellX == -2 )
  CoE -2 -15
 ElseIf ( CellX == -1 )
  CoE -1 -15
 ElseIf ( CellX == 0 )
  CoE 0 -15
 ElseIf ( CellX == 1 )
  CoE 1 -15
 ElseIf ( CellX == 2 )
  CoE 2 -15
 ElseIf ( CellX == 3 )
  CoE 3 -15
 ElseIf ( CellX == 4 )
  CoE 4 -15
 ElseIf ( CellX == 5 )
  CoE 5 -15
 ElseIf ( CellX == 6 )
  CoE 6 -15
 ElseIf ( CellX == 7 )
  CoE 7 -15
 ElseIf ( CellX == 8 )
  CoE 8 -15
 ElseIf ( CellX == 9 )
  CoE 9 -15
 ElseIf ( CellX == 10 )
  CoE 10 -15
 ElseIf ( CellX == 11 )
  CoE 11 -15
 ElseIf ( CellX == 12 )
  CoE 12 -15
 ElseIf ( CellX == 13 )
  CoE 13 -15
 ElseIf ( CellX == 14 )
  CoE 14 -15
 ElseIf ( CellX == 15 )
  CoE 15 -15
 ElseIf ( CellX == 16 )
  CoE 16 -15
 ElseIf ( CellX == 17 )
  CoE 17 -15
 ElseIf ( CellX == 18 )
  CoE 18 -15
 EndIf
EndIf

; Range (-16,-1) to (-16,18)
If ( CellY == -16 )
 If ( CellX == -1 )
  CoE -1 -16
 ElseIf ( CellX == 0 )
  CoE 0 -16
 ElseIf ( CellX == 1 )
  CoE 1 -16
 ElseIf ( CellX == 2 )
  CoE 2 -16
 ElseIf ( CellX == 3 )
  CoE 3 -16
 ElseIf ( CellX == 4 )
  CoE 4 -16
 ElseIf ( CellX == 5 )
  CoE 5 -16
 ElseIf ( CellX == 6 )
  CoE 6 -16
 ElseIf ( CellX == 7 )
  CoE 7 -16
 ElseIf ( CellX == 8 )
  CoE 8 -16
 ElseIf ( CellX == 9 )
  CoE 9 -16
 ElseIf ( CellX == 10 )
  CoE 10 -16
 ElseIf ( CellX == 11 )
  CoE 11 -16
 ElseIf ( CellX == 12 )
  CoE 12 -16
 ElseIf ( CellX == 13 )
  CoE 13 -16
 ElseIf ( CellX == 14 )
  CoE 14 -16
 ElseIf ( CellX == 15 )
  CoE 15 -16
 ElseIf ( CellX == 16 )
  CoE 16 -16
 ElseIf ( CellX == 17 )
  CoE 17 -16
 ElseIf ( CellX == 18 )
  CoE 18 -16
 EndIf
EndIf

; Range (-17,-1) to (-17,16)
If ( CellY == -17 )
 If ( CellX == -1 )
  CoE -1 -17
 ElseIf ( CellX == 0 )
  CoE 0 -17
 ElseIf ( CellX == 1 )
  CoE 1 -17
 ElseIf ( CellX == 2 )
  CoE 2 -17
 ElseIf ( CellX == 3 )
  CoE 3 -17
 ElseIf ( CellX == 4 )
  CoE 4 -17
 ElseIf ( CellX == 5 )
  CoE 5 -17
 ElseIf ( CellX == 6 )
  CoE 6 -17
 ElseIf ( CellX == 7 )
  CoE 7 -17
 ElseIf ( CellX == 8 )
  CoE 8 -17
 ElseIf ( CellX == 9 )
  CoE 9 -17
 ElseIf ( CellX == 10 )
  CoE 10 -17
 ElseIf ( CellX == 11 )
  CoE 11 -17
 ElseIf ( CellX == 12 )
  CoE 12 -17
 ElseIf ( CellX == 13 )
  CoE 13 -17
 ElseIf ( CellX == 14 )
  CoE 14 -17
 ElseIf ( CellX == 15 )
  CoE 15 -17
 ElseIf ( CellX == 16 )
  CoE 16 -17
 EndIf
EndIf

; Range (-18,6) to (-18,11)
If ( CellY == -18 )
 If ( CellX == 6 )
  CoE 6 -18
 ElseIf ( CellX == 7 )
  CoE 7 -18
 ElseIf ( CellX == 8 )
  CoE 8 -18
 ElseIf ( CellX == 9 )
  CoE 9 -18
 ElseIf ( CellX == 10 )
  CoE 10 -18
 ElseIf ( CellX == 11 )
  CoE 11 -18
 EndIf
EndIf

; Range (-19,7) to (-19,8)
If ( CellY == -19 )
 If ( CellX == 7 )
  CoE 7 -19
 ElseIf ( CellX == 8 )
  CoE 8 -19
 EndIf
EndIf

; standard script: stop it
StopScript "A1_DAT_SRT_CoE_V_Lo"

End