i can get it to show the hp bar above the character and npc's but it just wont trigger the icon_state shifting to match the current hp? is there any other way to add hp bars to npc's like maybe useing the skin interface? or something because regardless to what i do it just dosnt want to co-opperate
mob
proc
updateHealth()
var/percent=round(src.hp/src.maxhp*100,10)
if(percent>100) percent=100
if(percent<0) percent=0
for(var/obj/hudMeters/o in src)
o.icon_state=num2text(percent)
proc/add_hpbars()
usr.overlays += /obj/hudMeters/health_01
usr.overlays += /obj/hudMeters/health_02
src.updateHealth()
obj
hudMeters
health_01
icon='meter_01.dmi'
icon_state="0"
pixel_x=-16
pixel_y=40
health_02
icon='meter_02.dmi'
icon_state="0"
pixel_x=16
pixel_y=40
when the mob is hit it dose every other proc call there is like blood effect, damage numbers.. but for some reason this just wont fill the hp bar or reduce it
the game loads with the bar active but its also empty aswell even tho ive told the NPC's to trigger the update proc at spawning of all there outfits and weapons.
anyone have a clue whats going on here