R3d.Body:getTransform: Difference between revisions

From GiderosMobile
Created page with "'''Available since:''' Gideros 2019.10<br/> '''Class:''' R3d.Body<br/> === Description === Gets the body transform. <source lang="lua"> (matrix) = r3d.Body:getTransform()..."
 
No edit summary
 
(2 intermediate revisions by one other user not shown)
Line 4: Line 4:
=== Description ===
=== Description ===
Gets the body transform.
Gets the body transform.
<source lang="lua">
<syntaxhighlight lang="lua">
(matrix) = r3d.Body:getTransform()
(matrix) = r3d.Body:getTransform()
</source>
</syntaxhighlight>


=== Return values ===
=== Return values ===
Line 12: Line 12:


=== Example ===
=== Example ===
<source lang="lua">
<syntaxhighlight lang="lua">
</source>
local m1 = cube.body:getTransform()
cube:setMatrix(m1) -- aligns the cube shape to its body transform
</syntaxhighlight>


{{R3d.Body}}
{{R3d.Body}}

Latest revision as of 08:19, 18 December 2025