jeudi 24 novembre 2022

Display only one gameobject from list

I have 3(A) game object I want when game start to display random only one another to hide,

enter image description here

I tried below code but is only change position please help

    public GameObject player;
   public float placex;
   public float placez;
   private void Start() {
    placex=Random.Range(209,-70);
    placez=Random.Range(-179,108);

    player.transform.position=new Vector3(placex,0,placez);
   }



Aucun commentaire:

Enregistrer un commentaire