11.03.2012, 22:44
i tired to make an thing so if i get killed by an person it says "You've been killed by %s" ..can some tellme..or for rep do it.
public OnPlayerDeath( playerid, killerid, reason ) {
if ( killerid != INVALID_PLAYER_ID ) {
new wepName[32];
new deathStr[82];
new killerName[24];
GetPlayerName( killerid, killerName, 24 );
GetWeaponName( reason, wepName, 32 );
format( deathStr, 82, "You were killed by %s using a %s.", killerName );
SendClientMessage( playerid, -1, deathStr );
}
return 1;
}
public OnPlayerDeath(playerid, killerid, reason) { new string[128],killed[MAX_PLAYER_NAME],killer[MAX_PLAYER_NAME]; GetPlayerName(playerid,killed,sizeof(killed)); GetPlayerName(killerid,killer,sizeof(killer)); format(string,sizeof(string),"%s has been killed by %s",killed,killer); SendClientMessage(playerid,0xAA3333AA,string); return 1; }
pawn Код:
|
if ( killerid != INVALID_PLAYER_ID ) {
new deathStr[82];
new killerName[24];
GetPlayerName( killerid, killerName, 24 );
format( deathStr, 82, "You were killed by %s.", killerName );
SendClientMessage( playerid, -1, deathStr );
}
return 1;
}
if ( killerid != INVALID_PLAYER_ID ) { new deathStr[82]; new killerName[24]; GetPlayerName( killerid, killerName, 24 ); format( deathStr, 82, "You were killed by %s.", killerName ); SendClientMessage( playerid, -1, deathStr );
format(mess,sizeof(mess),"%s a intrat in server. [ {278227}Tara: %s | {278227}IP: %s | {278227}Ping: %i |",GetPName(playerid),Country,IP,GetPlayerPing(playerid));
Line:(24) > SendAdminMessage(COLOR_ADMIN, string);