I really stuck at implementing wrapping world.
My idea is to use object wich contains NSMutableArray of its bodies (which can be up to 4 elements). When i create the object i add initial body to the array simultaneously with adding it to the world.
Then when some conditions occur i add one more body with modified position. But this body exists only as element of the array.
I can't understand how to properly create copy of body from an element of the array in the world if i must use safe adding as safe removing (outside of world->Step())?
Any clues?
My idea is to use object wich contains NSMutableArray of its bodies (which can be up to 4 elements). When i create the object i add initial body to the array simultaneously with adding it to the world.
Then when some conditions occur i add one more body with modified position. But this body exists only as element of the array.
I can't understand how to properly create copy of body from an element of the array in the world if i must use safe adding as safe removing (outside of world->Step())?
Any clues?