IsCollisionTest
From MaratisWiki
(Difference between revisions)
Dahnielson (Talk | contribs) m |
Dahnielson (Talk | contribs) m |
||
Line 2: | Line 2: | ||
Detect if an object is colliding with something. | Detect if an object is colliding with something. | ||
+ | |||
+ | {{lua-function-param|object|object to operate on}} | ||
'''Example:''' Will display Collision! in maratis console window if there's a collision for object1. | '''Example:''' Will display Collision! in maratis console window if there's a collision for object1. |
Latest revision as of 01:27, 9 February 2014
isCollisionTest(object)
Detect if an object is colliding with something.
-
object
: object to operate on
Example: Will display Collision! in maratis console window if there's a collision for object1.
object1 = getObject("object1") function onSceneUpdate() if isCollisionTest(object1) then print("Collision!") end end