Difference between revisions of "Sprite.contains"
Jump to navigation
Jump to search
ZachStrout (talk | contribs) (Created page with "<c>Sprite.contains</c> returns whether the sprite's world bounds contains the given x,y point (given in world coordinates). === Arguments === {| class="wikitable" |- ! Para...") |
|||
Line 1: | Line 1: | ||
− | <c>Sprite.contains</c> returns whether the sprite's world bounds contains the given x,y point | + | <c>[[Sprite]].contains</c> returns whether the sprite's world bounds contains the given x,y point |
(given in world coordinates). | (given in world coordinates). | ||
Latest revision as of 23:13, 12 April 2020
Sprite.contains
returns whether the sprite's world bounds contains the given x,y point
(given in world coordinates).
Arguments
Parameter Name | Type | Default Value | Meaning |
---|---|---|---|
x | number | 0 | horizontal position of point of interest |
y | number | 0 | vertical position of point of interest |
Usage Notes
This is just a shortcut for worldBounds.contains
.
Use of this requires first defining the localBounds.