How to make a character of a random color each time the game starts

Hello everyone. I’m not exactly sure how to approach this as I’m a noob. I’m making a third person shooter and I’m using the standard third person character model, as it works pretty well for my game.

However, I want the character to have a random color every time I start the game. I would also like for a prefab which the shooting script shoots out of the character’s body, to take the color of the character. That’s pretty much it. Can you please help me out with that? Thank you in advance!

There is many ways to do this.

One way is to use Random.Range(x, x); in the Start function to assign a int variable when your game and script starts.

Then in the Update function check the variable and decide color depending on int value.