PDA

View Full Version : How to update a slider value component from Girder?



jackdeth999
March 29th, 2009, 12:01 AM
Is there a way I can have Girder send a value to NetRemote and have a slider component update with that new value?

I know how I can have the slider component register a variable with Girder, but how can I go the other way?

Thanks,
Ken

Rob H
March 29th, 2009, 07:57 AM
You just need to send a value to that same variable.

If you're doing this in Lua then use NetRemote.SetVariable, if it's from a GML then use a NetRemote|Set variable (All) action.

jackdeth999
March 29th, 2009, 01:52 PM
I tried that, but it does not seem to work.

What variable name should I use in the NetRemote.SetVariable command?

I have a slider button variable called "Lexicon\Volume". If I update that value, or "<^^>\Volume", or just "Volume", the slider does not update.

Is there some special format I should use?

Rob H
March 30th, 2009, 12:10 AM
If you're doing that from Lua code then you'll need to double up the backslashes ie "Lexicon\\Volume" or use [[ and ]] to delimit the string ie [[Lexicon\Volume]]

jackdeth999
March 30th, 2009, 10:14 AM
That did it! Thanks!

Ken