Playmaker Forum
PlayMaker Help & Tips => PlayMaker Help => Topic started by: 4ppleseed on January 20, 2014, 04:53:00 PM
-
Hi guys, lets say I have a variable in a script called amount:
[Range(100,20000)]
public float
amount = 100;
I've set a range for this float from 100 to 20000.
What I want to do is rotate an object (like a volume dial on a HiFi) so when the object is at 20 degrees it tells the script's amount variable to be at 10 and when the object is rotated to 340 degrees its at the top of the range at 20000.
I have no idea how to set this up in Playmaker :o
Thanks
-
Hi,
you should use this action ( float remap or cross multiplication)
http://hutonggames.com/playmakerforum/index.php?topic=5122.msg24311#msg24311
If you are having trouble with this let me know.
Bye,
Jean