I'm building a 2D game where you have to swipe upwards on a phone to grow a plant from where you touch. I have about 4 animations to include and I want them to generate randomly with each tap. I have them changing colour randomly but I have no idea how to get them rendering randomly! HELP!
Add public List<Sprite> AllSprites to your class so you can populate it in the Editor then swap the sprites out at random public List<Sprite> AllSprites; // later on inside your logic SpriteRenderer sr = GetComponent<SpriteRenderer>(); if (sr) sr.sprite = AllSprites[Random.Range(0, AllSprites.Count)];