PM error dialog
#1

HEy i get this error while making a Dialog PM System.



How do make that it sends to another player? and a note that shows that they've gotten a PM.

ERROR:
Код:
C:\Users\Linus\Desktop\samptesting\gamemodes\PM.pwn(278) : error 017: undefined symbol "SendPlayerMessage"
C:\Users\Linus\Desktop\samptesting\gamemodes\PM.pwn(286) : warning 217: loose indentation
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


1 Error.

pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
  switch(dialogid)//if your using only one dialog this isn't needed but you never know.
        {
        case 3:
            {
                 if(strlen(inputtext) > 0)
                 {
line 278:                     SendPlayerMessage(playerid, inputtext);
                 }
                 else
                 {
                     SendClientMessage(playerid,0xFFFFFFAA,"Your input was too short.");
                 }
            }
    }
    return 1;
}

COMMAND:

pawn Код:
CMD:pm(playerid, params[])
{
   ShowPlayerDialog(playerid, 3, DIALOG_STYLE_INPUT, "Private Message", "Type your PM here.", "Submit", "Cancel");
   return 1;
}
Reply
#2

Try This:

pawn Код:
public OnDialogResponse(playerid, dialogid, response, listitem, inputtext[])
{
  switch(dialogid)//if your using only one dialog this isn't needed but you never know.
        {
        case 3:
            {
                 if(strlen(inputtext) > 0)
                 {
                     SendClientMessage(playerid,0xFFFFFFAA,inputtext);
                 }
                 else
                 {
                     SendClientMessage(playerid,0xFFFFFFAA,"Your input was too short.");
                 }
            }
    }
    return 1;
}
Reply
#3

What's the stock your using for SendPLAYERMESSAGE?
Reply
#4

PHP код:
public OnDialogResponse(playeriddialogidresponselistiteminputtext[])
{
  switch(
dialogid)//if your using only one dialog this isn't needed but you never know.
        
{
        case 
3:
            {
                 if(
strlen(inputtext) > 0)
                 {
                     
SendClientMessage(playerid,0xFFFFFFAA,inputtext);
                 }
                 else
                 {
                     
SendClientMessage(playerid,0xFFFFFFAA,"Your input was too short.");
                 }
            }
    }
    return 
1;

Reply
#5

Just change SendPlayerMessage to SendClientMessage, else you need to define SendPlayerMessage.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)