I started making an experience-system from the tutorials on SDK Docs.
I got all the levels and xp set up but I thought I'd implement an ability-system as well.
So basicly when you have enough "AbilityPoints" you can upgrade your health, speed etc.
I have set up a working VGUI that looks like the teammenu in HL2MP but the problem I'm having is that I don't know how to change the looks of the VGUI depending on the properties of the player. For example if he already has HealthUpgrade level 1, that button should be disabled.
The reason why its complicated is that the VGUI is in the client part of the project and therefore I can only acces C_HL2MP_Player.h and for some reason making functions in that header does not work during runtime :S
I've tried making an integer in the C_HL2MP_Player.h that keeps track of the HealthLevel as well as functions like GetHealthLevel() and SetHealthLevel() and in the UpgradeMenu.cpp (vgui file) I checked like this:
if GetHealthLevel() >= 2 then m_pHealthButton->SetEnable(false);
But it doesn't work -.- HELP PLEASE
EDIT: I found the solution. If anyone is interrested in the code, just pm me.
~J
ps. if you want me to post the code it will be liek 5 different pages

