Naming conventions and errors?

Hi all,

There is a strange error I’m facing that sometimes pop up, other times it doesn’t, connected to naming NodePaths. Here it is:

:pgraph(error): Invalid type name: 44$176$72place_block
:pgraph(error): Invalid type name: 40$176$72place_block
:pgraph(error): Invalid type name: 36$176$72place_block
:pgraph(error): Invalid type name: 36$176$68place_block
:pgraph(error): Invalid type name: 36$176$64place_block
:pgraph(error): Invalid type name: 36$176$60place_block
:pgraph(error): Invalid type name: 36$176$56place_block
:pgraph(error): Invalid type name: 36$172$56place_block
:pgraph(error): Invalid type name: 36$172$60place_block
:pgraph(error): Invalid type name: 36$172$64place_block
:pgraph(error): Invalid type name: 36$172$68place_block
:pgraph(error): Invalid type name: 40$172$60place_block
:pgraph(error): Invalid type name: 44$172$60place_block
:pgraph(error): Invalid type name: 44$172$64place_block
:pgraph(error): Invalid type name: 44$172$68place_block
:pgraph(error): Invalid type name: 44$172$72place_block
:pgraph(error): Invalid type name: 40$172$72place_block
:pgraph(error): Invalid type name: 36$172$72place_block

So, what’s the issue here? Is there a naming convention to follow when setting the names of nodepaths? Can anyone kindly point me to information regarding this, or explain it?

EDIT
It seems that if the name starts with the negative sign, this error is raised? E.g.:

np.setName("-44$72$176place_block")

In some cases, adding some other character or string before the minus sign seems to make it go away.
Thanks in advance.

That does seem to correlate with the syntax of Searching the Scene Graph — Panda3D Manual

1 Like

Indeed: It may be that some search of the scene-graph is taking place (either in your own code or within the engine), and when your node-name appears in that search, the leading “-” character results in the find-algorithm treating it as a search for a type of node.

1 Like