Hey guys
I tried to Spawn The Drone At the Position of the spawn point But It doen not work??
using UnityEngine;
using System.Collections;
public class Dronesspawn : MonoBehaviour
{
public Transform SpawnPoint;
public GameObject Drones;
public float spawnTime = 5f;
// Use this for initialization
void Start()
{
InvokeRepeating("DronesSpawn", spawnTime, spawnTime);
}
// Update is called once per frame
void Update()
{
}
void DronesSpawn ()
{
// I tried to Spawn The Drone At the Position of the spawn point ( The SpawnPoint Will Be moving!! ).But It Does not Work?
var newpDronesspawn = GameObject.Instantiate(Drones), SpawnPoint.transform.position,transform.rotation);
}
}