<?xml version="1.0" encoding="utf-8"?>
<feed xmlns="http://www.w3.org/2005/Atom">
  <title>VeeLang news</title>
  <link href="https://veelang.org/blog/" />
  <link rel="self" href="https://veelang.org/blog/feed.xml" />
  <id>https://veelang.org/blog/</id>
  <updated>2026-10-11T00:00:00Z</updated>
  <entry>
    <title>Click to make things happen! 👆</title>
    <link href="https://veelang.org/blog/click-to-make-things-happen/" />
    <id>https://veelang.org/blog/click-to-make-things-happen/</id>
    <updated>2026-10-11T00:00:00Z</updated>
    <author><name>Suhas Chatekar</name></author>
    <summary>Drawings that listen: do something when a shape is clicked, remember things in variables, and make choices with if. Then make a game.</summary>
    <content type="html">&lt;p&gt;Your drawings can do something when you &lt;strong&gt;click&lt;/strong&gt; them. Write &lt;code&gt;when&lt;/code&gt;, the shape&amp;#39;s name and &lt;code&gt;is clicked&lt;/code&gt;, and put what should happen inside &lt;code&gt;{ }&lt;/code&gt;:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 250
draw circle balloon at 200, 125 having radius 40, fill &amp;quot;tomato&amp;quot;
when balloon is clicked {
  grow balloon by 1.5 in 0.5 seconds
  shrink balloon by 1.5 in 0.5 seconds
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 250&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;250&quot; fill=&quot;white&quot; /&gt;
  &lt;circle cx=&quot;200&quot; cy=&quot;125&quot; r=&quot;40&quot; fill=&quot;tomato&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; cursor=&quot;pointer&quot; pointer-events=&quot;visible&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNTAKZHJhdyBjaXJjbGUgYmFsbG9vbiBhdCAyMDAsIDEyNSBoYXZpbmcgcmFkaXVzIDQwLCBmaWxsICJ0b21hdG8iCndoZW4gYmFsbG9vbiBpcyBjbGlja2VkIHsKICBncm93IGJhbGxvb24gYnkgMS41IGluIDAuNSBzZWNvbmRzCiAgc2hyaW5rIGJhbGxvb24gYnkgMS41IGluIDAuNSBzZWNvbmRzCn0&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;Click the balloon. Click it again! It happens every time.&lt;/p&gt;
&lt;h2&gt;Remembering things 🧠&lt;/h2&gt;
&lt;p&gt;A &lt;strong&gt;variable&lt;/strong&gt; is a name that holds a value, like a number. Give it a value with &lt;code&gt;=&lt;/code&gt;, and change it later. Here &lt;code&gt;pops&lt;/code&gt; counts the clicks:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 250
draw circle balloon at 200, 125 having radius 30, fill &amp;quot;tomato&amp;quot;
pops = 0
when balloon is clicked {
  pops = pops + 1
  grow balloon by 1.2 in 0.3 seconds
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 250&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;250&quot; fill=&quot;white&quot; /&gt;
  &lt;circle cx=&quot;200&quot; cy=&quot;125&quot; r=&quot;30&quot; fill=&quot;tomato&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; cursor=&quot;pointer&quot; pointer-events=&quot;visible&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNTAKZHJhdyBjaXJjbGUgYmFsbG9vbiBhdCAyMDAsIDEyNSBoYXZpbmcgcmFkaXVzIDMwLCBmaWxsICJ0b21hdG8iCnBvcHMgPSAwCndoZW4gYmFsbG9vbiBpcyBjbGlja2VkIHsKICBwb3BzID0gcG9wcyArIDEKICBncm93IGJhbGxvb24gYnkgMS4yIGluIDAuMyBzZWNvbmRzCn0&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;h2&gt;Making choices 🔀&lt;/h2&gt;
&lt;p&gt;&lt;code&gt;if&lt;/code&gt; checks something, and does its lines only when it&amp;#39;s true. &lt;code&gt;otherwise&lt;/code&gt; says what to do when it isn&amp;#39;t:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 250
draw circle lamp at 200, 125 having radius 40, fill &amp;quot;gray&amp;quot;
lit = false
when lamp is clicked {
  lit = not lit
  if lit {
    lamp.fill = &amp;quot;gold&amp;quot;
  }
  otherwise {
    lamp.fill = &amp;quot;gray&amp;quot;
  }
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 250&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;250&quot; fill=&quot;white&quot; /&gt;
  &lt;circle cx=&quot;200&quot; cy=&quot;125&quot; r=&quot;40&quot; fill=&quot;gray&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; cursor=&quot;pointer&quot; pointer-events=&quot;visible&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNTAKZHJhdyBjaXJjbGUgbGFtcCBhdCAyMDAsIDEyNSBoYXZpbmcgcmFkaXVzIDQwLCBmaWxsICJncmF5IgpsaXQgPSBmYWxzZQp3aGVuIGxhbXAgaXMgY2xpY2tlZCB7CiAgbGl0ID0gbm90IGxpdAogIGlmIGxpdCB7CiAgICBsYW1wLmZpbGwgPSAiZ29sZCIKICB9CiAgb3RoZXJ3aXNlIHsKICAgIGxhbXAuZmlsbCA9ICJncmF5IgogIH0KfQ&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;Click the lamp to switch it on, and again to switch it off. 💡&lt;/p&gt;
&lt;h2&gt;Make a game 🦫&lt;/h2&gt;
&lt;p&gt;Put it all together, and you can make a game. Moles take turns popping up. Catch one by clicking it: it smiles, and you get a star. Catch five to win!&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas garden having width 400, length 300, fill &amp;quot;lightgreen&amp;quot;
shape mole having mood &amp;quot;hiding&amp;quot; {
  circle body having radius 20, fill &amp;quot;sienna&amp;quot;
  circle eye1 at -7, -5 having radius 3, fill &amp;quot;black&amp;quot;
  circle eye2 at 7, -5 having radius 3, fill &amp;quot;black&amp;quot;
  when mood is &amp;quot;hiding&amp;quot; { }
  when mood is &amp;quot;caught&amp;quot; {
    arc smile from 8, 6 to -8, 6 having radius 10
  }
}
caught = 0
draw mole m1 at 100, 150
draw mole m2 at 200, 150
draw mole m3 at 300, 150
draw text message at 200, 40 having content &amp;quot;Catch the moles!&amp;quot;
hide m2
hide m3
forever {
  hide m1
  show m2
  wait 1 second
  hide m2
  show m3
  wait 1 second
  hide m3
  show m1
  wait 1 second
}
when m1 is clicked {
  caught = caught + 1
  m1.mood = &amp;quot;caught&amp;quot;
  draw circle star at 20 * caught, 280 having radius 6, fill &amp;quot;gold&amp;quot;
  if caught is at least 5 {
    message.content = &amp;quot;You win!&amp;quot;
  }
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 300&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;300&quot; fill=&quot;lightgreen&quot; /&gt;
  &lt;g opacity=&quot;0&quot; cursor=&quot;pointer&quot; pointer-events=&quot;none&quot;&gt;
  &lt;circle cx=&quot;100&quot; cy=&quot;150&quot; r=&quot;20&quot; fill=&quot;sienna&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;93&quot; cy=&quot;145&quot; r=&quot;3&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;107&quot; cy=&quot;145&quot; r=&quot;3&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;/g&gt;
  &lt;g&gt;
  &lt;circle cx=&quot;200&quot; cy=&quot;150&quot; r=&quot;20&quot; fill=&quot;sienna&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;193&quot; cy=&quot;145&quot; r=&quot;3&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;207&quot; cy=&quot;145&quot; r=&quot;3&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;/g&gt;
  &lt;g opacity=&quot;0&quot; pointer-events=&quot;none&quot;&gt;
  &lt;circle cx=&quot;300&quot; cy=&quot;150&quot; r=&quot;20&quot; fill=&quot;sienna&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;293&quot; cy=&quot;145&quot; r=&quot;3&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;307&quot; cy=&quot;145&quot; r=&quot;3&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;/g&gt;
  &lt;text x=&quot;200&quot; y=&quot;40&quot; font-family=&quot;sans-serif&quot; font-size=&quot;16&quot; fill=&quot;black&quot;&gt;Catch the moles!&lt;/text&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIGdhcmRlbiBoYXZpbmcgd2lkdGggNDAwLCBsZW5ndGggMzAwLCBmaWxsICJsaWdodGdyZWVuIgpzaGFwZSBtb2xlIGhhdmluZyBtb29kICJoaWRpbmciIHsKICBjaXJjbGUgYm9keSBoYXZpbmcgcmFkaXVzIDIwLCBmaWxsICJzaWVubmEiCiAgY2lyY2xlIGV5ZTEgYXQgLTcsIC01IGhhdmluZyByYWRpdXMgMywgZmlsbCAiYmxhY2siCiAgY2lyY2xlIGV5ZTIgYXQgNywgLTUgaGF2aW5nIHJhZGl1cyAzLCBmaWxsICJibGFjayIKICB3aGVuIG1vb2QgaXMgImhpZGluZyIgeyB9CiAgd2hlbiBtb29kIGlzICJjYXVnaHQiIHsKICAgIGFyYyBzbWlsZSBmcm9tIDgsIDYgdG8gLTgsIDYgaGF2aW5nIHJhZGl1cyAxMAogIH0KfQpjYXVnaHQgPSAwCmRyYXcgbW9sZSBtMSBhdCAxMDAsIDE1MApkcmF3IG1vbGUgbTIgYXQgMjAwLCAxNTAKZHJhdyBtb2xlIG0zIGF0IDMwMCwgMTUwCmRyYXcgdGV4dCBtZXNzYWdlIGF0IDIwMCwgNDAgaGF2aW5nIGNvbnRlbnQgIkNhdGNoIHRoZSBtb2xlcyEiCmhpZGUgbTIKaGlkZSBtMwpmb3JldmVyIHsKICBoaWRlIG0xCiAgc2hvdyBtMgogIHdhaXQgMSBzZWNvbmQKICBoaWRlIG0yCiAgc2hvdyBtMwogIHdhaXQgMSBzZWNvbmQKICBoaWRlIG0zCiAgc2hvdyBtMQogIHdhaXQgMSBzZWNvbmQKfQp3aGVuIG0xIGlzIGNsaWNrZWQgewogIGNhdWdodCA9IGNhdWdodCArIDEKICBtMS5tb29kID0gImNhdWdodCIKICBkcmF3IGNpcmNsZSBzdGFyIGF0IDIwICogY2F1Z2h0LCAyODAgaGF2aW5nIHJhZGl1cyA2LCBmaWxsICJnb2xkIgogIGlmIGNhdWdodCBpcyBhdCBsZWFzdCA1IHsKICAgIG1lc3NhZ2UuY29udGVudCA9ICJZb3Ugd2luISIKICB9Cn0&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;Only the first mole can be caught so far. Can you make the other two catchable? 🌟&lt;/p&gt;
&lt;p&gt;Learn more in &lt;a href=&quot;https://learn.veelang.org/tutorials/18-clicking/&quot;&gt;Click to Make Things Happen&lt;/a&gt; and &lt;a href=&quot;https://learn.veelang.org/tutorials/19-remembering-things/&quot;&gt;Remembering Things&lt;/a&gt;. Have fun! ✨&lt;/p&gt;
</content>
  </entry>
  <entry>
    <title>Recipes that change, and keep to themselves 🍪</title>
    <link href="https://veelang.org/blog/recipes-that-change/" />
    <id>https://veelang.org/blog/recipes-that-change/</id>
    <updated>2026-10-10T00:00:00Z</updated>
    <author><name>Suhas Chatekar</name></author>
    <summary>Shapes made from recipes can change their settings while things move, and follow other shapes. And two new rules make recipes easier to share.</summary>
    <content type="html">&lt;p&gt;A &lt;strong&gt;recipe&lt;/strong&gt; describes a kind of shape: a face, a house, a tree. Each &lt;code&gt;draw&lt;/code&gt; makes a new one, with its own &lt;strong&gt;settings&lt;/strong&gt;.&lt;/p&gt;
&lt;p&gt;Now a recipe&amp;#39;s shape can change its settings &lt;strong&gt;while things move&lt;/strong&gt;. The recipe makes it again with the new setting, every part in the right place:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 300
shape face having size 60, skin &amp;quot;gold&amp;quot; {
  circle head having radius size / 2, fill skin
  circle eye1 at -size / 6, -size / 10 having radius size / 15, fill &amp;quot;black&amp;quot;
  circle eye2 at size / 6, -size / 10 having radius size / 15, fill &amp;quot;black&amp;quot;
}
draw face sam at 200, 150
sam.size = 160 in 2 seconds
sam.skin = &amp;quot;pink&amp;quot; in 2 seconds&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 300&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;300&quot; fill=&quot;white&quot; /&gt;
  &lt;g&gt;
  &lt;circle cx=&quot;200&quot; cy=&quot;150&quot; r=&quot;30&quot; fill=&quot;gold&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;190&quot; cy=&quot;144&quot; r=&quot;4&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;210&quot; cy=&quot;144&quot; r=&quot;4&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;/g&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAzMDAKc2hhcGUgZmFjZSBoYXZpbmcgc2l6ZSA2MCwgc2tpbiAiZ29sZCIgewogIGNpcmNsZSBoZWFkIGhhdmluZyByYWRpdXMgc2l6ZSAvIDIsIGZpbGwgc2tpbgogIGNpcmNsZSBleWUxIGF0IC1zaXplIC8gNiwgLXNpemUgLyAxMCBoYXZpbmcgcmFkaXVzIHNpemUgLyAxNSwgZmlsbCAiYmxhY2siCiAgY2lyY2xlIGV5ZTIgYXQgc2l6ZSAvIDYsIC1zaXplIC8gMTAgaGF2aW5nIHJhZGl1cyBzaXplIC8gMTUsIGZpbGwgImJsYWNrIgp9CmRyYXcgZmFjZSBzYW0gYXQgMjAwLCAxNTAKc2FtLnNpemUgPSAxNjAgaW4gMiBzZWNvbmRzCnNhbS5za2luID0gInBpbmsiIGluIDIgc2Vjb25kcw&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;The eyes grow and move with the head, because the recipe makes the face again as &lt;code&gt;size&lt;/code&gt; grows.&lt;/p&gt;
&lt;h2&gt;Click a recipe 👆&lt;/h2&gt;
&lt;p&gt;A click can change a setting too. Each click makes this face bigger:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 300
shape face having size 60 {
  circle head having radius size / 2, fill &amp;quot;gold&amp;quot;
  circle eye1 at -size / 6, -size / 10 having radius size / 15, fill &amp;quot;black&amp;quot;
  circle eye2 at size / 6, -size / 10 having radius size / 15, fill &amp;quot;black&amp;quot;
}
draw face sam at 200, 150
when sam is clicked {
  sam.size = sam.size + 20
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 300&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;300&quot; fill=&quot;white&quot; /&gt;
  &lt;g cursor=&quot;pointer&quot; pointer-events=&quot;visible&quot;&gt;
  &lt;circle cx=&quot;200&quot; cy=&quot;150&quot; r=&quot;30&quot; fill=&quot;gold&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;190&quot; cy=&quot;144&quot; r=&quot;4&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;210&quot; cy=&quot;144&quot; r=&quot;4&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;/g&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAzMDAKc2hhcGUgZmFjZSBoYXZpbmcgc2l6ZSA2MCB7CiAgY2lyY2xlIGhlYWQgaGF2aW5nIHJhZGl1cyBzaXplIC8gMiwgZmlsbCAiZ29sZCIKICBjaXJjbGUgZXllMSBhdCAtc2l6ZSAvIDYsIC1zaXplIC8gMTAgaGF2aW5nIHJhZGl1cyBzaXplIC8gMTUsIGZpbGwgImJsYWNrIgogIGNpcmNsZSBleWUyIGF0IHNpemUgLyA2LCAtc2l6ZSAvIDEwIGhhdmluZyByYWRpdXMgc2l6ZSAvIDE1LCBmaWxsICJibGFjayIKfQpkcmF3IGZhY2Ugc2FtIGF0IDIwMCwgMTUwCndoZW4gc2FtIGlzIGNsaWNrZWQgewogIHNhbS5zaXplID0gc2FtLnNpemUgKyAyMAp9&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;h2&gt;Two new rules 📏&lt;/h2&gt;
&lt;p&gt;To make recipes work like this, they keep to themselves:&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;1. Only its settings change a recipe&amp;#39;s shape.&lt;/strong&gt; You can read its parts, like &lt;code&gt;sam.eye1.center&lt;/code&gt;, but not change them: &lt;code&gt;sam.eye1.fill = &amp;quot;blue&amp;quot;&lt;/code&gt; is now a mistake. Give the recipe a setting instead:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 300
shape face having size 100, eyes &amp;quot;black&amp;quot; {
  circle head having radius size / 2, fill &amp;quot;gold&amp;quot;
  circle eye1 at -size / 6, -size / 10 having radius size / 15, fill eyes
  circle eye2 at size / 6, -size / 10 having radius size / 15, fill eyes
}
draw face sam at 200, 150
sam.eyes = &amp;quot;blue&amp;quot;&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 300&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;300&quot; fill=&quot;white&quot; /&gt;
  &lt;g&gt;
  &lt;circle cx=&quot;200&quot; cy=&quot;150&quot; r=&quot;50&quot; fill=&quot;gold&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;183.33&quot; cy=&quot;140&quot; r=&quot;6.67&quot; fill=&quot;blue&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;216.67&quot; cy=&quot;140&quot; r=&quot;6.67&quot; fill=&quot;blue&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;/g&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAzMDAKc2hhcGUgZmFjZSBoYXZpbmcgc2l6ZSAxMDAsIGV5ZXMgImJsYWNrIiB7CiAgY2lyY2xlIGhlYWQgaGF2aW5nIHJhZGl1cyBzaXplIC8gMiwgZmlsbCAiZ29sZCIKICBjaXJjbGUgZXllMSBhdCAtc2l6ZSAvIDYsIC1zaXplIC8gMTAgaGF2aW5nIHJhZGl1cyBzaXplIC8gMTUsIGZpbGwgZXllcwogIGNpcmNsZSBleWUyIGF0IHNpemUgLyA2LCAtc2l6ZSAvIDEwIGhhdmluZyByYWRpdXMgc2l6ZSAvIDE1LCBmaWxsIGV5ZXMKfQpkcmF3IGZhY2Ugc2FtIGF0IDIwMCwgMTUwCnNhbS5leWVzID0gImJsdWUi&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;&lt;strong&gt;2. A recipe uses only its own settings and parts.&lt;/strong&gt; It can&amp;#39;t use the other shapes and numbers in your drawing. If it needs something, give it a setting, and set it where you draw it:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 300
draw circle sun at 350, 50 having radius 30, fill &amp;quot;gold&amp;quot;
shape face having size 100, skin &amp;quot;pink&amp;quot; {
  circle head having radius size / 2, fill skin
}
draw face at 150, 150 having skin sun.fill&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 300&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;300&quot; fill=&quot;white&quot; /&gt;
  &lt;circle cx=&quot;350&quot; cy=&quot;50&quot; r=&quot;30&quot; fill=&quot;gold&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;g&gt;
  &lt;circle cx=&quot;150&quot; cy=&quot;150&quot; r=&quot;50&quot; fill=&quot;gold&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;/g&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAzMDAKZHJhdyBjaXJjbGUgc3VuIGF0IDM1MCwgNTAgaGF2aW5nIHJhZGl1cyAzMCwgZmlsbCAiZ29sZCIKc2hhcGUgZmFjZSBoYXZpbmcgc2l6ZSAxMDAsIHNraW4gInBpbmsiIHsKICBjaXJjbGUgaGVhZCBoYXZpbmcgcmFkaXVzIHNpemUgLyAyLCBmaWxsIHNraW4KfQpkcmF3IGZhY2UgYXQgMTUwLCAxNTAgaGF2aW5nIHNraW4gc3VuLmZpbGw&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;Why? A recipe should work the same way in every drawing you put it in. Everything it needs comes in through its settings, and only its settings change it. That&amp;#39;s what makes a recipe easy to share, and soon, to keep in a file of its own.&lt;/p&gt;
&lt;p&gt;If one of your drawings did one of these, VeeLang will tell you, with what to write instead.&lt;/p&gt;
&lt;p&gt;Learn more in &lt;a href=&quot;https://learn.veelang.org/tutorials/15-recipes/&quot;&gt;Your Own Shapes&lt;/a&gt; and the &lt;a href=&quot;https://learn.veelang.org/reference/recipes/&quot;&gt;recipes reference&lt;/a&gt;. Have fun! ✨&lt;/p&gt;
</content>
  </entry>
  <entry>
    <title>Follow that kite! 🪁</title>
    <link href="https://veelang.org/blog/follow-that-kite/" />
    <id>https://veelang.org/blog/follow-that-kite/</id>
    <updated>2026-10-09T00:00:00Z</updated>
    <author><name>Suhas Chatekar</name></author>
    <summary>Put @ in front of a shape's name, and a shape follows it wherever it goes, even while it moves.</summary>
    <content type="html">&lt;p&gt;When you write &lt;code&gt;kite.center&lt;/code&gt;, VeeLang reads where the kite is &lt;strong&gt;right now&lt;/strong&gt;. If the kite flies off, whatever you put there stays behind.&lt;/p&gt;
&lt;p&gt;Put &lt;code&gt;@&lt;/code&gt; in front, and it &lt;strong&gt;follows&lt;/strong&gt; the kite instead:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 300, fill &amp;quot;lightskyblue&amp;quot;
draw circle kite at 300, 60 having radius 15, fill &amp;quot;tomato&amp;quot;
draw line string from 60, 280 to @kite.center
forever {
  move kite by -150, 30 in 2 seconds
  move kite by 150, -30 in 2 seconds
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 300&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;300&quot; fill=&quot;lightskyblue&quot; /&gt;
  &lt;circle cx=&quot;300&quot; cy=&quot;60&quot; r=&quot;15&quot; fill=&quot;tomato&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;line x1=&quot;60&quot; y1=&quot;280&quot; x2=&quot;300&quot; y2=&quot;60&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAzMDAsIGZpbGwgImxpZ2h0c2t5Ymx1ZSIKZHJhdyBjaXJjbGUga2l0ZSBhdCAzMDAsIDYwIGhhdmluZyByYWRpdXMgMTUsIGZpbGwgInRvbWF0byIKZHJhdyBsaW5lIHN0cmluZyBmcm9tIDYwLCAyODAgdG8gQGtpdGUuY2VudGVyCmZvcmV2ZXIgewogIG1vdmUga2l0ZSBieSAtMTUwLCAzMCBpbiAyIHNlY29uZHMKICBtb3ZlIGtpdGUgYnkgMTUwLCAtMzAgaW4gMiBzZWNvbmRzCn0&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;Wherever the kite goes, the end of the string goes too. &lt;code&gt;@&lt;/code&gt; means &amp;quot;follow&amp;quot;.&lt;/p&gt;
&lt;h2&gt;Follow a colour 🎨&lt;/h2&gt;
&lt;p&gt;You can follow anything about a shape, not just where it is. This flower is always the same colour as the sun:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 250
draw circle sun at 80, 80 having radius 30, fill &amp;quot;gold&amp;quot;
draw circle flower at 300, 180 having radius 20, fill @sun.fill
forever {
  sun.fill = &amp;quot;orange&amp;quot; in 2 seconds
  sun.fill = &amp;quot;gold&amp;quot; in 2 seconds
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 250&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;250&quot; fill=&quot;white&quot; /&gt;
  &lt;circle cx=&quot;80&quot; cy=&quot;80&quot; r=&quot;30&quot; fill=&quot;rgb(255, 215, 0)&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;300&quot; cy=&quot;180&quot; r=&quot;20&quot; fill=&quot;rgb(255, 215, 0)&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNTAKZHJhdyBjaXJjbGUgc3VuIGF0IDgwLCA4MCBoYXZpbmcgcmFkaXVzIDMwLCBmaWxsICJnb2xkIgpkcmF3IGNpcmNsZSBmbG93ZXIgYXQgMzAwLCAxODAgaGF2aW5nIHJhZGl1cyAyMCwgZmlsbCBAc3VuLmZpbGwKZm9yZXZlciB7CiAgc3VuLmZpbGwgPSAib3JhbmdlIiBpbiAyIHNlY29uZHMKICBzdW4uZmlsbCA9ICJnb2xkIiBpbiAyIHNlY29uZHMKfQ&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;h2&gt;Parts that follow 👀&lt;/h2&gt;
&lt;p&gt;Inside a shape&amp;#39;s &lt;code&gt;{ }&lt;/code&gt;, a part can follow another part. The pupil stays in the eye, even when the eye moves:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 300
draw circle face at 200, 150 having radius 100, fill &amp;quot;peachpuff&amp;quot; {
  circle eye at -35, -25 having radius 15, fill &amp;quot;white&amp;quot;
  circle pupil at @eye.center having radius 6, fill &amp;quot;black&amp;quot;
}
forever {
  move face.eye by 40, 0 in 1 second
  move face.eye by -40, 0 in 1 second
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 300&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;300&quot; fill=&quot;white&quot; /&gt;
  &lt;g&gt;
  &lt;circle cx=&quot;200&quot; cy=&quot;150&quot; r=&quot;100&quot; fill=&quot;peachpuff&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;165&quot; cy=&quot;125&quot; r=&quot;15&quot; fill=&quot;white&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;165&quot; cy=&quot;125&quot; r=&quot;6&quot; fill=&quot;black&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;/g&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAzMDAKZHJhdyBjaXJjbGUgZmFjZSBhdCAyMDAsIDE1MCBoYXZpbmcgcmFkaXVzIDEwMCwgZmlsbCAicGVhY2hwdWZmIiB7CiAgY2lyY2xlIGV5ZSBhdCAtMzUsIC0yNSBoYXZpbmcgcmFkaXVzIDE1LCBmaWxsICJ3aGl0ZSIKICBjaXJjbGUgcHVwaWwgYXQgQGV5ZS5jZW50ZXIgaGF2aW5nIHJhZGl1cyA2LCBmaWxsICJibGFjayIKfQpmb3JldmVyIHsKICBtb3ZlIGZhY2UuZXllIGJ5IDQwLCAwIGluIDEgc2Vjb25kCiAgbW92ZSBmYWNlLmV5ZSBieSAtNDAsIDAgaW4gMSBzZWNvbmQKfQ&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;h2&gt;Try it! 🎯&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;🌟 Give the kite a tail that follows it.&lt;/li&gt;
&lt;li&gt;🌟 Make a shadow under a bouncing ball: &lt;code&gt;draw oval shadow at @ball.x, 280&lt;/code&gt;.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Learn more in &lt;a href=&quot;https://learn.veelang.org/tutorials/17-making-things-move/#following-another-shape&quot;&gt;Making Things Move&lt;/a&gt;. Have fun! ✨&lt;/p&gt;
</content>
  </entry>
  <entry>
    <title>Your drawings can move! 🎬</title>
    <link href="https://veelang.org/blog/your-drawings-can-move/" />
    <id>https://veelang.org/blog/your-drawings-can-move/</id>
    <updated>2026-10-08T00:00:00Z</updated>
    <author><name>Suhas Chatekar</name></author>
    <summary>Add a time to a change and watch it happen: move, turn, grow, wait, repeat for ever, and do two things at once.</summary>
    <content type="html">&lt;p&gt;Until today, a VeeLang drawing was a picture. It stayed still.&lt;/p&gt;
&lt;p&gt;Now it can &lt;strong&gt;move&lt;/strong&gt;. Add &lt;code&gt;in 2 seconds&lt;/code&gt; to a change, and VeeLang does it slowly, so you can watch:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 250, fill &amp;quot;lightskyblue&amp;quot;
draw circle sun at 60, 200 having radius 30, fill &amp;quot;gold&amp;quot;
move sun to 340, 60 in 3 seconds
sun.fill = &amp;quot;orange&amp;quot; in 3 seconds&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 250&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;250&quot; fill=&quot;lightskyblue&quot; /&gt;
  &lt;circle cx=&quot;60&quot; cy=&quot;200&quot; r=&quot;30&quot; fill=&quot;gold&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNTAsIGZpbGwgImxpZ2h0c2t5Ymx1ZSIKZHJhdyBjaXJjbGUgc3VuIGF0IDYwLCAyMDAgaGF2aW5nIHJhZGl1cyAzMCwgZmlsbCAiZ29sZCIKbW92ZSBzdW4gdG8gMzQwLCA2MCBpbiAzIHNlY29uZHMKc3VuLmZpbGwgPSAib3JhbmdlIiBpbiAzIHNlY29uZHM&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;The picture is drawn first. Then, one line after another, the sun rises and turns orange.&lt;/p&gt;
&lt;h2&gt;Move, turn and grow 🌀&lt;/h2&gt;
&lt;p&gt;&lt;code&gt;move&lt;/code&gt; goes somewhere, &lt;code&gt;turn&lt;/code&gt; spins, and &lt;code&gt;grow&lt;/code&gt; and &lt;code&gt;shrink&lt;/code&gt; change the size. Each one can go &lt;code&gt;to&lt;/code&gt; a place or a size, or &lt;code&gt;by&lt;/code&gt; an amount:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 250
draw square box at 60, 80 having size 60, fill &amp;quot;tomato&amp;quot;
move box by 220, 0 in 2 seconds
turn box by 90 in 1 second
grow box by 2 in 1 second&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 250&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;250&quot; fill=&quot;white&quot; /&gt;
  &lt;rect x=&quot;60&quot; y=&quot;80&quot; width=&quot;60&quot; height=&quot;60&quot; fill=&quot;tomato&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNTAKZHJhdyBzcXVhcmUgYm94IGF0IDYwLCA4MCBoYXZpbmcgc2l6ZSA2MCwgZmlsbCAidG9tYXRvIgptb3ZlIGJveCBieSAyMjAsIDAgaW4gMiBzZWNvbmRzCnR1cm4gYm94IGJ5IDkwIGluIDEgc2Vjb25kCmdyb3cgYm94IGJ5IDIgaW4gMSBzZWNvbmQ&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;You can change anything slowly: a colour, a size, even the words in a text.&lt;/p&gt;
&lt;h2&gt;Again and again ♾️&lt;/h2&gt;
&lt;p&gt;&lt;code&gt;forever&lt;/code&gt; repeats its lines for ever, and &lt;code&gt;wait&lt;/code&gt; waits a little:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 250
draw square fan at 200, 125 having size 80, fill &amp;quot;tomato&amp;quot;
forever {
  turn fan by 90 in 1 second
  wait 0.5 seconds
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 250&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;250&quot; fill=&quot;white&quot; /&gt;
  &lt;rect x=&quot;200&quot; y=&quot;125&quot; width=&quot;80&quot; height=&quot;80&quot; fill=&quot;tomato&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNTAKZHJhdyBzcXVhcmUgZmFuIGF0IDIwMCwgMTI1IGhhdmluZyBzaXplIDgwLCBmaWxsICJ0b21hdG8iCmZvcmV2ZXIgewogIHR1cm4gZmFuIGJ5IDkwIGluIDEgc2Vjb25kCiAgd2FpdCAwLjUgc2Vjb25kcwp9&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;h2&gt;Two things at once 🤹&lt;/h2&gt;
&lt;p&gt;Lines happen one after another. Put them in &lt;code&gt;together&lt;/code&gt;, and they happen at the same time:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 250, fill &amp;quot;midnightblue&amp;quot;
draw circle moon at 60, 60 having radius 25, fill &amp;quot;lightyellow&amp;quot;
draw text words at 200, 200 having content &amp;quot;Good night!&amp;quot;, size 30, color &amp;quot;white&amp;quot;
hide words
together {
  move moon to 340, 60 in 3 seconds
  show words in 3 seconds
}&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 250&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;250&quot; fill=&quot;midnightblue&quot; /&gt;
  &lt;circle cx=&quot;60&quot; cy=&quot;60&quot; r=&quot;25&quot; fill=&quot;lightyellow&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;text x=&quot;200&quot; y=&quot;200&quot; font-family=&quot;sans-serif&quot; font-size=&quot;30&quot; fill=&quot;white&quot; opacity=&quot;0&quot; pointer-events=&quot;none&quot;&gt;Good night!&lt;/text&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNTAsIGZpbGwgIm1pZG5pZ2h0Ymx1ZSIKZHJhdyBjaXJjbGUgbW9vbiBhdCA2MCwgNjAgaGF2aW5nIHJhZGl1cyAyNSwgZmlsbCAibGlnaHR5ZWxsb3ciCmRyYXcgdGV4dCB3b3JkcyBhdCAyMDAsIDIwMCBoYXZpbmcgY29udGVudCAiR29vZCBuaWdodCEiLCBzaXplIDMwLCBjb2xvciAid2hpdGUiCmhpZGUgd29yZHMKdG9nZXRoZXIgewogIG1vdmUgbW9vbiB0byAzNDAsIDYwIGluIDMgc2Vjb25kcwogIHNob3cgd29yZHMgaW4gMyBzZWNvbmRzCn0&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;p&gt;&lt;code&gt;hide&lt;/code&gt; and &lt;code&gt;show&lt;/code&gt; make a shape disappear and come back, slowly if you give them a time.&lt;/p&gt;
&lt;h2&gt;Try it! 🎯&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;🌟 Make the sun set again after it rises.&lt;/li&gt;
&lt;li&gt;🌟 Make the fan spin faster.&lt;/li&gt;
&lt;li&gt;🌟 Make a ball that moves across the page and back, for ever.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Learn more in &lt;a href=&quot;https://learn.veelang.org/tutorials/17-making-things-move/&quot;&gt;Making Things Move&lt;/a&gt; and the &lt;a href=&quot;https://learn.veelang.org/reference/animation/&quot;&gt;animation reference&lt;/a&gt;. Have fun! ✨&lt;/p&gt;
</content>
  </entry>
  <entry>
    <title>Ask a shape where it is! 📍</title>
    <link href="https://veelang.org/blog/ask-a-shape-where-it-is/" />
    <id>https://veelang.org/blog/ask-a-shape-where-it-is/</id>
    <updated>2026-10-06T00:00:00Z</updated>
    <author><name>Suhas Chatekar</name></author>
    <summary>Now you can write house.at to find out where the house is, and build things next to it.</summary>
    <content type="html">&lt;p&gt;Every shape has an &lt;code&gt;at&lt;/code&gt;. It tells VeeLang where to draw the shape.&lt;/p&gt;
&lt;p&gt;Now you can &lt;strong&gt;ask&lt;/strong&gt; a shape where it is. Write its name, a dot, and &lt;code&gt;at&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code&gt;house.at
&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;Before today, this didn&amp;#39;t work. VeeLang said it was a mistake. But it wasn&amp;#39;t your mistake: it was VeeLang&amp;#39;s! Now it&amp;#39;s fixed. 🛠️&lt;/p&gt;
&lt;h2&gt;Build a chimney 🏠&lt;/h2&gt;
&lt;p&gt;This house has a chimney. The chimney asks the house where it is, and puts itself on the roof:&lt;/p&gt;
&lt;figure class=&quot;vee-example&quot;&gt;
  &lt;pre&gt;&lt;code&gt;Canvas paper having width 400, length 260,
  fill &amp;quot;lightskyblue&amp;quot;
draw rectangle house at 120, 120
  having width 160, length 120, fill &amp;quot;tomato&amp;quot;
draw rectangle chimney at house.at.x + 110, house.at.y - 40
  having width 25, length 40, fill &amp;quot;brown&amp;quot;
draw circle at chimney.at.x + 12, chimney.at.y - 20
  having radius 12, fill &amp;quot;white&amp;quot;
draw circle at chimney.at.x + 30, chimney.at.y - 45
  having radius 16, fill &amp;quot;white&amp;quot;&lt;/code&gt;&lt;/pre&gt;
  &lt;div class=&quot;vee-drawing&quot;&gt;&lt;svg xmlns=&quot;http://www.w3.org/2000/svg&quot; viewBox=&quot;0 0 400 260&quot; preserveAspectRatio=&quot;xMidYMid meet&quot;&gt;
&lt;rect x=&quot;0&quot; y=&quot;0&quot; width=&quot;400&quot; height=&quot;260&quot; fill=&quot;lightskyblue&quot; /&gt;
  &lt;rect x=&quot;120&quot; y=&quot;120&quot; width=&quot;160&quot; height=&quot;120&quot; fill=&quot;tomato&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;rect x=&quot;230&quot; y=&quot;80&quot; width=&quot;25&quot; height=&quot;40&quot; fill=&quot;brown&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;242&quot; cy=&quot;60&quot; r=&quot;12&quot; fill=&quot;white&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
  &lt;circle cx=&quot;260&quot; cy=&quot;35&quot; r=&quot;16&quot; fill=&quot;white&quot; stroke=&quot;black&quot; stroke-width=&quot;1&quot; /&gt;
&lt;/svg&gt;&lt;/div&gt;
  &lt;figcaption&gt;&lt;a href=&quot;https://play.veelang.org/#code=uQ2FudmFzIHBhcGVyIGhhdmluZyB3aWR0aCA0MDAsIGxlbmd0aCAyNjAsCiAgZmlsbCAibGlnaHRza3libHVlIgpkcmF3IHJlY3RhbmdsZSBob3VzZSBhdCAxMjAsIDEyMAogIGhhdmluZyB3aWR0aCAxNjAsIGxlbmd0aCAxMjAsIGZpbGwgInRvbWF0byIKZHJhdyByZWN0YW5nbGUgY2hpbW5leSBhdCBob3VzZS5hdC54ICsgMTEwLCBob3VzZS5hdC55IC0gNDAKICBoYXZpbmcgd2lkdGggMjUsIGxlbmd0aCA0MCwgZmlsbCAiYnJvd24iCmRyYXcgY2lyY2xlIGF0IGNoaW1uZXkuYXQueCArIDEyLCBjaGltbmV5LmF0LnkgLSAyMAogIGhhdmluZyByYWRpdXMgMTIsIGZpbGwgIndoaXRlIgpkcmF3IGNpcmNsZSBhdCBjaGltbmV5LmF0LnggKyAzMCwgY2hpbW5leS5hdC55IC0gNDUKICBoYXZpbmcgcmFkaXVzIDE2LCBmaWxsICJ3aGl0ZSI&quot;&gt;Open in the Playground&lt;/a&gt;&lt;/figcaption&gt;
&lt;/figure&gt;
&lt;ul&gt;
&lt;li&gt;&lt;code&gt;house.at.x&lt;/code&gt; is how far &lt;strong&gt;across&lt;/strong&gt; the house is.&lt;/li&gt;
&lt;li&gt;&lt;code&gt;house.at.y&lt;/code&gt; is how far &lt;strong&gt;down&lt;/strong&gt; the house is.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;So &lt;code&gt;house.at.y - 40&lt;/code&gt; means &amp;quot;40 higher than the house&amp;quot;. The smoke does the same thing with the chimney. 💨&lt;/p&gt;
&lt;h2&gt;Try it! 🎯&lt;/h2&gt;
&lt;p&gt;Press &lt;strong&gt;Open in the Playground&lt;/strong&gt; under the drawing, then:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;🌟 Change the house&amp;#39;s &lt;code&gt;120, 120&lt;/code&gt; to &lt;code&gt;40, 100&lt;/code&gt;. The chimney and the smoke move with the house, because they ask the house where it is!&lt;/li&gt;
&lt;li&gt;🌟 Add a door. Use &lt;code&gt;house.at.x&lt;/code&gt; and &lt;code&gt;house.at.y&lt;/code&gt; to put it at the bottom of the house.&lt;/li&gt;
&lt;li&gt;🌟 Add more smoke, higher and higher.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Have fun! ✨&lt;/p&gt;
</content>
  </entry>
</feed>
