how would a script go that has the object attack once every 1 and a half seconds? I dont need damage applied, but I am wondering how I could accomplish that or if possible, if someone could write it for me.
try this:
var canAttack = false;
function Update () {
if (canAttack) {
canAttack = false;
SendMessage("Attack");
}
if (!canAttack) {
SendMessage("Reset");
}
}
function Attack () {
// attack script stuff here
}
function Reset () {
yield WaitForSeconds(1.5);
canAttack = true;
}