{ if ( ch("../my_parameter/group1") == "none" ) { return 0; } }
And this is the error I get:
Error: Unable to evaluate expression (Bad data type for function or operation (/obj/geo1/HDA_1/switch1/input)).
How can I compare two strings in Hscript?
{ if ( ch("../my_parameter/group1") == "none" ) { return 0; } }
Error: Unable to evaluate expression (Bad data type for function or operation (/obj/geo1/HDA_1/switch1/input)).
{ if(strcmp(chs("../random_node/geotype"), "poly")==0) { return 1; } }
tamteThanks!
you have to use strcmp(){ if(strcmp(chs("../random_node/geotype"), "poly")==0) { return 1; } }
and not sure but the values you are refering here (“none”) or in your file (“primitive”) are not valid for group geotype parm, so it would never switch to one anyway
the valid values are:
'all', ‘bezierc’, ‘bezier’, ‘mesh’, ‘circle’, ‘MetaSQuad’, ‘meta’, ‘nurbc’, ‘nurb’, ‘PackedAgent’, ‘AlembicRef’, ‘PackedDisk’, ‘PackedFragment’, ‘PackedGeometry’, ‘part’, ‘PasteSurf’, ‘poly’, ‘polysoup’, ‘sphere’, ‘tetrahedron’, ‘trifan’, ‘tristrip’, ‘tribez’, ‘tube’, ‘vdb’, ‘volume’