public void TakeDamage(int dam) { this.health -= (dam - armor); if (health <= 0) { Destroy(gameObject); globals.AddBits(worth); } }