private void Awake() { outOfBound = gameObject.AddComponent <OutOfBound>(); rb = GetComponent <Rigidbody2D>(); trailRenderer = GetComponent <TrailRenderer>(); particle = gameObject.AddComponent <Particle>(); particle.ParticleName = hitEffekt; }
private void Awake() { rb = GetComponent <Rigidbody2D>(); outOfBound = gameObject.AddComponent <OutOfBound>(); health = gameObject.AddComponent <Health>(); health.startHealth = hitsToDeath; health.blinkColor = blinkColor; GetComponent <SpriteRenderer>().color = startColor; SetRandomSize(3f, 4f); particle = GetComponent <Particle>(); particle.ParticleName = "Explotion Variant"; }
void Start() { oob = GameObject.FindGameObjectWithTag("OOB").GetComponent <OutOfBound>(); timeLeft = minute * 60 + second; }