Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using UnityEngine;
- namespace Combat {
- public class Health : MonoBehaviour {
- [SerializeField] float health = 100f;
- public void TakeDamage(float damage) {
- health = Mathf.Max(health - damage, 0);
- print(health);
- }
- }
- }
Add Comment
Please, Sign In to add comment