Jump to content
  • 0

pomoc Vybraný text


radilek

Dotaz

Ahoj dodnes nechapu kdyz chci treba udelat hrace xxx zabil hrace xxx tak nechapu dodnes jak udelat aby na to spravny misto byl ten hrac kterej ho zabil a hrac co je mrtvej ... mohl by mi nekdo tuhle funkci s tim co napise hrac tak se zobrazi v textu atd poradne vysvetlit pls?

Link to comment
Share on other sites

1 odpověd na tuto otázku

Recommended Posts

  • 0

skus toto

new name[MAX_PLAYER_NAME], string[256], deathreason[20];

GetPlayerName(playerid, name, sizeof(name));
GetWeaponName(reason, deathreason, 20);

if (killerid == INVALID_PLAYER_ID)
{
SendDeathMessage(INVALID_PLAYER_ID,playerid,reason);

switch (reason)
{
case WEAPON_DROWN:
{
format(string, sizeof(string), "[!]> Hráč %s se utopil.", name);
}
default:
{
if (strlen(deathreason) > 0)
{
format(string, sizeof(string), "Hráč %s zemřel. [%s]", name, deathreason);
} else {
format(string, sizeof(string), "Hráč %s zemřel.", name);
}}}
} else {
SendDeathMessage(killerid,playerid,reason);
new killer[MAX_PLAYER_NAME];
GetPlayerName(killerid, killer, sizeof(killer));
if (strlen(deathreason) > 0)
{
format(string, sizeof(string), "Hráč %s zabil hráce %s zbraní [%s]", killer, name, deathreason);
} else {
SendDeathMessage(killerid,playerid,reason);
format(string, sizeof(string), "Hráč %s zabil hráče %s.", killer, name);
}}

 

je to trochu slozitejsi na vysvetleni :d

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...