
This sample code demonstrates one way to display a health bar that floats above
a desired object using the Viewport.Project method and 2D sprites rendered with a SpriteBatch object. The health bar also scales itself depending on the distance
from the camera's position.