Magnus Pettersson Posted December 16, 2009 Share Posted December 16, 2009 Hello! I want to use buttons in my HDA to do some tasks but im pretty lost in hscript and python world yet. What i want is to get, and set channel values when i press a button. I have used "opparm . fluidboxSize[0] ( $sizeX )" to set a parameter to some random value when pressing the button, but i have trouble getting a value from another channel somewhere else to put in the $sizeX variable. i tried doing set sizeX = `run("opparm -d . testchannelx")` but that returns: opparm /obj/testpath testchannelx ( 10 ) how do i only get the value from a channel? i tried opdigits expression but that doesn't work if its float then it only returns the decimals. if you know how to do this in python too would be cool to know Cheers /Magnus Quote Link to comment Share on other sites More sharing options...
edward Posted December 17, 2009 Share Posted December 17, 2009 ch() expression Quote Link to comment Share on other sites More sharing options...
Magnus Pettersson Posted December 17, 2009 Author Share Posted December 17, 2009 ohhhh i will put myself into the stupid corner for a while! i must have missed the backticks `` when testing it the first time around thanks Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.