posición de conjunto de unidad
// To set the position of a gameobject use the following
GameObject.transform.position = new Vector3(x, y, z);
SkelliBoi
// To set the position of a gameobject use the following
GameObject.transform.position = new Vector3(x, y, z);
using UnityEngine;
using System.Collections;
public class AICover : MonoBehaviour
{
public GameObject() balls = new GameObject(However many balls);
//you need to go to the inspector and put the balls in order to what you want to destroy first
void Update()
{
foreach (GameObject ball in balls)
{
int minisIndex = 0;
int OminisIndex = 1;
int index = 0;
if (OminisIndex <= 1)
{
minisIndex = OminisIndex;
for (int i = 0; i == minisIndex; i += 0)
{
if (balls[minisIndex] != null && balls[index] == null)
{
//lose
}
minisIndex--;
}
}
index++;
OminisIndex++;
}
}
}
if (transform.position.x == 0)
{
print("hi");
}