Hey again devs,
i have a quick question as it may help me in what i’m trying to achieve here.
Basically let’s say you have some type of value that can increase and decrease at a minimum of 0 and 1.
Now if you would set for example a part’s Transparency to this value it would be transparent at 1 and visible at 0.
Would it be possible to reverse this math? What i mean with reverse is if the value is at 0 the part would be transparent and if its at 1 then it would be visible.
I’m not talking about if statements by the way. As i would like the number to also go in between 0 and 1.
From 0 to 1, to be more specific i am trying to match the PlaybackLoudness of a sound to the TextTransparency. I just realized that the PlaybackLoudness will actually end up as 0, so the TextTransparency would just be visible.
What if, lets say I’m trying to make an ammo counter and as you loose ammo the image becomes more transparent/invisible.
I have a max ammo count and a current ammo count
ammoIcon.ImageTransparency = currentAmmo/maxAmmo
but this makes the image transparent at the start and makes it less transparent. I’m aware as to why but I need to know how to make it do the opposite.