Skip to content

Instantly share code, notes, and snippets.

@unity3dcollege
Created December 30, 2016 20:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save unity3dcollege/bf3a350ffd5dc5ff018247c653ffd6e8 to your computer and use it in GitHub Desktop.
Save unity3dcollege/bf3a350ffd5dc5ff018247c653ffd6e8 to your computer and use it in GitHub Desktop.
using UnityEngine;
public class NPC : MonoBehaviour
{
internal void TakeDamage(int amount)
{
GetComponent<IHealth>().TakeDamage(amount);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment