Player to Player /sendcash command??
#1

Hi, I'm tyring to make a very simple command "send cash" for players to use. (not admins)

I have tried to copy from the admin script, but wow it was very hard to read from Ladmin (..and I'm a noob, but learning)


I know what's needed, but scripting it is another story.. (I'm a bad translator - english > machine)

I am just looking for a very very simple script that will do this:
Quote:

/sendcash <ID> <AMOUNT>

if user is online
if user has enough money
{
sender cash - x amount
receiver cash + x amount
}

else
msg "player not online or you do not have enough cash"

I did try to have a bash myself

I know you will need to hold/use at least 4 values, both users ID's / cash


Quote:

public OnPlayerCommandText(playerid, rec_playerid, cmdtext[])
{
if(strcmp(cmdtext,"/sendcash",true) == 0)
{
-i cash from sender
+i cash to receiver
}

return 0;
}

I have searched the forum and ****** btw.


Can anyone help a noob out please?
Reply


Messages In This Thread
Player to Player /sendcash command?? - by sheepondrugs - 17.08.2010, 16:38
Re: Player to Player /sendcash command?? - by Claude - 17.08.2010, 16:51
Re: Player to Player /sendcash command?? - by sheepondrugs - 17.08.2010, 17:01
Re: Player to Player /sendcash command?? - by ikey07 - 17.08.2010, 17:14
Re: Player to Player /sendcash command?? - by Claude - 17.08.2010, 17:19

Forum Jump:


Users browsing this thread: 1 Guest(s)