How to give physicbody a texture?

The body created by physic api is invisiable.Can anyone helps?

Codea’s Physics API creates logical objects in 2D space that behave in a way consistent with the laws of physics, as time passes.

You have to write separate code to translate those logical objects into graphics on the Viewer. See the Physics Lab example project, which is written up on the Codea wiki here.

You may find this discussion here of use, too.

You can look at how spacemonkey does it in his great program b’boucing balls’