示例#1
0
 public override void OnHit()
 {
     base.OnHit();
     if (!dead)
     {
         dead = true;
         WorldDestroy fx = Instantiate(destroyEffect, transform.position, Quaternion.identity) as WorldDestroy;
         fx.DoDestroy(myRadius);
         Destroy();
     }
 }
示例#2
0
    public override void OnHit()
    {
        base.OnHit();
        if (!dead)
        {
            dead = true;
            gameObject.SetActive(false);
            WorldDestroy fx = Instantiate(destroyEffect, transform.position, Quaternion.identity) as WorldDestroy;
            fx.DoDestroy(1);

            GameOver.EndGame();
        }
    }