CollisionTraverser - Wound me up to much!!!

I’ve tried to sort this out on my own and looking through the forum, but its wound me up to much!

basically i have collision nodes set up and what to add a transver node to the main character (ralph)

def setupCollisions(self):

      	# use an event collision handler (sends events on collisions)
	self.cHandler = CollisionHandlerEvent()
	# set the pattern for the event sent on collision
	# "enter" plus the name of the object collided into
	# make a traverser and make it the default traverser
	self.cTrav = CollisionTraverser()
	base.cTrav = self.cTrav

	# add a sphere around Ralph to collide with the lollipops
	# get the bounding sphere of Ralph
	bounds = self.Ralph.getChild(0).getBounds()
	center = bounds.getCenter()
	radius = bounds.getRadius()
	cSphere = CollisionSphere(center,radius)
	cNode = CollisionNode("Ralph")
        cNodePath = self.Ralph.attachNewNode(cNode)

        # add Ralphs's collision node to the traverser as a collider


	# traverser = CollisionTraverser('Ralph')
	# base.cTrav = traverser
	# traverser.addCollider(fromObject, handler)

	# add sphere around the lollipops to be collided into
	for target in self.targets:
		cSphere = CollisionSphere(Point3(0,0,15),15)
		cNode = CollisionNode("lollipop")
		cNodePath = target.attachNewNode(cNode)

        # end setupCollisions

And when i run it i get this error:

Warning: DirectNotify: category 'Interval' already exists
DirectStart: Starting the game.
Known pipe types:
(3 aux display modules not yet loaded.)
Traceback (most recent call last):
  File "", line 179, in ?
    w= World()
  File "", line 34, in __init__
  File "", line 155, in setupCollisions
TypeError: CollisionTraverser::add_collider() argument 1 must be NodePath, not C
Press any key to continue . . .

Any ideas??

i’ve looked through the manual and the forum and tried some of the suggestions but still can’t get it working.

Please Help!

Change the line




Super thats done the trick… bout the only thing i didn’t try!

1000 Thanks