12.06.2017, 15:35
OK so I basically have a server sided health and all that stuff recently I wanted to make a new system that gives players hp... (the actualy hp perk gives them like this pInfo[playerid][pHealth] += 150; )
So my code is here:
My gethealth stock function
My GiveHealth stock function
Disabled cuz it fucks the whole gm...
Now how do I correctly write the code? to store the hp and then give it.
I tried this and results:
Empty statement lol.
So my code is here:
Code:
if(team[i] == TEAM_HUMAN) { GetHealth(i,hp); if(hp < 80) { GiveHealth(i,hp+3.5);
Code:
stock GetHealth(playerid) { return pInfo[playerid][pHealth]; }
Code:
//stock GiveHealth(playerid { return pInfo[playerid][pHealth] ++; )
Now how do I correctly write the code? to store the hp and then give it.
I tried this and results:
Code:
pInfo[i][pHealth] += 3.5;