SA-MP Forums

Go Back   SA-MP Forums > Non-English > Languages > Português/Portuguese

Reply
 
Thread Tools Display Modes
Old 07/07/2010, 02:57 AM   #1
andersongr98
Big Clucker
 
Join Date: Jun 2010
Posts: 122
Reputation: 0
Default [Duvida]Duvida No Script Aadmin

ola a todos queria saber como consertar esse warning:

D:\Minhas imagens\Admin\Arquivos\Server SAMP\Server Samp\pawno\Untitled.pwn(276) : warning 235: public function lacks forward declaration (symbol "OnPlayerPrivmsg")

na linha 276 tem o seguinte:




276. public OnPlayerPrivmsg(playerid, recieverid, text[])
277. {
278. new string[256];
279. new PlayerName[MAX_PLAYER_NAME];
280. new RecName[MAX_PLAYER_NAME];
281. GetPlayerName(recieverid, RecName, sizeof(RecName));
282. GetPlayerName(playerid, PlayerName, sizeof(PlayerName));
283. if(IsPlayerConnected(recieverid) && IsPlayerConnected(playerid))
284. {
285. format(string, sizeof(string), "AdmPM: PM de %s to %s: %s.", PlayerName, RecName, text);
286. for(new i = 0; i < MAX_PLAYERS; i++)
287. {
288. if(IsPlayerConnected(i) && PlayerInfo[i][pAdmin] >= 1 && i != playerid && i != recieverid)
289. {
290. if(PlayerInfo[i][pPMs] == 1)
291. {
292. SendClientMessage(i, COLOR_CYAN, string);
293. }
294. }
295. }


e tbm queria saber como eu crio mais um level no admin filterscript e como eu mudo o level para usar um comando(se tiver algum tutorial me envie ou fale por aki mesmo!)
andersongr98 is offline   Reply With Quote
Old 07/07/2010, 07:21 AM   #2
andmeida10
High-roller
 
andmeida10's Avatar
 
Join Date: Jan 2010
Location: Aveiro - Portugal
Posts: 1,202
Reputation: 31
Default Re: [Duvida]Duvida No Script Aadmin

essa public foi retirada na 0.3a
__________________
andmeida10 is offline   Reply With Quote
Old 07/07/2010, 01:12 PM   #3
ipsBruno
Godfather
 
ipsBruno's Avatar
 
Join Date: Apr 2010
Location: Brazil, Caxias RS
Posts: 6,084
Reputation: 546
Default Re: [Duvida]Duvida No Script Aadmin

SendClientMessageToPlayer??
ipsBruno is offline   Reply With Quote
Old 07/07/2010, 03:25 PM   #4
egonzks
Big Clucker
 
egonzks's Avatar
 
Join Date: Jan 2010
Posts: 161
Reputation: 0
Default Re: [Duvida]Duvida No Script Aadmin

Ficaria assim mais como o andmeida disse na versao 0.3 nao tem mais

pawn Code:
public OnPlayerPrivmsg(playerid, recieverid, text[])
{
    new string[256];
    new PlayerName[MAX_PLAYER_NAME];
    new RecName[MAX_PLAYER_NAME];
    GetPlayerName(recieverid, RecName, sizeof(RecName));
    GetPlayerName(playerid, PlayerName, sizeof(PlayerName));
    if(IsPlayerConnected(recieverid) && IsPlayerConnected(playerid))
    {
        format(string, sizeof(string), "PM de %s to %s: %s.", PlayerName, RecName, text);
        for(new i = 0; i < MAX_PLAYERS; i++)
        {
            if(IsPlayerConnected(i) && PlayerInfo[i][pAdmin] >= 1 && i != playerid && i != recieverid)
            {
                if(PlayerInfo[i][pPMs] == 1)
                {
                    SendClientMessage(i,  COLOR_CYAN, string);
                }
            }
        }
        if(Mute[playerid] == 1) return SendClientMessage(playerid, COLOR_YELLOW, "Você não pode madar PMs enquanto está mudo! Por favor use /report para reportar sua situação para o Admin se você ficou muito tempo mudo.");
        if(recieverid != playerid)
        {
            GetPlayerName(playerid, PlayerName, sizeof(PlayerName));
            GetPlayerName(recieverid, RecName, sizeof(RecName));
            GameTextForPlayer(playerid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~y~Menssagem privada ~r~enviada~y~!", 3000, 3);
            GameTextForPlayer(recieverid, "~n~~n~~n~~n~~n~~n~~n~~n~~n~~y~ Menssagem privada ~r~recebida~y~!", 3000, 3);
            PlayerPlaySound(playerid,1057,0.0,0.0,0.0);
            PlayerPlaySound(recieverid,1057,0.0,0.0,0.0);
            format(string, sizeof(string), "# PM para %s(%i): %s", PlayerName, playerid, text);
            SendClientMessage(recieverid, COLOR_CYAN, string);
            format(string, sizeof(string), "# PM de %s(%i): %s", RecName, recieverid, text);
            SendClientMessage(playerid, COLOR_CYAN, string);
        }
    }
    else
    {
        format(string, sizeof(string), "Não tem nenhum player conectado com o ID %i!", recieverid);
        SendClientMessage(playerid, COLOR_CYAN, string);
    }
    return 0;

}
egonzks is offline   Reply With Quote
Old 07/07/2010, 03:35 PM   #5
andersongr98
Big Clucker
 
Join Date: Jun 2010
Posts: 122
Reputation: 0
Default Re: [Duvida]Duvida No Script Aadmin

Ta e o que eu ponho no lugar??
andersongr98 is offline   Reply With Quote
Old 07/07/2010, 06:48 PM   #6
[BEP]AcerPilot
Guest
 
Posts: n/a
Default Re: [Duvida]Duvida No Script Aadmin

Coloca no topo do GM:

pawn Code:
forward OnPlayerPrivmsg(playerid, recieverid, text[])
  Reply With Quote
Old 07/07/2010, 09:13 PM   #7
andersongr98
Big Clucker
 
Join Date: Jun 2010
Posts: 122
Reputation: 0
Default Re: [Duvida]Duvida No Script Aadmin

mas nao eh gm eh FS o que eu faço??


Edit:

tentei coloca mas nao funciono apareceu os seguinte erro!

Code:
D:\Minhas imagens\Anderson\Arquivos Que Eu Mais Uso\Server SAMP 0.2 u1(0.2.1)\FesTa No Samp 0.2.1\pawno\Untitled.pwn(201) : error 001: expected token: ";", but found "new"
D:\Minhas imagens\Anderson\Arquivos Que Eu Mais Uso\Server SAMP 0.2 u1(0.2.1)\FesTa No Samp 0.2.1\pawno\Untitled.pwn(276) : warning 235: public function lacks forward declaration (symbol "SendClientMessageToPlayer")
Pawn compiler 3.2.3664	 	 	Copyright (c) 1997-2006, ITB CompuPhase


1 Error.
andersongr98 is offline   Reply With Quote
Old 07/07/2010, 09:36 PM   #8
TheGarfield
Banned
 
Join Date: Jul 2010
Location: -_-
Posts: 649
Reputation: 11
Default Re: [Duvida]Duvida No Script Aadmin

Na linha 201 no final bote ;

e na 276 bote SendClientMessage(playerid,
TheGarfield is offline   Reply With Quote
Old 08/07/2010, 12:56 AM   #9
andersongr98
Big Clucker
 
Join Date: Jun 2010
Posts: 122
Reputation: 0
Default Re: [Duvida]Duvida No Script Aadmin

ok ja consegui vlw!!!
andersongr98 is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
[Duvida]Como Adicionar Mais Um Level No Aadmin andersongr98 Português/Portuguese 5 09/07/2010 05:15 PM
[Dúvida] 147rafa147 Português/Portuguese 7 23/03/2010 11:29 PM
Duvida ruandro Português/Portuguese 2 11/02/2010 02:49 PM
Duvida jcs14 Português/Portuguese 3 10/02/2010 11:13 AM


All times are GMT. The time now is 09:13 AM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.