hi im trynna use a function defined in the class Level2
Level2
public int score = 0;
public void increaseScore()
{
score++;
}
Fish
public void act()
{
collectStarfish();
}
public void collectStarfish(){
Actor Starfish;
Starfish = getOneObjectAtOffset(0,0, Starfish.class);
if (Starfish!=null){
World world;
world = getWorld();
world.removeObject(Starfish);
increaseScore();
}
}
doing this, it says that the method "increaseScore" cannot be found.
how can i fix this?
thanks