wood burning stoves 2.0*
The moose likes Java in General and the fly likes Please help me in robocode java wave surfing Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Java in General
Bookmark "Please help me in robocode java wave surfing" Watch "Please help me in robocode java wave surfing" New topic
Author

Please help me in robocode java wave surfing

jhumar regaspi
Greenhorn

Joined: Dec 15, 2012
Posts: 1
This is the code:



This is the error:

1. WARNING in C:\robocode\robots\Robot\Noblesse.java (at line 32)
_enemyWaves = new ArrayList();
^^^^^^^^^
ArrayList is a raw type. References to generic type ArrayList<E> should be parameterized
----------
2. WARNING in C:\robocode\robots\Robot\Noblesse.java (at line 33)
_surfDirections = new ArrayList();
^^^^^^^^^
ArrayList is a raw type. References to generic type ArrayList<E> should be parameterized
----------
3. WARNING in C:\robocode\robots\Robot\Noblesse.java (at line 34)
_surfAbsBearings = new ArrayList();
^^^^^^^^^
ArrayList is a raw type. References to generic type ArrayList<E> should be parameterized
----------
4. ERROR in C:\robocode\robots\Robot\Noblesse.java (at line 40)
turnRadarRightRadians(Double.POSITIVE_INFINITY);
^^^^^^^^^^^^^^^^^^^^^
The method turnRadarRightRadians(double) is undefined for the type Noblesse
----------
4 problems (1 error, 3 warnings)
Compile Failed (-1)

can somebody help me.. I'm only a beginner hoping to become pro programmer..



fred rosenberger
lowercase baba
Bartender

Joined: Oct 02, 2003
Posts: 11479
    
  16

The error message tells you exactly what is wrong.

4. ERROR in C:\robocode\robots\Robot\Noblesse.java (at line 40)
turnRadarRightRadians(Double.POSITIVE_INFINITY);
^^^^^^^^^^^^^^^^^^^^^
The method turnRadarRightRadians(double) is undefined for the type Noblesse

There is no method called "turnRadarRightRadians" that takes a double. There are two ways to fix it:

1) Don't call the (non-existent) method
2) Define the method.


There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Please help me in robocode java wave surfing