Buy armour
#1

Quote:

//buy armour

if (strcmp("/buyarmour", cmdtext, true, 10) == 0)
{
if GetPlayerMoney(playerid) => 1000;
SetPlayerArmour(playerid, 100.0);
SendClientMessage(playerid, 0xFFFFFFAA, "Armor for you!");
GivePlayerMoney(playerid, -1000);


else
SendClientMessage(playerid, 0xFFFFFFAA, "Poor bastard, Get some money!");

return 1;


}

When you got 1000 you should be able to buy armour. If you don't have that it should return the message poor bastard. If you can correct it and explain what I did wrong, I would appreciate that.

Thanks in advance.
Reply


Messages In This Thread
Buy armour - by kimse007 - 28.07.2009, 12:08
Re: Buy armour - by Criss_Angel - 28.07.2009, 12:10
Re: Buy armour - by -Sneaky- - 28.07.2009, 12:13
Re: Buy armour - by kimse007 - 28.07.2009, 12:47
Re: Buy armour - by ronyx69 - 28.07.2009, 12:52
Re: Buy armour - by kimse007 - 28.07.2009, 12:59
Re: Buy armour - by ronyx69 - 28.07.2009, 13:01
Re: Buy armour - by BMUK - 28.07.2009, 13:02
Re: Buy armour - by kimse007 - 28.07.2009, 13:07
Re: Buy armour - by miceiken - 28.07.2009, 13:17

Forum Jump:


Users browsing this thread: 1 Guest(s)