Difference between revisions of "Sprite:hitTestPoint"

From GiderosMobile
Line 2: Line 2:
 
'''Available since:''' Gideros 2011.6<br/>
 
'''Available since:''' Gideros 2011.6<br/>
 
=== Description ===
 
=== Description ===
<br />
+
<translate><br />
 
Checks whether the given coordinates (in global coordinate system) is in bounds of the sprite.<br />
 
Checks whether the given coordinates (in global coordinate system) is in bounds of the sprite.<br />
 
<br />
 
<br />
<br />
+
<br /></translate>
 
<source lang="lua">
 
<source lang="lua">
 
(bool) = Sprite:hitTestPoint(x,y,shapeFlag)
 
(bool) = Sprite:hitTestPoint(x,y,shapeFlag)
 
</source>
 
</source>
 
=== Parameters ===
 
=== Parameters ===
'''x''': (number) <br/>
+
'''x''': (number) <translate></translate> <br/>
'''y''': (number) <br/>
+
'''y''': (number) <translate></translate> <br/>
'''shapeFlag''': (bool) Take clipping/masking into consideration when testing hit point '''optional'''<br/>
+
'''shapeFlag''': (bool) <translate>Take clipping/masking into consideration when testing hit point</translate> '''optional'''<br/>
 
=== Return values ===
 
=== Return values ===
'''Returns''' (bool) `true` if the given global coordinates are in bounds of the sprite, `false` otherwise.<br/>
+
'''Returns''' (bool) <translate>[[[true` if the given global coordinates are in bounds of the sprite, `false]]] otherwise.</translate><br/>

Revision as of 13:33, 23 August 2018

Available since: Gideros 2011.6

Description


Checks whether the given coordinates (in global coordinate system) is in bounds of the sprite.


(bool) = Sprite:hitTestPoint(x,y,shapeFlag)

Parameters

x: (number)
y: (number)
shapeFlag: (bool) Take clipping/masking into consideration when testing hit point optional

Return values

Returns (bool) [[[true` if the given global coordinates are in bounds of the sprite, `false]]] otherwise.