playMaker

Author Topic: How to convert int or float to get percent ?  (Read 2262 times)

blackant

  • Hero Member
  • *****
  • Posts: 521
  • http://blackantmaster.com
    • blackantmaster.com
How to convert int or float to get percent ?
« on: October 27, 2014, 04:50:20 AM »
Hi,

i would like to create a GUI color variable wich will be modified depending of the Ercentage of a defined value.

to be more precise, on a Shield Icon, set to green when 100% of life to red when 0% of life

jeanfabre

  • Administrator
  • Hero Member
  • *****
  • Posts: 15500
  • Official Playmaker Support
Re: How to convert int or float to get percent ?
« Reply #1 on: October 28, 2014, 01:43:59 AM »
Hi,

It's explained in the thread below, and there is an action as well, called "float remap", that you can find on the ecosystem as well as on the thread:

http://hutonggames.com/playmakerforum/index.php?topic=5122.msg24311#msg24311

Bye,

 Jean