12.01.2011, 19:36
Heey guys,
I am using a weapon systeem with variables like: weapon1,ammo1,weapon2,ammo2.
Now I want that when you are out of guns you are REALY out of guns so you need to buy more guns.
Now I have made this:
if(GetPlayerWeapon(playerid) == 25)
{
PlayerInfo[playerid][pAmmo3] = GetPlayerAmmo(playerid);
return 1;
}
I know sure that I have weapon ID 25.
When I shoot 2 times with the shotgun and I disconnect (so the player is getting saved) and I look at the scriptfiles it is still the same ammo wich I bought.
Can anyone please help me how to fix this?
I am using a weapon systeem with variables like: weapon1,ammo1,weapon2,ammo2.
Now I want that when you are out of guns you are REALY out of guns so you need to buy more guns.
Now I have made this:
if(GetPlayerWeapon(playerid) == 25)
{
PlayerInfo[playerid][pAmmo3] = GetPlayerAmmo(playerid);
return 1;
}
I know sure that I have weapon ID 25.
When I shoot 2 times with the shotgun and I disconnect (so the player is getting saved) and I look at the scriptfiles it is still the same ammo wich I bought.
Can anyone please help me how to fix this?