physics.addBody doesn't allow static with circles

I was creating some static circles with physics.addBody

This doesn’t work:

[lua] physics.addBody( circle, “static”, { density=0.9, friction=0.3, bounce=0.3, radius=34} )[/lua]

This does, but takes two lines:
[lua] physics.addBody( circle, { density=0.9, friction=0.3, bounce=0.3, radius=34} )
circle1.bodyType = “static”[/lua]
I searched the bug tracker and didn’t see this issue. Is this a known issue? Small problem I know… :slight_smile:

Regards,

Mike Chapman
[import]uid: 9827 topic_id: 2606 reply_id: 302606[/import]

The first way is no longer supported. From the online docs:
“In Alpha 2, this attribute is no longer part of the body element definition, and will be ignored if specified in the above format.”

https://developer.anscamobile.com/content/game-edition-physics-bodies

In your example you are creating “circle” and adding the bodyType to “circle1”. I assume this is a typo in the forum post.

-Tom [import]uid: 7559 topic_id: 2606 reply_id: 7435[/import]

Yes that was a typo. Thanks for the clarification. I will check the doc again. It works just figured I would post and save someone else the trouble of figuring it out.
[import]uid: 9827 topic_id: 2606 reply_id: 7444[/import]