...
private ArrayList<Ufo> ufos = new ArrayList<>();
private ArrayList<Rocket> rockets = new ArrayList<>();
private ArrayList<Bomb> bombs = new ArrayList<>();
...
public void moveAllItems() {
// Get a list of all objects in the game and call the move() method on each of them.
...
}
/**
* The method returns a single list that contains all objects in the game
*/
public List<BaseObject> getAllItems() {
// You need to create a new list and put all the game objects into it.
...
}
code looks legit but fails
Resolved
Comments (5)
- Popular
- New
- Old
You must be signed in to leave a comment
Djole
29 May 2019, 09:43
i copied spaceship file from javarush you gave us for this task. totally forgot to make that change :) thanks
0
Roman
29 May 2019, 05:59solution
https://codegym.cc/help/3152 - the same problem :)
why did you return ArrayList ?
+3
Djole
29 May 2019, 09:44
i copied spaceship file from javarush you gave us for this task. totally forgot to make that change :) thanks
0
Roman
29 May 2019, 10:05
thanks, we'll fix this
be careful in part 18 ;)
0
Djole
29 May 2019, 12:17
yep, thanks for reminding me. i would have forgotten again :)
0