So, i'm working on a school project and i want to implement a mechanic allowing a randomly moved actor to turn at a specific point, if he reaches it.
if(actor at specific coordinates, for example x=500, y=400) //here lies my problem
{
if(Greenfoot.getRandomNumber(1) == 1)
setRotation(270);
else
setRotation(90);
}

