Clean up HUD drawing code