ch.sahits.game.graphic.display.util
Class ClickableOffsetPolygons
java.lang.Object
ch.sahits.game.graphic.display.util.ClickablePolygons
ch.sahits.game.graphic.display.util.ClickableOffsetPolygons
public class ClickableOffsetPolygons
- extends ClickablePolygons
This specialisation of the ClickablePolygons class provides
a test method for a given Y-Offset. The polygons are defined by forms
on an image. The image may however be moved by an offset in the y direction.
This offset must be considered when checking against the polygons.
- Author:
- Andi Hotz, (c) Sahits GmbH, 2011
Created on Dec 19, 2011
|
Method Summary |
void |
testAndExecute(Point p,
int yOffset)
Find the polygon that contains the point and if such a polygon
exists execute its action |
ClickableOffsetPolygons
public ClickableOffsetPolygons()
testAndExecute
public void testAndExecute(Point p,
int yOffset)
- Find the polygon that contains the point and if such a polygon
exists execute its action
- Parameters:
p - coordinates clicked on the screenyOffset - offset the underling image is scrolled in y direction
Copyright © 2011-2012 Sahits GmbH. All Rights Reserved.