Python in Parameter problem

   2872   1   1
User Avatar
Member
68 posts
Joined: 5月 2013
Offline
Well now if I put…
hou.node(“.”).digitsInName()
I'll see a “1” assuming the node's name is say object1 and the paramater is set to evaluate as Python script not houdini script.
but if I put…
hn = hou.node(“.”)
hn.digitsInName()
I get a zero “0”
if I wrap it in squiggly brackets or I put semi colons at the end or anything it never works in a multiline way?
I also can't seem to integrate it into a hscript maybe with back ticks or something? eval? no I can't find a way?

I'm totally lost here, please help.
User Avatar
Member
68 posts
Joined: 5月 2013
Offline
In HScript I finally found this
opdigits(opname(“.”))
will get a way to the “opnum”.
Still Multiline Python doesn't seem to work in expressions, at least the way I expected.
  • Quick Links