Jump to content

Ramp value in HScript

Recommended Posts

float value = chramp("ramp",fit11(sin(@Time),0,1))*chf("amp");

this is what i would do in vex but i need to use it as a value for a node parameter. Is this possible in hscript?
i tried creating a string multiline vex parameter in the parameter interface and write this

float value = chramp("ramp",fit11(sin(@Time),0,1))*chf("amp");
return value;

then reference the result inside the parameter like chf("vex") or chs("vex") ? none of those would work ofcourse but i dont know what else to try

Any tips?

Link to comment
Share on other sites


You'll just need to create a "ramp" and "amp" parms (attached example)
Notice the extra 0 at the end of the chramp function, that's the first component since you can do vector ramps too

how do you find help about hscript?
Open a textport and search for ramp:

exhelp -k ramp 

Then get the docs about chramp

exhelp chramp



Link to comment
Share on other sites

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.

Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Create New...