I was attempting to make my enemies disapeer and come back in say. 60 seconds. I tried to use transform.active = false; inside of a waitforseconds Coroutine but the object never came back.. so all Im trying to do is make the gameobject after it hits 0 life to disapeer for 60 seconds and come back with full life.
thank you in advance!
if (curHealth == 0) {
//DISAPEER FOR 60 SECONDS
//COME BACK.
transform.position = respawnhere;
curHealth = maxHealth;
PlayerAttack ZS = (PlayerAttack)target.GetComponent ("PlayerAttack");
ZS.DeselectTarget ();
ZS.SpawnEXP();
PlayerHealth eh = (PlayerHealth)target.GetComponent ("PlayerHealth");
eh.AdjustCurrentEXP (20);
}
↧