Created
September 30, 2017 20:37
-
-
Save unity3dcollege/e76f0c0ed9fda9b15046eec246f34d2e to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[System.Serializable] | |
public struct RangedFloat | |
{ | |
public float minValue; | |
public float maxValue; | |
public RangedFloat(float minValue, float maxValue) | |
{ | |
this.minValue = minValue; | |
this.maxValue = maxValue; | |
} | |
public float RandomInRange() | |
{ | |
return UnityEngine.Random.Range(minValue, maxValue); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment