THE POST BELOW IS MORE THAN 5 YEARS OLD. RELATED SUPPORT INFORMATION MIGHT BE OUTDATED OR DEPRECATED
On 29/06/2011 at 12:50, xxxxxxxx wrote:
hey guys! had another question.
is it possible to clone all the data from one spline object into another(assuming they are both the same exact type of spline object)? in my project i have a slot to drag a spline into a user data link field. then within python, i am getting the ID of that type of spline and creating a new spline based on the original spline's ID, but all of the settings are new(which is to be expected) and rather than program the settings for every type of spline i was hoping i could just use a base container to Transfer settings to the new spline. I am halfway there, but now i am not sure how to transfer a base container full of the main spline's settings into the new spline. help? code below...
#---------------------------------------------
sptype = baseSpline.GetType() #baseSpline is the original spline from the User Data Link Field
spCore = c4d.BaseObject(sptype) #create a new spline based on the original spline's type
#--------------------------------------------
P.S. i am used to just using get clone is this case, but i doesn't seem to be working with my code. as soon as I use get clone it fails to keep my c4d base object alive. plus i would really just like to know how to do this. Thanks again guys!