<xml xmlns="https://developers.google.com/blockly/xml">
  <variables>
    <variable id="E(h`4-x5Mwx-k3@T)_)|">Current position</variable>
    <variable id="T)Eyr1bZPcLT43#u^,a^">Rotation angle</variable>
    <variable id="w$lo3SfsIR`j.-kU`!h(">Distance to travel</variable>
    <variable id="gh@OGf3]!@0=kMKAYX7i">Target position</variable>
  </variables>
  <block type="variables_set" id="0;vlJzG8|iQX5^T0=|a_" x="192" y="62">
    <field name="VAR" id="E(h`4-x5Mwx-k3@T)_)|">Current position</field>
    <value name="VALUE">
      <block type="lists_create_with" id="Kd[@o=^w3Ug8Ql,yh7j6">
        <mutation items="3"></mutation>
        <comment pinned="false" h="80" w="160">List contains coordinates (x in cm, y in cm and Rotation along z axis in deg)</comment>
        <value name="ADD0">
          <block type="math_number" id="8qlREBG$Bg{}vN;M`#;K">
            <field name="NUM">0</field>
          </block>
        </value>
        <value name="ADD1">
          <block type="math_number" id="1n@oZ5;7h|MQp3ZtWixN">
            <field name="NUM">0</field>
          </block>
        </value>
        <value name="ADD2">
          <block type="math_number" id="I=z@.vWr/m#oo6,aty{Z">
            <field name="NUM">0</field>
          </block>
        </value>
      </block>
    </value>
    <next>
      <block type="variables_set" id="!]nyl_?S7%eDQI!KA8y%">
        <field name="VAR" id="E(h`4-x5Mwx-k3@T)_)|">Current position</field>
        <value name="VALUE">
          <block type="lists_create_with" id="wG_`%uD}fV?R`wn{H,xX">
            <mutation items="3"></mutation>
            <value name="ADD0">
              <block type="math_number" id="58S%5Ei*4`$9+|W9(8/G">
                <field name="NUM">15</field>
              </block>
            </value>
            <value name="ADD1">
              <block type="math_number" id="rlmXX/=S8+UBEXYGJ-NV">
                <field name="NUM">15</field>
              </block>
            </value>
            <value name="ADD2">
              <block type="math_number" id="WJ*dGM$z2n8;4r{~pDam">
                <field name="NUM">20</field>
              </block>
            </value>
          </block>
        </value>
        <next>
          <block type="variables_set" id="2.K2Pcn6C9%#F*SS0`*H">
            <field name="VAR" id="T)Eyr1bZPcLT43#u^,a^">Rotation angle</field>
            <value name="VALUE">
              <block type="math_atan2" id="Kn,yL;?G:|?tDrP?wc4!">
                <value name="X">
                  <shadow type="math_number" id="oi_1wkDMZH1Zn_Y5rEO_">
                    <field name="NUM">1</field>
                  </shadow>
                  <block type="lists_getIndex" id="21Ybq3(;-M!]-0ef!~g2">
                    <mutation statement="false" at="true"></mutation>
                    <field name="MODE">GET</field>
                    <field name="WHERE">FROM_START</field>
                    <value name="VALUE">
                      <block type="variables_get" id="3JSshZv!,!Fm%CXyj$!X">
                        <field name="VAR" id="gh@OGf3]!@0=kMKAYX7i">Target position</field>
                      </block>
                    </value>
                    <value name="AT">
                      <block type="math_number" id="(fL[]E3%q@`FMCvsUZGb">
                        <field name="NUM">1</field>
                      </block>
                    </value>
                  </block>
                </value>
                <value name="Y">
                  <shadow type="math_number" id="Mw8KzQqW:UJN(7!`+V52">
                    <field name="NUM">1</field>
                  </shadow>
                  <block type="lists_getIndex" id="lq:{y:fq:N)Vlq:[y#_I">
                    <mutation statement="false" at="true"></mutation>
                    <field name="MODE">GET</field>
                    <field name="WHERE">FROM_START</field>
                    <value name="VALUE">
                      <block type="variables_get" id="iueH`Lu[LtwQDHTRr;sc">
                        <field name="VAR" id="gh@OGf3]!@0=kMKAYX7i">Target position</field>
                      </block>
                    </value>
                    <value name="AT">
                      <block type="math_number" id="^Xamt?o{c=hD8:`$3nj`">
                        <field name="NUM">2</field>
                      </block>
                    </value>
                  </block>
                </value>
              </block>
            </value>
            <next>
              <block type="variables_set" id="#B9t:k,s_JtyRK]-:@kZ">
                <field name="VAR" id="w$lo3SfsIR`j.-kU`!h(">Distance to travel</field>
                <value name="VALUE">
                  <block type="math_single" id="06!Way[xh=nWcS`PCnY9">
                    <field name="OP">ROOT</field>
                    <value name="NUM">
                      <shadow type="math_number" id="mgOJmSc..I?RAA6_KA7U">
                        <field name="NUM">9</field>
                      </shadow>
                      <block type="math_arithmetic" id="n@ER/a4f6W]8epf)sy_B">
                        <field name="OP">ADD</field>
                        <value name="A">
                          <shadow type="math_number" id="}].2bf@j}-0?VUq6Xq7j">
                            <field name="NUM">1</field>
                          </shadow>
                          <block type="math_arithmetic" id="i/.k#l@O*I;zneKUGz.J">
                            <field name="OP">POWER</field>
                            <value name="A">
                              <shadow type="math_number" id="[CAt,eRQTY-47-f7$k@X">
                                <field name="NUM">1</field>
                              </shadow>
                              <block type="lists_getIndex" id="2yTy)S1Cm-g9EtU[%7#v">
                                <mutation statement="false" at="true"></mutation>
                                <field name="MODE">GET</field>
                                <field name="WHERE">FROM_START</field>
                                <value name="VALUE">
                                  <block type="variables_get" id="H{#4r,dbCjk#`jc1Q8N.">
                                    <field name="VAR" id="gh@OGf3]!@0=kMKAYX7i">Target position</field>
                                  </block>
                                </value>
                                <value name="AT">
                                  <block type="math_number" id="dz9_U]j%o)O.;~I{`TIJ">
                                    <field name="NUM">1</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                            <value name="B">
                              <shadow type="math_number" id="WgH#[E2x!/R1h;k!3MSe">
                                <field name="NUM">2</field>
                              </shadow>
                            </value>
                          </block>
                        </value>
                        <value name="B">
                          <shadow type="math_number" id="Y5z9[n_P=~3Z1qE,g%=m">
                            <field name="NUM">1</field>
                          </shadow>
                          <block type="math_arithmetic" id="V-@hwxdq8B-VG8`MJ1`?">
                            <field name="OP">POWER</field>
                            <value name="A">
                              <shadow type="math_number">
                                <field name="NUM">1</field>
                              </shadow>
                              <block type="lists_getIndex" id="{`m00$JO:6Z]nkrt1%{q">
                                <mutation statement="false" at="true"></mutation>
                                <field name="MODE">GET</field>
                                <field name="WHERE">FROM_START</field>
                                <value name="VALUE">
                                  <block type="variables_get" id="3!46dCMT;9Hg+Fuz[SoH">
                                    <field name="VAR" id="gh@OGf3]!@0=kMKAYX7i">Target position</field>
                                  </block>
                                </value>
                                <value name="AT">
                                  <block type="math_number" id="gR#@B(Hav/0xc1~O;:#5">
                                    <field name="NUM">2</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                            <value name="B">
                              <shadow type="math_number" id="LuY;5nAWD;WL_?huR~fS">
                                <field name="NUM">2</field>
                              </shadow>
                            </value>
                          </block>
                        </value>
                      </block>
                    </value>
                  </block>
                </value>
                <next>
                  <block type="rotate_degrees_angle" id="!$k%$+1GDb-0[zkuw]+I">
                    <field name="angle">0</field>
                    <next>
                      <block type="move_forward_distance" id="11S5!hur,JOBzM$({Jbr">
                        <field name="number_of_steps">0</field>
                        <next>
                          <block type="controls_if" id="6^$E0;XQcn}wb)2h1e2K">
                            <mutation else="1"></mutation>
                            <value name="IF0">
                              <block type="logic_compare" id=".?E18h-~oR{y^94.FA/|">
                                <field name="OP">GT</field>
                                <value name="A">
                                  <block type="math_arithmetic" id="@:9ys0fU`ol=:D`*64dc">
                                    <field name="OP">MINUS</field>
                                    <value name="A">
                                      <shadow type="math_number" id="EM|dnp*$x%HeOnoMWD^j">
                                        <field name="NUM">1</field>
                                      </shadow>
                                      <block type="lists_getIndex" id="i])T32G0^N]1%(;PR^L)">
                                        <mutation statement="false" at="true"></mutation>
                                        <field name="MODE">GET</field>
                                        <field name="WHERE">FROM_START</field>
                                        <value name="VALUE">
                                          <block type="variables_get" id="kIG3}KT.l-;VGb)==54A">
                                            <field name="VAR" id="gh@OGf3]!@0=kMKAYX7i">Target position</field>
                                          </block>
                                        </value>
                                        <value name="AT">
                                          <block type="math_number" id="62WgqI]}@ws3(m%wIv(L">
                                            <field name="NUM">3</field>
                                          </block>
                                        </value>
                                      </block>
                                    </value>
                                    <value name="B">
                                      <shadow type="math_number" id=",g4b1tVuSQ331F5;z?~]">
                                        <field name="NUM">1</field>
                                      </shadow>
                                      <block type="variables_get" id="9m3gh5y3}af_3iqmAc3)">
                                        <field name="VAR" id="T)Eyr1bZPcLT43#u^,a^">Rotation angle</field>
                                      </block>
                                    </value>
                                  </block>
                                </value>
                                <value name="B">
                                  <block type="math_number" id="y0Acm3QXF{:xPOiCc!%@">
                                    <field name="NUM">0</field>
                                  </block>
                                </value>
                              </block>
                            </value>
                            <statement name="DO0">
                              <block type="rotate_degrees_angle" id="Np?gRV]}8eE~|{RSP:c9">
                                <field name="angle">0</field>
                              </block>
                            </statement>
                            <statement name="ELSE">
                              <block type="rotate_degrees_angle" id="0WIuTo5VI=H4o;oy=(k;">
                                <field name="angle">0</field>
                              </block>
                            </statement>
                          </block>
                        </next>
                      </block>
                    </next>
                  </block>
                </next>
              </block>
            </next>
          </block>
        </next>
      </block>
    </next>
  </block>
  <block type="variables_get" id="F)L}s:I72;jVmh$;n|%D" x="349" y="320">
    <field name="VAR" id="T)Eyr1bZPcLT43#u^,a^">Rotation angle</field>
  </block>
  <block type="variables_get" id="_Y55CuG/bRU8uX*-!k^8" x="380" y="350">
    <field name="VAR" id="w$lo3SfsIR`j.-kU`!h(">Distance to travel</field>
  </block>
  <block type="math_arithmetic" id="d}1CMPA|EZF4r9x.9jBL" x="372" y="427">
    <field name="OP">MINUS</field>
    <value name="A">
      <shadow type="math_number" id="9JYcW+Y5#rX2D_6E0~TC">
        <field name="NUM">1</field>
      </shadow>
    </value>
    <value name="B">
      <shadow type="math_number" id="1~mq)[smZqs4x}GBa%f3">
        <field name="NUM">1</field>
      </shadow>
      <block type="lists_getIndex" id="v@3TLYk3[Y/Kje_2bK#s">
        <mutation statement="false" at="true"></mutation>
        <field name="MODE">GET</field>
        <field name="WHERE">FROM_START</field>
        <value name="VALUE">
          <block type="variables_get" id="ja)Sf%D~6D1=avl.Gh~p">
            <field name="VAR" id="gh@OGf3]!@0=kMKAYX7i">Target position</field>
          </block>
        </value>
        <value name="AT">
          <block type="math_number" id="c9j)RLGKtrO:zq(hk~$W">
            <field name="NUM">3</field>
          </block>
        </value>
      </block>
    </value>
  </block>
  <block type="math_arithmetic" id="6`5a5wh}J7r15+(DbpB:" x="367" y="486">
    <field name="OP">ADD</field>
    <value name="A">
      <shadow type="math_number">
        <field name="NUM">1</field>
      </shadow>
      <block type="lists_getIndex" id="H_9kfU,pk(UN^(fL6)Zy">
        <mutation statement="false" at="true"></mutation>
        <field name="MODE">GET</field>
        <field name="WHERE">FROM_START</field>
        <value name="VALUE">
          <block type="variables_get" id="WW)0*fT9(o{M1sGr@+0?">
            <field name="VAR" id="gh@OGf3]!@0=kMKAYX7i">Target position</field>
          </block>
        </value>
        <value name="AT">
          <block type="math_number" id="Lxu(O~!+e3i~(G%ftd2t">
            <field name="NUM">3</field>
          </block>
        </value>
      </block>
    </value>
    <value name="B">
      <shadow type="math_number">
        <field name="NUM">1</field>
      </shadow>
      <block type="variables_get" id="V0ceJX_5cn}}abDg(by]">
        <field name="VAR" id="T)Eyr1bZPcLT43#u^,a^">Rotation angle</field>
      </block>
    </value>
  </block>
  <project>
    <title>From relative to absolute</title>
    <description>Learning to navigate using absolute positions</description>
  </project>
</xml>