Skip to content

Commit

Permalink
quick error fix
Browse files Browse the repository at this point in the history
  • Loading branch information
theradest1 committed Mar 2, 2022
1 parent fd84fd1 commit 449f4dc
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Assets/Scripts/Health.cs
Original file line number Diff line number Diff line change
Expand Up @@ -14,12 +14,12 @@ public class Health : MonoBehaviour
public GameObject player;
public GameObject hitParticles;
public float minStrength;
Sounds sounds;
//Sounds sounds;

// Start is called before the first frame update
void Start()
{
sounds = GameObject.Find("SoundManager").GetComponent<Sounds>();
//sounds = GameObject.Find("SoundManager").GetComponent<Sounds>();
}

// Update is called once per frame
Expand All @@ -36,7 +36,7 @@ void OnCollisionEnter(Collision collision)
//Debug.Log(strength);
//Debug.Log(strength);
if(strength > minStrength){
sounds.hitSounds();
//sounds.hitSounds();
Instantiate(hitParticles, collision.contacts[0].point, healthBarCanvas.transform.rotation);
health -= strength/resistance;

Expand Down

0 comments on commit 449f4dc

Please sign in to comment.