A place to discuss everything related to Newton Dynamics.
Moderators: Sascha Willems, walaber
by FSA » Fri May 25, 2012 1:23 pm
Hello.
I want to copy a NewtonBody*.
But if I copy a pointer and relaese the original NewtonBody, that's not good ^^
Like this:
[CPP]
NewtonBody* body1 = CreateBody(...);
NewtonBody* body2 = body1;
RelaeseBody(body1);
// body2 is now "empty"
[/CPP]
So how can i copy a NewtonBody(Pointer) and have an second Newton Body? memcpy don't work

Tank you.
-

FSA
-
- Posts: 322
- Joined: Wed Dec 21, 2011 9:47 am
by Julio Jerez » Fri May 25, 2012 10:52 pm
you can not really copy a newton body top another, you nee to us Get abd Set funtion to make to create a new one.
-
Julio Jerez
- Moderator

-
- Posts: 12426
- Joined: Sun Sep 14, 2003 2:18 pm
- Location: Los Angeles
-
Return to General Discussion
Who is online
Users browsing this forum: No registered users and 1 guest