<table cellspacing="0" cellpadding="0" border="0" ><tr><td valign="top" style="font: inherit;">Nice and clean compared to my "procedural" code (and variables). Would make it much simpler to add a third tower (same endgame conditions), while my code would require a complete rewrite.<br><br>I wasn't aware that the Etoys playfield has a timer. Perfect for taking turns.<br><br>Thanks.<br><br>Michael<br><br><br>--- On <b>Mon, 4/11/11, Bert Freudenberg <i>&lt;bert@freudenbergs.de&gt;</i></b> wrote:<br><blockquote style="border-left: 2px solid rgb(16, 16, 255); margin-left: 5px; padding-left: 5px;"><br>From: Bert Freudenberg &lt;bert@freudenbergs.de&gt;<br>Subject: Re: [Newbies] Re: Randomness + Pause/Delay?<br>To: "michael rice" &lt;nowgate@yahoo.com&gt;<br>Cc: "A friendly place to get answers to even the most basic questions about Squeak." &lt;beginners@lists.squeakfoundation.org&gt;<br>Date: Monday, April 11, 2011, 6:40 AM<br><br><div
 id="yiv133116365"><div><div>On 09.04.2011, at 13:28, michael rice wrote:</div><br class="yiv133116365Apple-interchange-newline"><blockquote type="cite"><table style="" border="0" cellpadding="0" cellspacing="0"><tbody><tr><td style="font: inherit;" valign="top">Here's the Etoys app. Load and press Go button and it will continue game where two players take turns randomly selecting a tower on which to place a blue or red block, each game concluding when both towers are topped with block of the same color.<br><br>As you can see, redAction and blueAction appear to happen simultaneously. Ergo, the wish for a means to delay for a tick or two between the two actions.<br><br>Michael<font class="yiv133116365Apple-style-span" color="#144fae"><font class="yiv133116365Apple-style-span" color="#000000"><br></font></font></td></tr></tbody></table></blockquote></div><div><br></div><div>The Etoys way would be to do the red and blue actions in alternating ticks.
 E.g.</div><div><br></div><div></div></div><div id="yiv1263256906"><div></div><div><br></div><div>However, the *real* Etoys way would be to&nbsp;let the Etoys objects do their work. Your approach is very procedural. It uses many variables and functions instead of objects. It even does the layout in code, calculating x,y coordinates etc.</div><div><br></div><div>I am attaching a project that does pretty much the same as yours, but does not need a single variable, and has only 3 simple scripts with about 3 lines each.</div><div><br></div><div><div style="font-family: Helvetica; font-size: 12px;"><span class="yiv1263256906Apple-style-span" style="font-family: Helvetica;">- Bert -</span></div><span class="yiv1263256906Apple-style-span" style="font-size: 12px;"><br class="yiv1263256906Apple-interchange-newline"></span></div></div><div id="yiv2033801688"></div></blockquote></td></tr></table>