using UnityEngine;
using System.Collections;
public class enemyshoot : MonoBehaviour {
public Transform spawnbulletenemy;
public Rigidbody bullet;
public float brzinametka = 5f;
public Transform igrac;
// Use this for initialization
void Start () {
}
// Update is called once per frame
void Update () {
Rigidbody metakkojileti;
metakkojileti = Instantiate (bullet, spawnbulletenemy.position, spawnbulletenemy.rotation) as Rigidbody;
metakkojileti.AddForce (spawnbulletenemy.forward * brzinametka);
}
void shoot()
{
}
}
This is my code , I want delay before evry shoot , is there any way to avoid corutines they look very complicated ?