예제 #1
0
 public void InitializeColours(ColourData colourData)
 {
     this.colourData = colourData;
     Debug.Log("Init player colours");
     GetComponents();
     currentColourIndex   = (uint)Random.Range(0, colourData.size);
     spriteRenderer.color = colourData.GetColourFromIndex(currentColourIndex);
 }
예제 #2
0
 public void ChangeColour()
 {
     currentColourIndex   = colourData.GetRandomColourIndex(currentColourIndex);
     spriteRenderer.color = colourData.GetColourFromIndex(currentColourIndex);
 }
 public void InitializeColours(ColourData colourData)
 {
     this.colourData = colourData;
     GetComponents();
     spriteRenderer.color = colourData.GetColourFromIndex(colourIndex);
 }