Mathf.Pow alternative function?
Hello there! I have a problem with the Mathf.Pow-Function of the UnityEngine, cause it just allows float values and no double values. But for my program where I can buy Items i need functions like this: f(x):= 100+1.25^x And would be the best if x can be a double value in this function aswell. Is there any way to get something like this? I just wonder that the Unity-Math-Function cant work with double values like the usual c# do.
Would be happy for any solutions and ty for reading my bad english.
Answer by TreyH · Mar 15, 2016 at 04:21 PM
System.Math.Pow()
https://msdn.microsoft.com/en-us/library/system.math.pow(v=vs.110).aspx
Well I was blind, forgot the "System." ty!
System.$$anonymous$$ath.Pow(1.15, x);
Your answer
Follow this Question
Related Questions
Get angle of line based on worldspace 1 Answer
Slowly increase or decrease between two int values? 0 Answers
Moving a GameObject in an Ellipsoid path 1 Answer
How do I convert a number and a range to another directly proportional number and range? 4 Answers
Mathf.Approximately, how to apply this to my script? 1 Answer