I'm working on a scenario similar to the ants scenario from chapter 9 in the Intro to programming book... In this scenario there are ants coming out of an anthill, and anteaters coming out of a cave. The anteaters wonder around the world and if they come in conctact with an ant, it is suppose to "eat" it, and thus the ant is removed from the world... In the anteater class code, I had the method where it checks for intersecting objects (ant.class) and if !=null, removeObject(this). However it doesn't compile... I've tried replacing this with ant, Ant, Ant.class... none seem to work, the error message is "cant find variable removeObject". Why is this? any tips?
THANKS!