Shields In a Game

I was wondering if anyone knows how make shield bar and have it took away a little bit when shot at for my game?
please help me thanks