hudname=h
hud0
hudunshow=hHud19,hudshow=hHud18
Why use a cap when showing or unshowing if you didn't use caps when defining?
If names are case sensitive, then you are attempting to show/unshow a hud that has never been created yet.
Try putting the capitol H in the hudnames, because that would be an easier edit than getting rid of the caps elsewhere, since the hud names are all nicely grouped at the top.
That would be the only thing I see wrong with the first script, other than also needing a
desc = x.
Although, I would have finished it off differently...
:state=21,plrhealthless=1:hudunshow=hHud01,state=22
:state=22,plrhealthgreater=0:hudunshow=hHud01,hudshow=hHud0,state=2
...
:state=21,plralive=0:hudunshow=hHud01,state=22
:state=22,plralive=1:hudunshow=hHud01,hudshow=hHud0,state=2
...but his way should have worked too.
desc = I have to include a description in order for it to work
:state=0:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud0.dds,hudname=hHud0,hudhide=1,hudmake=display,state=1
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud1.dds,hudname=hHud01,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud2.dds,hudname=hHud02,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud3.dds,hudname=hhud03,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud4.dds,hudname=hHud04,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud5.dds,hudname=hHud05,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud6.dds,hudname=hHud06,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud7.dds,hudname=hHud07,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud8.dds,hudname=hHud08,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud9.dds,hudname=hHud09,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud10.dds,hudname=hHud10,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud11.dds,hudname=hHud11,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud12.dds,hudname=hHud12,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud13.dds,hudname=hHud13,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud14.dds,hudname=hHud14,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud15.dds,hudname=hHud15,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud16.dds,hudname=hHud16,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud17.dds,hudname=hHud17,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud18.dds,hudname=hHud18,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud19.dds,hudname=hHud19,hudhide=1,hudmake=display
:state=1:hudreset,hudx=10,hudy=90,hudimagefine=gamecore\huds\healthhuds\hhud20.dds,hudname=hHud20,hudhide=1,hudmake=display,state=2
:state=2,plrhealthless=101,plrhealthgreater=94:hudunshow=hHud0,hudshow=hHud20,state=3
:state=2,plrhealthless=95:state=3
:state=3,plrhealthless=95,plrhealthgreater=89:hudunshow=hHud20,hudshow=hHud19,state=4
:state=3,plrhealthgreater=94:state=2
:state=3,plrhealthless=90:state=4
:state=4,plrhealthless=90,plrhealthgreater=84:hudunshow=hHud19,hudshow=hHud18,state=5
:state=4,plrhealthgreater=89:state=3
:state=4,plrhealthless=85:state=5
:state=5,plrhealthless=85,plrhealthgreater=79:hudunshow=hHud18,hudshow=hHud17,state=6
:state=5,plrhealthgreater=84:state=4
:state=5,plrhealthless=80:state=6
:state=6,plrhealthless=80,plrhealthgreater=74:hudunshow=hHud17,hudshow=hHud16,state=7
:state=6,plrhealthgreater=79:state=5
:state=6,plrhealthless=75:state=7
:state=7,plrhealthless=75,plrhealthgreater=69:hudunshow=hHud16,hudshow=hHud15,state=8
:state=7,plrhealthgreater=74:state=6
:state=7,plrhealthless=70:state=8
:state=8,plrhealthless=70,plrhealthgreater=64:hudunshow=hHud15,hudshow=hHud14,state=9
:state=8,plrhealthgreater=69:state=7
:state=8,plrhealthless=65:state=9
:state=9,plrhealthless=65,plrhealthgreater=59:hudunshow=hHud14,hudshow=hHud13,state=10
:state=9,plrhealthgreater=64:state=8
:state=9,plrhealthless=60:state=10
:state=10,plrhealthless=60,plrhealthgreater=54:hudunshow=hHud13,hudshow=hHud12,state=11
:state=10,plrhealthgreater=59:state=9
:state=10,plrhealthless=55:state=11
:state=11,plrhealthless=55,plrhealthgreater=49:hudunshow=hHud12,hudshow=hHud11,state=12
:state=11,plrhealthgreater=54:state=10
:state=11,plrhealthless=50:state=12
:state=12,plrhealthless=50,plrhealthgreater=44:hudunshow=hHud11,hudshow=hHud10,state=13
:state=12,plrhealthgreater=49:state=11
:state=12,plrhealthless=45:state=13
:state=13,plrhealthless=45,plrhealthgreater=39:hudunshow=hHud10,hudshow=hHud09,state=14
:state=13,plrhealthgreater=44:state=12
:state=13,plrhealthless=40:state=14
:state=14,plrhealthless=40,plrhealthgreater=34:hudunshow=hHud09,hudshow=hHud08,state=15
:state=14,plrhealthgreater=39:state=13
:state=14,plrhealthless=35:state=15
:state=15,plrhealthless=35,plrhealthgreater=29:hudunshow=hHud08,hudshow=hHud07,state=16
:state=15,plrhealthgreater=34:state=14
:state=15,plrhealthless=30:state=16
:state=16,plrhealthless=30,plrhealthgreater=24:hudunshow=hHud07,hudshow=hHud06,state=17
:state=16,plrhealthgreater=29:state=15
:state=16,plrhealthless=25:state=17
:state=17,plrhealthless=25,plrhealthgreater=19:hudunshow=hHud06,hudshow=hHud05,state=18
:state=17,plrhealthgreater=24:state=16
:state=17,plrhealthless=20:state=18
:state=18,plrhealthless=20,plrhealthgreater=14:hudunshow=hHud05,hudshow=hHud04,state=19
:state=18,plrhealthgreater=19:state=17
:state=18,plrhealthless=15:state=19
:state=19,plrhealthless=15,plrhealthgreater=9:hudunshow=hHud04,hudshow=hHud03,state=20
:state=19,plrhealthgreater=14:state=18
:state=19,plrhealthless=10:state=20
:state=20,plrhealthless=10,plrhealthgreater=4:hudunshow=hHud03,hudshow=hHud02,state=21
:state=20,plrhealthgreater=9:state=19
:state=20,plrhealthless=5:state=21
:state=21,plrhealthless=5,plrhealthgreater=0:hudunshow=hHud02,hudshow=hHud01,state=22
:state=21,plrhealthgreater=4:state=20
:state=21,plrhealthless=1:hudunshow=hHud01,state=22
:state=22,plrhealthgreater=0:hudunshow=hHud01,hudshow=hHud0,state=2
Try that, but change the description of course.
Quote: "For example, what happens if the player has 10 health, then gets a health pack that increases their health to 100? Your script will take time to catch up, not immediately change to the HUD that it needs. That is one of the problems I see in your script."
Yes, but it would barely be noticable if at all.
The problem I see with stepping back is that he is leaving the last hud displayed, so I would probably make sure each state removed its hud when going back up...
:state=3,plrhealthgreater=94:state=2
...
:state=3,plrhealthgreater=94:hudunshow=hHud19,state=2
Anyway, those two things above were all I saw that would keep the first script from functioning, and this last suggestion is just to tidy up.
I'll leave the testing to Michael Thompson,since he has all of the HUDs in the right places.