Question by
Kaktuskage · Oct 24, 2015 at 09:51 PM ·
c#
How do I make a Random (YES OR NO) generator? in 2D
I do not understand how too get my main button to choice randomly ?
Comment
Best Answer
Answer by Paulo-Henrique025 · Oct 24, 2015 at 10:01 PM
Take a look at the Random.Range documentation.
string GetRandomAnswers()
{
return Random.Range(0,2) == 1 ? "yes": "no";
}
Your answer
Follow this Question
Related Questions
Unity is reseting Dictionary when game is playing 0 Answers
[Solved] How to Script a Camera That Follows the Player but Collides with the Edge of the Level 2 Answers
localscale not working 1 Answer
Camera Jitters When Displacing and Rotating Smoothly 0 Answers
My sprite disappears from the camera view after some time moving 5 Answers