• Post Reply Bookmark Topic Watch Topic
  • New Topic

Tank MiniGame  RSS feed

 
Greenhorn
Posts: 25
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Just posted this in the wrong forum so if anyone sees it there my apologies. Anyways, I am partially creating a tank minigame in which I need to use an autopilot mode. I have partially coded it but it does not work. The game has two walls that have holes to get through and it has a target you need to run into. Any help will be greatly appreciated. My code will be first, and the given code will be second.


all the code is obviously not here so if i left something important out please let me know. Thank you
 
Rhyeca Riley
Greenhorn
Posts: 25
1
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The program compiles and runs fine but the problem is it is not always getting through the walls, or getting the target. Sorry my post was a little vague on what the actual problem was.
 
Bartender
Posts: 2087
44
Firefox Browser IntelliJ IDE Java Linux Spring
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please read those two articles carefully.
https://coderanch.com/wiki/660352/Avoid-Equality-Operator
https://coderanch.com/wiki/659830/Strings-Bad

This will allow you to understand why this line is wrong.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!