<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[Using Spheres]]></title><description><![CDATA[<p dir="auto"> </p>
<h2><a class="anchor-offset" name="prerequisite"></a>Prerequisite</h2>
<ul>
<li><a href="/topic/14/adding-boxes-to-a-3d-scene">Adding Boxes to a 3D scene</a></li>
</ul>
<h2><a class="anchor-offset" name="introduction"></a>Introduction</h2>
<p dir="auto">Besides boxes, the next most commonly used shape in 3D scenes is the Sphere. Spheres can be added using the <strong>add sphere</strong> block from the <strong>3D Object</strong> category:</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/64af77df-e310-4f4d-913d-fc3290749e99.png" width="800" style="filter:drop-shadow(0.35rem 0.35rem 0.4rem rgba(0, 0, 0, 0.5))" /></p>
<p dir="auto"> </p>
<h2><a class="anchor-offset" name="parameters"></a>Parameters</h2>
<h3><a class="anchor-offset" name="strong-color-strong"></a><strong>Color</strong></h3>
<p dir="auto">You can set the color of the sphere by clicking on the color input.</p>
<h3><a class="anchor-offset" name="strong-size-in-x-y-z-strong"></a><strong>Size in x/y/z</strong></h3>
<p dir="auto">These 3 numbers control the size of the sphere in each direction. For example, the following program adds an oval shape that is taller along the Z-axis:</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/5cf1c819-82f3-4013-96dd-acae03911f32.png" width="800" style="filter:drop-shadow(0.35rem 0.35rem 0.4rem rgba(0, 0, 0, 0.5))" /></p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/a993d755-b8ef-4aac-b93a-58d38f13b166.gif" width="325" style="border-radius:5px;border:1px solid #29622d" /></p>
<p dir="auto"> </p>
<h3><a class="anchor-offset" name="arc"></a>Arc</h3>
<p dir="auto">The “arc” value allows us to show a portion of a sphere, just like how you can peel off some sections of an orange:</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/3c2d967d-0c24-46f5-9976-8e0e35e78443.png" width="300" style="border-radius:5px;border:1px solid #29622d" /></p>
<p dir="auto">For example, the following picture shows the difference between arc values of 100, 75, 50, 25 and 5:</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/be785df3-2da3-4bd0-ac47-f4120b620da5.gif" width="700" style="border-radius:5px;border:1px solid #29622d" /></p>
<p dir="auto"> </p>
<h3><a class="anchor-offset" name="slice"></a>Slice</h3>
<p dir="auto">The “slice” value allows us to vertically cut off a portion of a sphere, just like how you cut lemon slices:</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/ecae681f-afda-4269-95ec-169044bc2f06.png" width="400" style="border-radius:5px;border:1px solid #29622d" /></p>
<p dir="auto">For example, the following picture shows the difference between slice values of 100, 75, 50, 25 and 5:</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/42d0d9b4-df20-436a-970b-d781a8140934.gif" width="700" style="border-radius:5px;border:1px solid #29622d" /></p>
<p dir="auto"> </p>
<h3><a class="anchor-offset" name="sides"></a>Sides</h3>
<p dir="auto">A sphere is approximated by many small triangles, and the “sides” value controls how many such triangles are used. The more sides, the smoother the sphere looks, but it would also take the game engine more time to draw these triangles. For example, the following picture shows the difference between sides values of 2, 4, 8, 16 and 32.</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/3a158433-155c-4b39-a847-76fa33313cbf.gif" width="700" style="border-radius:5px;border:1px solid #29622d" /></p>
<p dir="auto">For most situations, you can use sides of 8 or 16 to reduce the computations. If you are including a very large sphere in your scene, then you will need to use more sides to make it smooth.</p>
<p dir="auto"> </p>
<h2><a class="anchor-offset" name="demo"></a>Demo</h2>
<p dir="auto">When you set both the arc and slice to less than 100, you can get some interesting shapes.</p>
<p dir="auto">For example, with <strong>arc of 25 and slice of 50</strong>, you get a flying carpet:</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/fe6070f7-13ed-463f-aa76-268c730197b9.gif" width="250" style="border-radius:5px;border:1px solid #29622d" /></p>
<p dir="auto">On the other hand, with <strong>arc of 50 and slice of 25</strong>, you get a face mask:</p>
<p dir="auto"><img src="https://cdncreaticodecom.b-cdn.net/scratch-gui-projects/forum/5b4b92a9-7352-4a12-9228-47d043e45395.gif" width="250" style="border-radius:5px;border:1px solid #29622d" /></p>
]]></description><link>https://forum.creaticode.com/topic/117/using-spheres</link><generator>RSS for Node</generator><lastBuildDate>Sat, 05 Sep 2026 18:08:01 GMT</lastBuildDate><atom:link href="https://forum.creaticode.com/topic/117.rss" rel="self" type="application/rss+xml"/><pubDate>Wed, 23 Mar 2022 20:04:12 GMT</pubDate><ttl>60</ttl></channel></rss>