<html><head><meta http-equiv="content-type" content="text/html; charset=utf-8"></head><body dir="auto"><div>The ability to compare colors is not implemented  in the version of Alice that is currently available to download.</div><div id="AppleMailSignature"><br></div><div id="AppleMailSignature">In the meantime, try this:</div><div id="AppleMailSignature"><br></div><div id="AppleMailSignature">1) Create a TextString variable property for the Disc class, name it "color", and set its initial value to "white".</div><div id="AppleMailSignature"><br></div><div id="AppleMailSignature">2) There is a procedural method in the Scene class called "PerformCustomSetup". Edit this method and set the values of each of the color variables for each Disc to the appropriate color.</div><div id="AppleMailSignature"><br></div><div id="AppleMailSignature">3) Youo can now write if statements to compare the variable TextString values.</div><div id="AppleMailSignature"><br></div><div id="AppleMailSignature">4) If you are changing the colors of the disc, be sure to also change th`e text value of the variable appropriately.</div><div id="AppleMailSignature"><br></div><div id="AppleMailSignature">Let us know if you have any other questions...</div><div id="AppleMailSignature"><br></div><div id="AppleMailSignature">All the best,</div><div id="AppleMailSignature">Don Slater<br><br>Sent from my iPad</div><div><br>On Apr 8, 2016, at 12:30 PM, Steven Jang via alice-teachers <<a href="mailto:alice-teachers@lists.andrew.cmu.edu">alice-teachers@lists.andrew.cmu.edu</a>> wrote:<br><br></div><blockquote type="cite"><div><div dir="ltr"><div style="font-size:12.8px">I found a post by S. Rodger with the question of comparing if two objects have the same colors.,</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">My students have a similar problem for a class project and I found your post of 11/25/2013. </div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">Our project randomly flips 4x4 discs. When you get four disc in a row with the same colors, you win. We can't find a way to use an if statement to do this.</div><div style="font-size:12.8px"><br></div><div style="font-size:12.8px">Did the Alice 3 team find a solution  to compare if the colors of two objects are the same? I could not after searching the web.</div><div><br></div><div><div><div dir="ltr"><div><div dir="ltr"><span style="font-size:12.8px;color:rgb(0,0,153)"><b style="font-size:14px"><font size="6">PACIFIC ACADEMY</font></b><br><b style="font-size:14px">T H E  O P P O R T U N I T Y  T O  B E  M E<br></b><font size="1"><i>A Private Preparatory School for Grades 7 through 12</i><b><br></b></font><br><b>S T E V E  J A N G<br></b></span><div style="font-size:14px;font-family:arial,helvetica,sans-serif"><div><span style="color:rgb(0,0,153)"><b>PACIFIC ACADEMY |</b> Computer Science/Math instructor</span></div><div><span style="color:rgb(0,0,153)"><span style="border-collapse:collapse">Email:  SJang<a href="mailto:ayu@PacificAcademy.org" style="color:rgb(17,85,204)" target="_blank">@pacificacademy.org<br></a></span></span></div><div><span style="color:rgb(0,0,153)"><span style="border-collapse:collapse">Websites: <a href="http://www.pacificacademy.org/" style="color:rgb(17,85,204)" target="_blank">pacificacademy.org<br></a></span></span></div><div><span style="color:rgb(0,0,153)"><br></span><span style="color:rgb(0,0,153)"><span style="border-collapse:collapse"><u><span style="border-collapse:collapse"><u>Irvine Campus<br></u></span></u><span style="border-collapse:collapse">4947 Alton Parkway, Irvine, CA 92604<br>Phone: <a style="color:rgb(34,34,34)">(949) 398-5288, </a>Fax: <a style="color:rgb(34,34,34)">(949) 398-5289</a></span></span></span><div><br></div><span style="color:rgb(0,0,153)"><u>San Diego Campus<br></u>679 Encinitas Blvd,  #205, Encinitas, CA 92024<br>Phone: <a style="color:rgb(34,34,34)">(760) 634-1188, </a>Fax: <a style="color:rgb(34,34,34)">(760) 436-5718</a></span></div></div></div></div></div></div></div>
</div>
</div></blockquote><blockquote type="cite"><div><span>_______________________________________________</span><br><span>alice-teachers mailing list</span><br><span><a href="mailto:alice-teachers@lists.andrew.cmu.edu">alice-teachers@lists.andrew.cmu.edu</a></span><br><span><a href="https://lists.andrew.cmu.edu/mailman/listinfo/alice-teachers">https://lists.andrew.cmu.edu/mailman/listinfo/alice-teachers</a></span><br></div></blockquote></body></html>