Not sending winners name. :s
#1

It's not sending anything.
pawn Code:
forward TimeUp(playerid,notify);
public TimeUp(playerid,notify)
{
    new player;
    if(notify == 1)
    {
    for(new i; i < MAX_PLAYERS; i++)
    {
        if(gKills[i] > gKills[playerid]) player = i;
    }
    GetPlayerName(player, gPlayerName, sizeof(gPlayerName));
    format(str, sizeof(str), WonMatch, gPlayerName);
        SendClientMessageToAll(color1,str);
    }
    return 1;
}
Reply
#2

1. Change

pawn Code:
new player;
1. To;
pawn Code:
new player[MAX_PLAYER_NAME];
2. Change;
pawn Code:
GetPlayerName(player, gPlayerName, sizeof(gPlayerName));
2. To;
pawn Code:
GetPlayerName(i,player,sizeof(player));
3. Change
pawn Code:
format(str, sizeof(str), WonMatch, gPlayerName);
3. To

pawn Code:
format(str, sizeof(str), WonMatch, player);
Reply
#3

Whats the WonMatch?

Code:
forward TimeUp(playerid,notify);
public TimeUp(playerid,notify)
{
    new player;
    if(notify == 1)
    {
    for(new i; i < MAX_PLAYERS; i++)
    {
        if(gKills[i] > gKills[playerid]) player = i;
    }
    GetPlayerName(player, gPlayerName, sizeof(gPlayerName));
    format(str, sizeof(str),"%s %s", WonMatch, gPlayerName);
        SendClientMessageToAll(color1,str);
    }
    return 1;
}
Reply
#4

WonMatch is in a define
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)