I have a problem with the hook HUDPaint. I’m trying to draw a rounded box with a value in a datafile. But when the value in the data file is changed, the rounded box is not updated. Isn’t HUDPaint supposed to be reloaded every frames ?
this is a fake code that represent my problem :
hook.Add("HUDPaint","HUDaLightSaber_EmpireRebellion", function() local value = file.Read("directoryfile/filewhereisthevalue.txt","DATA") tonumber(value,10) draw.RoundedBox(0, ScrW() * 0.5, ScrH() * 0.5 ,value,ScrH()* 0.5, Color(0, 0,0)) end)
Thank you for all help possible,
I’m sure it’s simple answer but i an’t find it