• If you have a mod, tool or prefab, please use the Resources section. Click Mods at the top of the forums.

PlayerStatsWindow controller gone? HUD Broken.

I have a HUD that shows things like current level, times died, and number of zombies killed, but since A20, it broke, and it's complaining that the PlayerStatsWindow controller is missing/unknown.

<rect pos="-85,-3" width="75" height="75" controller="PlayerStatsWindow" visible="{statvisible}">
<sprite depth="1" width="75" height="75" name="border" color="222,255,163,55" type="sliced"/>
<filledsprite depth="5" width="71" height="71" pos="2,-2" name="background" color="0,0,0,290" type="filled" fill="1" />
<sprite depth="6" name="TodeIcon" width="65" height="65" pos="3,-5" sprite="ui_game_symbol_zombie" color="96,96,96,100" foregroundlayer="true"/>
<label depth="10" name="ZombiekillsLabel" width="75" height="37" text="{playerzombiekills}" font_size="24" color="[ora]" pos="37,-35" justify="center" pivot="center"/>
</rect>



<rect pos="763,-3" width="75" height="75" controller="PlayerStatsWindow" visible="{statvisible}">
<sprite depth="1" width="75" height="75" name="border" color="222,255,163,55" type="sliced"/>
<filledsprite depth="5" width="71" height="71" pos="2,-2" name="background" color="0,0,0,290" type="filled" fill="1" />
<sprite depth="6" name="TodeIcon" width="65" height="65" pos="3,-5" sprite="ui_game_symbol_near_death_trauma" color="96,96,96,100" foregroundlayer="true"/>
<label depth="10" name="TodeLabel" width="75" height="37" text="{playerdeaths}" font_size="24" color="[ora]" pos="37,-35" justify="center" pivot="center"/>
</rect>


 How am I supposed to fix this? Is there a replacement controller?

 
Last edited by a moderator:
I made a little progress this morning trying to update the UI mod we use...

The original XML was
 

<rect pos="-75,37" width="75" height="75" controller="HUDStatBar" stat_type="Food" visible="{statvisible}">

... snip ...

<label depth="7" name="TextContent" pos="4,-1" font_size="26" color="[white]" text="{playerfood}"
height="34" width="45" justify="left" controller="PlayerStatsWindow" />




I changed the last line to...

<label depth="7" name="TextContent" pos="4,-1" font_size="26" color="[white]" text="{statcurrent}"
height="34" width="45" justify="left" />




It seems to be working for stat_type of "Food" and "Water".  I've got a bit more work/testing to do but I thought I'd post a quick update.

 
yeah, that's a big problem. I tried to solve it, but i only get a value, but this value don't refresh in the hud, it only refreshs by joining the game. -.-

 
Maybe it changed names? Have you checked the vanilla xUI.xml to see if it didn't?
I'm having the same problem (and a few more) when trying to update Sirillion's Z2 to a20 for personal use.

 
Back
Top