Skip to content

Instantly share code, notes, and snippets.

Last active Jun 18, 2018
What would you like to do?
void RollADice(){
// 乱数の範囲指定で配列のインデックスを取得する
int index = Random.Range(0, dice.Length);
// サイコロの目を取得する
int pips = dice[index];
Debug.Log("サイコロの目は " + pips + " でした。");
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment