Difference between revisions of "User talk:Urgood2"

From Robowiki
Jump to navigation Jump to search
Line 16: Line 16:
  
 
Thank you =) --[[User:Urgood2|-- Josh S]] 08:35, 24 April 2010 (UTC)
 
Thank you =) --[[User:Urgood2|-- Josh S]] 08:35, 24 April 2010 (UTC)
 +
 
==urgood2==
 
==urgood2==
--Newbie to Robocode
+
::Newbie to Robocode
  
 
I am currently learning Java.
 
I am currently learning Java.
Line 27: Line 28:
  
 
Finally got my WallAvoiderBot working. =) The angle adjusting part was testing for only heading 0...
 
Finally got my WallAvoiderBot working. =) The angle adjusting part was testing for only heading 0...
<code>  
+
<pre>  
 
//...
 
//...
 
double angle = 0;
 
double angle = 0;
 
while (!field.contains(wallStickEnd =  
 
while (!field.contains(wallStickEnd =  
project(myLocation, angle, WALL_STICK))) {
+
project(myLocation, <b>angle</b>, WALL_STICK))) {
 
angle += .1 * direction;
 
angle += .1 * direction;
 
}  
 
}  
</code>
+
</pre>
 
I was very frustrated about this, but I finally figured it out.. I replaced the bold part with <code>getHeadingRadians() + angle</code>.
 
I was very frustrated about this, but I finally figured it out.. I replaced the bold part with <code>getHeadingRadians() + angle</code>.
 
-[[User:Urgood2|-- Josh S]] 11:33, 26 April 2010 (UTC)
 
-[[User:Urgood2|-- Josh S]] 11:33, 26 April 2010 (UTC)

Revision as of 12:33, 26 April 2010

Welcome!

Hello, Urgood2, and welcome to RoboWiki! This place contains a wealth information about Robocode, from basic to more advanced. I hope you enjoy creating robots and being a robocoder!

If you are posting a comment on this wiki, please sign your messages using four tildes (--~~~~); this will automatically insert your username and the date stamp. If you are not familiar with MediaWiki, these links might help you out:

If you need help, check out the frequently asked questions or ask it on this page. Again, welcome!

—— RoboWiki Administrators

Welcome to the robowiki :) --Rednaxela 15:22, 23 April 2010 (UTC)

Thank you =) ---- Josh S 08:35, 24 April 2010 (UTC)

urgood2

Newbie to Robocode

I am currently learning Java. I haven't made any "good" robots yet.

Most of us started without a good bot in our sleeves. My first entrance, which defeated 7 others bots at work in melee, ended up on spot 285 out of 300. And see where I stand today. Just set your personal goal within reach and build up from there. Defeating (most of) the samplebots is a good start. Happy robocoding! --GrubbmGait 17:57, 25 April 2010 (UTC)

Well, that's encouraging! I hope I can start to get a grip on things sometime in the future.. ---- Josh S 11:33, 26 April 2010 (UTC)

Finally got my WallAvoiderBot working. =) The angle adjusting part was testing for only heading 0...

 
//...
double angle = 0;
while (!field.contains(wallStickEnd = 
				project(myLocation, <b>angle</b>, WALL_STICK))) {
				angle += .1 * direction;
} 

I was very frustrated about this, but I finally figured it out.. I replaced the bold part with getHeadingRadians() + angle. --- Josh S 11:33, 26 April 2010 (UTC)