package greenfoot.gui.input.mouse;
import greenfoot.Actor;
import threadchecker.OnThread;
import threadchecker.Tag;
| Interface for locating actors and coordinates in the world.
|
| @author Poul Henriksen
|
public interface WorldLocator
{
| Gets the top most actor at the given location.
| @param worldPixelPositionX The X pixel position in the world (not cell position)
| @param worldPixelPositionY The Y pixel position in the world (not cell position)
| @return The top most actor, or null if no actor.
|
@OnThread(Tag.Simulation)
public Actor getTopMostActorAt(int worldPixelPositionX, int worldPixelPositionY);
| Translates the coordinates from the given source component into some other coordinate system.
| @param worldPixelPositionX The X pixel position in the world (not cell position)
| @return The new x-coordinate
|
public int getTranslatedX(int worldPixelPositionX);
| Translates the coordinates from the given source component into some other coordinate system.
| @param worldPixelPositionY The Y pixel position in the world (not cell position)
| @return The new y-coordinate
|
public int getTranslatedY(int worldPixelPositionY);
}
top,
use,
map,
interface WorldLocator
. getTopMostActorAt
. getTranslatedX
. getTranslatedY
20 neLoCode
+ 12 LoComm