Quick Links: Download Gideros Studio | Gideros Documentation | Gideros community chat | DONATE
Correct format for vertices argument to b2.Polygon:set() — Gideros Forum

Correct format for vertices argument to b2.Polygon:set()

ndossndoss Guru
edited November 2011 in Bugs and issues

I can't figure out the correct format for the vertices argument to b2.Polygon:set().

p = b2.Polygon.new()
p:set(v)

I looked through the examples but I can't find an example. I've tried numerous things:

1. v = { x={1,2,3}, y={5,6,7} }
2. v = { 1,4, 2,6, 3,7 }
3. v = { {1,4}, {2,6}, {3,7} }

Any hints?

Thanks,

--ND

Comments

Sign In or Register to comment.