Warning 213: Tag mismatch and warning 202: number of arguments does not match definition
#1

I need help, i have problems with this, can u guys help me pls?

Script:
Code:
CMD:handcuff(playerid, params[])
{
    new targetid;
    if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, COLOR_GREY, "SU DUNG: /handcuff [Player ID]");
    if(IsPlayerConnected(targetid))
        {
            new Float:x, Float:y, Float:z;
               GetPlayerPos(playerid, x, y, z);
               if(IsPlayerInRangeOfPoint(targetid, 5.0, x, y, z))
                   {
                    new str[512];
                      new name[MAX_PLAYER_NAME];
                    GetPlayerName(playerid, name, sizeof(name));
                    new target[MAX_PLAYER_NAME];
                       GetPlayerName(targetid, target, sizeof(target));
                       format(str, sizeof(str), "You cuffed %s .",target);
                       SendClientMessage(playerid, COLOR_LIGHTBLUE, str);
                       format(str, sizeof(str), "You have cuffed by %s!",name);
                       SendClientMessage(targetid, COLOR_LIGHTBLUE, str);
                       SetPlayerAttachedObject(targetid, 0, 19418, 6, -0.011000, 0.028000, -0.022000, -15.600012, -33.699977,-81.700035, 0.891999, 1.000000, 1.168000);
                       SetPlayerSpecialAction(targetid,SPECIAL_ACTION_CUFFED);
                {
				    format(str, sizeof(str), "* %s take hands cuff out and cuffed %s .", GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid));
					ProxDetectorS(30.0, playerid, str, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
				}
                      return 1;
                }

        }
    return 1;
}

CMD:unhandcuff(playerid, params[])
{

        new targetid;
        if(sscanf(params, "u", targetid)) return SendClientMessage(playerid, -1, "SU DUNG: /unhandcuff [Player ID]");
        if(IsPlayerConnected(targetid))
        {
            new Float:x, Float:y, Float:z;
               GetPlayerPos(playerid, x, y, z);
               if(IsPlayerInRangeOfPoint(targetid, 5.0, x, y, z))
                   {
                    if(!SetPlayerAttachedObject(targetid, 0, 19418, 6, -0.011000, 0.028000, -0.022000, -15.600012, -33.699977,-81.700035, 0.891999, 1.000000, 1.168000))return SendClientMessage(playerid,-1,"ERROR: The player is not cuffed!");
                      SetPlayerSpecialAction(targetid,SPECIAL_ACTION_NONE);
                    new str[512];
                      new name[MAX_PLAYER_NAME];
                    GetPlayerName(playerid, name, sizeof(name));
                    new target[MAX_PLAYER_NAME];
                       GetPlayerName(targetid, target, sizeof(target));
                       format(str, sizeof(str), "You uncuffed for %s!",target);
                       SendClientMessage(playerid, COLOR_LIGHTBLUE, str);
					   format(str, sizeof(str), "** %s uncuffed for %s", GetPlayerName(playerid), GetPlayerName(playerid));
					   NewProx(playerid, 0xC688D4AA, str, 30.0);
                       format(str, sizeof(str), "You have uncuffed by %s!",name);
                       SendClientMessage(targetid, COLOR_LIGHTBLUE, str);
						{
				    	format(str, sizeof(str), "* %s uncuffed for %s.", GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid));
						ProxDetectorS(30.0, playerid, str, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
						}
                      return 1;
                }

        }
        return 1;
}
Warning:
Code:
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(352) : warning 213: tag mismatch
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(352) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(352) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(352) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(352) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(381) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(381) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(381) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(381) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(387) : warning 213: tag mismatch
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(387) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(387) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(387) : warning 202: number of arguments does not match definition
C:\Users\Administrator\Desktop\PG-RP.ORG\VGG\VGG\VGG-RP\filterscripts\oocchat.pwn(387) : warning 202: number of arguments does not match definition
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


14 Warnings.
Line 352:
Code:
ProxDetectorS(30.0, playerid, str, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
Line 381:

Code:
format(str, sizeof(str), "* %s take hands cuff out and cuffed %s .", GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid));
Line 387:
Code:
ProxDetectorS(30.0, playerid, str, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
Reply
#2

Can you show to me this function ?

Code:
ProxDetectorS
Reply
#3

Show ProxDetectorS AND GetPlayerNameEx
Reply
#4

GetPlayerNameEx
Code:
stock GetPlayerNameEx(playerid)
{
     new pName[25];
     GetPlayerName(playerid, pName, sizeof(pName));
     return pName;
}
ProxDetectorS
Code:
stock ProxDetectorS(playerid, color, const message[], Float:Range)
{
    new
		Float:_Position[  3], idx = 0
	;
    GetPlayerPos( playerid, _Position[0], _Position[1], _Position[2] );

    while(idx++ < MAX_PLAYERS && IsPlayerConnected(idx))
    {
        if(GetPlayerVirtualWorld(playerid) == GetPlayerVirtualWorld(idx) && IsPlayerInRangeOfPoint(idx, Range, _Position[0], _Position[1], _Position[2]))
        {
        	SendClientMessage(idx, color, message);
        }
    }
    return true;
}
Reply
#5

Quote:
Originally Posted by RogueDrifter
View Post
Show ProxDetectorS AND GetPlayerNameEx
Can you help me pls?
Reply
#6

change
PHP Code:
ProxDetectorS(30.0playeridstrCOLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE); 
to
PHP Code:
ProxDetectorS(playeridCOLOR_PURPLE,str,30.0); 
and
PHP Code:
format(strsizeof(str), "* %s take hands cuff out and cuffed %s ."GetPlayerNameEx(playerid), GetPlayerNameEx(giveplayerid)); 
to
PHP Code:
new playername[30];
new 
otherplayername[30];
GetPlayerName(playerid,playername,sizeof(playername));
GetPlayerName(giveplayerid,otherplayername,sizeof(otherplayername));
format(strsizeof(str), "* %s take hands cuff out and cuffed %s ."playernameotherplayername); 
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)