Sprite:getChildrenAtPoint: Difference between revisions

From GiderosMobile
language
m Text replacement - "<source" to "<syntaxhighlight"
Line 5: Line 5:
=== Description ===
=== Description ===
Returns the children Sprites that correspond to the given screen coordinates.
Returns the children Sprites that correspond to the given screen coordinates.
<source lang="lua">
<syntaxhighlight lang="lua">
(table) = Sprite:getChildrenAtPoint(x,y,visible,nosubs)
(table) = Sprite:getChildrenAtPoint(x,y,visible,nosubs)
</source>
</source>

Revision as of 13:31, 13 July 2023

Available since: Gideros 2018.12.1
Class: Sprite

Description

Returns the children Sprites that correspond to the given screen coordinates. <syntaxhighlight lang="lua"> (table) = Sprite:getChildrenAtPoint(x,y,visible,nosubs) </source>

Parameters

x: (number) x coordinate in global space
y: (number) y coordinate in global space
visible: (boolean) only report visible sprites
nosubs: (boolean) don't report children of this sprite children

Return values

Returns (table) a list of Sprites that were found at that screen location