Vice City Multiplayer
VC:MP 0.3 => mIRC/pawn Scripting => Snippet Showroom => Topic started by: Willian_Luigi on October 05, 2013, 01:47:32 am
-
[pawn]new gHeadValue[MAX_PLAYERS];[/pawn]
[pawn]
public OnPlayerSpawn(playerid)
{
gHeadValue[playerid] = 300; //Set player head value 300
return 1;
}
public OnPlayerDeath(playerid, killerid, reason)
{
if (killerid != INVALID_PLAYER_ID) //Verify if the player has died by another player.
{
GivePlayerMoney(killerid, gHeadValue[playerid]); //Give to killer the worth of player head...
gHeadValue[killerid] += 1000; //Set killer head value = value + 1000
//msgs
SendClientMessage(killerid, -1, "You have killed +1 noob, so, now your head worth +$1.000");
SendClientMessage(playerid, -1, "You died, now your head start into the original price($300)");
}
return 1;
}[/pawn]
-
lol. Nice, simple and original idea. I like it, good job :)
-
lol. Nice, simple and original idea. I like it, good job :)
:)
-
Simple, but you could format a string telling them their total head value.
For example:
format(string,sizeof(string),"You have killed +1 noob, so no your head worth +$%d",gHeadValue[killerid]);