Strange copyTo behavior

Return to Scripting Issues

Strange copyTo behavior

Postby mavasher » Mon May 28, 2012 1:37 pm

Hello everyone. I've come across some strange behavior when I use the copyTo command on a nodepath.

Relevant code:
Code: Select all
self.copynode = map.mapcentroid.copyTo(render)
map.mapcentroid.hide()
self.copynode.show()
            

I then move the copynode to a new location. The end result is that I have two objects visible in the world. I've tried hiding the original (mapcentroid) and hiding the copy but I still have an additional model in the world. I don't seem to be able to get a handle on this extra visible geometry so I can't delete it.

To be clear, if I don't hide the original or copy, there are three visible objects in the world.
On Panda3DProjects.com:
http://www.p3dp.com/?mavasher
User avatar
mavasher
 
Posts: 294
Joined: Thu Feb 08, 2007 10:32 am
Location: Texas

Postby ynjh_jo » Tue May 29, 2012 6:01 am

Maybe you accidentally did it twice ?
Try adding a print statement to track it down.
http://ynjh.panda3dprojects.com | http://ynjh.p3dp.com
Intel P4Prescott 2.8GHz HT | ATI Radeon HD4670 1GB GDDR3
User avatar
ynjh_jo
 
Posts: 1795
Joined: Tue Apr 18, 2006 12:41 am
Location: Malang, Indonesia


Return to Scripting Issues

Who is online

Users browsing this forum: No registered users and 0 guests