The command /contract
#1

Код:
dcmd_contract(playerid, params[])
{
	new targetid;
	new reasonid;
	if(sscanf(params, "uzi", targetid, reasonid, money)) return SendClientMessage(playerid, COLOR_RED, "Usage: /contract [ID] [Reason] [Reward]");
	if(!IsPlayerConnected(targetid) || targetid == INVALID_PLAYER_ID) return SendClientMessage(playerid,COLOR_RED, "Error: Player is not connected.");
	SendClientMessage(targetid, COLOR_RED, "Somebody has placed an contract on you!");
	GivePlayerMoney(playerid, -money);
	return 1;
}
This is my code.
What needs top happen?
If you type /contract [ID] [Reason] [Reward]
You lose the cash u typed in by REWARD.
The id gets 6 wanted stars.
The id gets the message: [NAME] has place an contract on you. Reason: [The reason here] <-- Who can do this?
And if the id gets killed by someone, he gets the reward cash.
Reply


Messages In This Thread
The command /contract - by dclaw - 08.01.2011, 20:16
Re: The command /contract - by John_F - 08.01.2011, 20:34
Re: The command /contract - by Alex_Valde - 08.01.2011, 20:34
Re: The command /contract - by John_F - 08.01.2011, 20:37

Forum Jump:


Users browsing this thread: 1 Guest(s)