<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>Comments on: Looping our game code</title>
	<atom:link href="https://gamecodeschool.com/java/looping-our-game-code/feed/" rel="self" type="application/rss+xml" />
	<link>https://gamecodeschool.com/java/looping-our-game-code/</link>
	<description>Game Coding for Beginners</description>
	<lastBuildDate>Fri, 06 Jun 2025 18:08:06 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>https://wordpress.org/?v=4.2.38</generator>
	<item>
		<title>By: John Horton</title>
		<link>https://gamecodeschool.com/java/looping-our-game-code/#comment-7941</link>
		<dc:creator><![CDATA[John Horton]]></dc:creator>
		<pubDate>Thu, 12 Oct 2017 09:00:51 +0000</pubDate>
		<guid isPermaLink="false">http://gamecodeschool.com/?p=11559#comment-7941</guid>
		<description><![CDATA[Hi there, maybe I am going mad. I have looked again and I still can&#039;t see my error. If I explain another way(how I think it is) and if you have time tell me again where my mistake is.

&lt;code&gt;while(playerLives !=0 &amp;&amp; alienShips !=0 ){&lt;/code&gt;

The above code says, keep looping all the time that &lt;strong&gt;both&lt;/strong&gt; &lt;code&gt;playerLives&lt;/code&gt; and &lt;code&gt;alienShips&lt;/code&gt; are any value other than zero. Therefore if &lt;strong&gt;either&lt;/strong&gt;(or perhaps even both simultaneously) &lt;code&gt;playerLives&lt;/code&gt; or &lt;code&gt;alienships&lt;/code&gt; becomes zero the loop will end.

I am not saying I am right I am just not able to see the error. This could be early onset Alzheimer&#039;s, I do have memory problems already. I hope you don&#039;t think I am being stubborn.

Thanks for taking the time.]]></description>
		<content:encoded><![CDATA[<p>Hi there, maybe I am going mad. I have looked again and I still can&#8217;t see my error. If I explain another way(how I think it is) and if you have time tell me again where my mistake is.</p>
<p>
			<span id="crayon-69e5dfc02b464285743150" class="crayon-syntax crayon-syntax-inline  crayon-theme-classic crayon-theme-classic-inline crayon-font-droid-sans-mono" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important;"><span class="crayon-pre crayon-code" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;"><span class="crayon-st">while</span><span class="crayon-sy">(</span><span class="crayon-v">playerLives</span><span class="crayon-h"> </span><span class="crayon-o">!=</span><span class="crayon-cn">0</span><span class="crayon-h"> </span><span class="crayon-o">&amp;&amp;</span><span class="crayon-h"> </span><span class="crayon-v">alienShips</span><span class="crayon-h"> </span><span class="crayon-o">!=</span><span class="crayon-cn">0</span><span class="crayon-h"> </span><span class="crayon-sy">)</span><span class="crayon-sy">{</span></span></span></p>
<p>The above code says, keep looping all the time that <strong>both</strong> 
			<span id="crayon-69e5dfc02b46b630580046" class="crayon-syntax crayon-syntax-inline  crayon-theme-classic crayon-theme-classic-inline crayon-font-droid-sans-mono" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important;"><span class="crayon-pre crayon-code" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;"><span class="crayon-v">playerLives</span></span></span> and 
			<span id="crayon-69e5dfc02b46d866140663" class="crayon-syntax crayon-syntax-inline  crayon-theme-classic crayon-theme-classic-inline crayon-font-droid-sans-mono" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important;"><span class="crayon-pre crayon-code" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;"><span class="crayon-v">alienShips</span></span></span> are any value other than zero. Therefore if <strong>either</strong>(or perhaps even both simultaneously) 
			<span id="crayon-69e5dfc02b46f714961325" class="crayon-syntax crayon-syntax-inline  crayon-theme-classic crayon-theme-classic-inline crayon-font-droid-sans-mono" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important;"><span class="crayon-pre crayon-code" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;"><span class="crayon-v">playerLives</span></span></span> or 
			<span id="crayon-69e5dfc02b472828840614" class="crayon-syntax crayon-syntax-inline  crayon-theme-classic crayon-theme-classic-inline crayon-font-droid-sans-mono" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important;"><span class="crayon-pre crayon-code" style="font-size: 12px !important; line-height: 16px !important;font-size: 12px !important; -moz-tab-size:4; -o-tab-size:4; -webkit-tab-size:4; tab-size:4;"><span class="crayon-v">alienships</span></span></span> becomes zero the loop will end.</p>
<p>I am not saying I am right I am just not able to see the error. This could be early onset Alzheimer&#8217;s, I do have memory problems already. I hope you don&#8217;t think I am being stubborn.</p>
<p>Thanks for taking the time.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: TflnSlckr</title>
		<link>https://gamecodeschool.com/java/looping-our-game-code/#comment-7478</link>
		<dc:creator><![CDATA[TflnSlckr]]></dc:creator>
		<pubDate>Tue, 10 Oct 2017 18:47:33 +0000</pubDate>
		<guid isPermaLink="false">http://gamecodeschool.com/?p=11559#comment-7478</guid>
		<description><![CDATA[Hi John,

Sorry, but correct me if I&#039;m wrong but I think Lux comment that you should use the &quot;&#124;&#124;&quot; operator is the right way to use in the example. If you are going for the condition of checking whether one condition would turn to false to end the loop the correct operator would be the &quot;&#124;&#124;&quot;. 

I also based this using the Psuedo Code style you mentioned in the previous chapters. I will quote the above comment &quot;the loop will keep going until either the player &quot;&quot;OR&quot;&quot; the aliens have run out of lives/ships&quot;. But again, correct me if I&#039;m barking off the wrong tree.

Great tutorial by the way! keep it up!]]></description>
		<content:encoded><![CDATA[<p>Hi John,</p>
<p>Sorry, but correct me if I&#8217;m wrong but I think Lux comment that you should use the &#8220;||&#8221; operator is the right way to use in the example. If you are going for the condition of checking whether one condition would turn to false to end the loop the correct operator would be the &#8220;||&#8221;. </p>
<p>I also based this using the Psuedo Code style you mentioned in the previous chapters. I will quote the above comment &#8220;the loop will keep going until either the player &#8220;&#8221;OR&#8221;&#8221; the aliens have run out of lives/ships&#8221;. But again, correct me if I&#8217;m barking off the wrong tree.</p>
<p>Great tutorial by the way! keep it up!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John Horton</title>
		<link>https://gamecodeschool.com/java/looping-our-game-code/#comment-3548</link>
		<dc:creator><![CDATA[John Horton]]></dc:creator>
		<pubDate>Thu, 08 Dec 2016 12:46:01 +0000</pubDate>
		<guid isPermaLink="false">http://gamecodeschool.com/?p=11559#comment-3548</guid>
		<description><![CDATA[Part 3 is a different subject unless you have found a bad link perhaps?]]></description>
		<content:encoded><![CDATA[<p>Part 3 is a different subject unless you have found a bad link perhaps?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: George</title>
		<link>https://gamecodeschool.com/java/looping-our-game-code/#comment-3539</link>
		<dc:creator><![CDATA[George]]></dc:creator>
		<pubDate>Wed, 07 Dec 2016 08:00:07 +0000</pubDate>
		<guid isPermaLink="false">http://gamecodeschool.com/?p=11559#comment-3539</guid>
		<description><![CDATA[is this not the same as part 3?]]></description>
		<content:encoded><![CDATA[<p>is this not the same as part 3?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: John Horton</title>
		<link>https://gamecodeschool.com/java/looping-our-game-code/#comment-3486</link>
		<dc:creator><![CDATA[John Horton]]></dc:creator>
		<pubDate>Thu, 01 Dec 2016 14:48:14 +0000</pubDate>
		<guid isPermaLink="false">http://gamecodeschool.com/?p=11559#comment-3486</guid>
		<description><![CDATA[Hi Blandon,

Thanks for your message. The i is a variable. You can read about them &lt;a href=&quot;http://gamecodeschool.com/java/game-variables/&quot; rel=&quot;nofollow&quot;&gt;here&lt;/a&gt;. I won&#039;t be able to give you any tips on the other tutorial because I am not familiar with it, unfortunately. As to you other question, I don&#039;t think there is any &quot;best&quot; language/platform/engine but there is usually one which is most appropriate for you and your situation. To try and work out what is right for you take a look at this &lt;a href=&quot;http://gamecodeschool.com/blog/making-games-where-do-i-start/&quot; rel=&quot;nofollow&quot;&gt;where do I start tutorial&lt;/a&gt;.]]></description>
		<content:encoded><![CDATA[<p>Hi Blandon,</p>
<p>Thanks for your message. The i is a variable. You can read about them <a href="http://gamecodeschool.com/java/game-variables/" rel="nofollow">here</a>. I won&#8217;t be able to give you any tips on the other tutorial because I am not familiar with it, unfortunately. As to you other question, I don&#8217;t think there is any &#8220;best&#8221; language/platform/engine but there is usually one which is most appropriate for you and your situation. To try and work out what is right for you take a look at this <a href="http://gamecodeschool.com/blog/making-games-where-do-i-start/" rel="nofollow">where do I start tutorial</a>.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
