***modify game class*** *****for reference***** Replace the enemy1, enemy2 and e
ID: 3644527 • Letter: #
Question
***modify game class***
*****for reference*****
Replace the enemy1, enemy2 and enemy3 fields by a single array called enemies. Throughout your Game, each time you refer to one of the fields enemy1, enemy2 or enemy3, replace that reference to the field by a reference to a particular position in the enemies array. For example, whenever you refer to enemy1, you should refer to enemies[0] instead. In order to avoid a NullPointerException, you must also create the enemies array in the constructor before you attempt to store enemies into it.Explanation / Answer
question is not clear please give me the clear question so that anyone i can answer
Related Questions
Navigate
Integrity-first tutoring: explanations and feedback only — we do not complete graded work. Learn more.