Question about random functions

Hi everyone,

i just want to ask something about RandomRange. Is it possible to call random functions?
I have 3 tipes of function in which i spawn diferent objects in precisely determined places. I did this because i want the player to have different game every time he wants to play.

When i write something like this:

 function Start(){
    
    random = Random.Range(Spawn1(), Spawn2(), Spawn3());
    }
    
    //And then i have those functions
    
    function Spawn1(){
    }
    
    function Spawn2(){
    }
    
    function Spawn3(){
    }

I don’t know how to write this properly or if this can work in any way.

Thanks, Milena

Randomize an ID and choose what function to call using this ID:

var functionID : int;

function Start()
{
  functionID = Random.Range(0,3);
  switch ( functionID )
  {
     case 0:  Spawn1();  break;
     case 1:  Spawn2();  break;
     case 2:  Spawn3();  break;
     default:
       Debug.LogError("No function defined for random functionID #" + functionID);
  }
}

function Spawn1(){
}

function Spawn2(){
}

function Spawn3(){
}