IRC Forward Help. (+REP)
#1

pawn Код:
public SaveStats()
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        new joinMsg[108];
        format(joinMsg, sizeof(joinMsg),i));
        IRC_GroupSay(groupID, IRC_CHANNEL, joinMsg);

       
       
        SendClientMessage(i, green,"Everyone's status has been automatically saved!");
        SavePlayer(i);
       
    }
    return 1;
}
Код:
C:\Users\Alex\Documents\Samp Server\gamemodes\CODWAW1.1.pwn(5759) : error 035: argument type mismatch (argument 3)
C:\Users\Alex\Documents\Samp Server\gamemodes\CODWAW1.1.pwn(5759) : error 029: invalid expression, assumed zero
C:\Users\Alex\Documents\Samp Server\gamemodes\CODWAW1.1.pwn(5759) : warning 215: expression has no effect
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


2 Errors.
I want that when the stats get saved appear on the IRC
Thanks!
Reply
#2

Which line does the error cause?
Reply
#3

pawn Код:
new joinMsg[108];
        format(joinMsg, sizeof(joinMsg),i));
        IRC_GroupSay(groupID, IRC_CHANNEL, joinMsg);
Thats the prob
Reply
#4

pawn Код:
format(joinMsg, sizeof(joinMsg),i));
Should be:

pawn Код:
format(joinMsg, sizeof(joinMsg),"%s has joined!",GetName(i));
//change the message to whatever you want it to be.
Reply
#5

Here You Go

pawn Код:
public SaveStats()
{
    for(new i = 0; i < MAX_PLAYERS; i++)
    {
        new string[45];
        format(string, sizeof(string), "Everyone's status has been automatically saved!"));
        IRC_GroupSay(groupID, IRC_CHANNEL, string);
        SendClientMessageToAll(green, string);
        SavePlayer(i);
    }
    return 1;
}
Reply
#6

Thanks!
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)