Difference between revisions of "B2.World:setDebugDraw"
From GiderosMobile
| Line 2: | Line 2: | ||
| '''Available since:''' Gideros 2011.6<br/> | '''Available since:''' Gideros 2011.6<br/> | ||
| === Description === | === Description === | ||
| − | <br /> | + | <translate><br /> | 
| Registers a b2.DebugDraw instance for debug drawing.<br /> | Registers a b2.DebugDraw instance for debug drawing.<br /> | ||
| − | <br /> | + | <br /></translate> | 
| <source lang="lua"> | <source lang="lua"> | ||
|   b2.World:setDebugDraw() |   b2.World:setDebugDraw() | ||
| Line 10: | Line 10: | ||
| === Examples === | === Examples === | ||
| '''Example'''<br/> | '''Example'''<br/> | ||
| − | <source lang="lua">local debugDraw = b2.DebugDraw.new() | + | <source lang="lua">local debugDraw = b2.DebugDraw.new() | 
| − | world:setDebugDraw(debugDraw) | + | world:setDebugDraw(debugDraw) | 
| stage:addChild(debugDraw)</source> | stage:addChild(debugDraw)</source> | ||
Revision as of 13:33, 23 August 2018
Available since: Gideros 2011.6
Description
Registers a b2.DebugDraw instance for debug drawing.
 b2.World:setDebugDraw()
Examples
Example
local debugDraw = b2.DebugDraw.new()
world:setDebugDraw(debugDraw)
stage:addChild(debugDraw)
