Difference between revisions of "Sprite:getSize"

From GiderosMobile
m (Text replacement - "<source" to "<syntaxhighlight")
m (Text replacement - "</source>" to "</syntaxhighlight>")
 
Line 7: Line 7:
 
<syntaxhighlight lang="lua">
 
<syntaxhighlight lang="lua">
 
(number), (number) = Sprite:getSize()
 
(number), (number) = Sprite:getSize()
</source>
+
</syntaxhighlight>
  
 
=== Return values ===
 
=== Return values ===

Latest revision as of 14:33, 13 July 2023

Available since: Gideros 2021.10
Class: Sprite

Description

Returns the width and height of the sprite in pixels. The width and height are calculated based on the bounds of the content of the sprite.

(number), (number) = Sprite:getSize()

Return values

Returns (number) the sprite width
Returns (number) the sprite height