SA-MP Forums Archive
argument type mismatch - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: argument type mismatch (/showthread.php?tid=632314)



argument type mismatch - Melktert - 12.04.2017

Код:
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(417) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(419) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(421) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(434) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(436) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(451) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(452) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(463) : error 035: argument type mismatch (argument 3)
Line 417:
PHP код:
        if(!IsPlayerAdmin(playerid)) return SendClientMessage(playeridCOL_WHITE"[SERVER] ERROR: {FFFFFF}You need to be logged into RCON to do this."); 
Line 419:
PHP код:
        if(sscanf(params,"ud",id,level)) return SendClientMessage(playeridCOL_WHITE"[SERVER] USAGE: {FFFFFF}/setadmin id level"); 
Line 421:
PHP код:
        if(level 5) return SendClientMessage(playeridCOL_WHITE"SERVER] ERROR: {FFFFFF}The level you entered is too high (Max 5)"); 
Line 434:
PHP код:
    if(PlayerInfo[playerid][pAdmin] > 1) return SendClientMessage(playeridCOL_WHITE"SERVER] ERROR: {FFFFFF}Insufficient privileges"); 
Line 436:
PHP код:
    if(sscanf(params,"us[128]",id,reason)) return SendClientMessage(playeridCOL_WHITE"[SERVER] USAGE: {FFFFFF}/kick id reason"); 
Line 451:
PHP код:
    if(PlayerInfo[playerid][pAdmin] > 3) return SendClientMessage(playeridCOL_WHITE"[SERVER] ERROR: {FFFFFF}Insufficient privileges"); 
Line 452:
PHP код:
    if(sscanf(params,"us[128]",id,reason)) return SendClientMessage(playeridCOL_WHITE"[SERVER] USAGE: {FFFFFF}/ban id reason"); 
Line 463:
PHP код:
                INI_WriteString(File,"Banned",1); 



Re: argument type mismatch - khRamin78 - 12.04.2017

Quote:
Originally Posted by Melktert
Посмотреть сообщение
Код:
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(417) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(419) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(421) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(434) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(436) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(451) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(452) : error 035: argument type mismatch (argument 2)
C:\Users\Melktert\Desktop\gtasa_deathmatch\gamemodes\lsdm.pwn(463) : error 035: argument type mismatch (argument 3)
Line 417:
PHP код:
        if(!IsPlayerAdmin(playerid)) return SendClientMessage(playeridCOL_WHITE"[SERVER] ERROR: {FFFFFF}You need to be logged into RCON to do this."); 
Line 419:
PHP код:
        if(sscanf(params,"ud",id,level)) return SendClientMessage(playeridCOL_WHITE"[SERVER] USAGE: {FFFFFF}/setadmin id level"); 
Line 421:
PHP код:
        if(level 5) return SendClientMessage(playeridCOL_WHITE"SERVER] ERROR: {FFFFFF}The level you entered is too high (Max 5)"); 
Line 434:
PHP код:
    if(PlayerInfo[playerid][pAdmin] > 1) return SendClientMessage(playeridCOL_WHITE"SERVER] ERROR: {FFFFFF}Insufficient privileges"); 
Line 436:
PHP код:
    if(sscanf(params,"us[128]",id,reason)) return SendClientMessage(playeridCOL_WHITE"[SERVER] USAGE: {FFFFFF}/kick id reason"); 
Line 451:
PHP код:
    if(PlayerInfo[playerid][pAdmin] > 3) return SendClientMessage(playeridCOL_WHITE"[SERVER] ERROR: {FFFFFF}Insufficient privileges"); 
Line 452:
PHP код:
    if(sscanf(params,"us[128]",id,reason)) return SendClientMessage(playeridCOL_WHITE"[SERVER] USAGE: {FFFFFF}/ban id reason"); 
Line 463:
PHP код:
                INI_WriteString(File,"Banned",1); 
first of all as your last problem make sure your defines are right

PHP код:
//SendClientMessage use this type 
#define COLOR_WHITE 0xFFFFFFAA
//Dialogs use this type 
#define COL_WHITE "{FFFFFF}" 
they are different !

and
PHP код:
INI_WriteString(File,"Banned",1);  
//1 is not a string so you have to do 
INI_WriteInt(File,"Banned",1); 
Please Read <<This>>


Re: argument type mismatch - DarkSkull - 12.04.2017

Edit: Answered Above


Re: argument type mismatch - Melktert - 12.04.2017

Quote:
Originally Posted by khRamin78
Посмотреть сообщение
first of all as your last problem make sure your defines are right

PHP код:
//SendClientMessage use this type 
#define COLOR_WHITE 0xFFFFFFAA
//Dialogs use this type 
#define COL_WHITE "{FFFFFF}" 
they are different !

and
PHP код:
INI_WriteString(File,"Banned",1);  
//1 is not a string so you have to do 
INI_WriteInt(File,"Banned",1); 
Please Read <<This>>
Thanks bruh, this really helped me. Sorry, I am new to scripting. <3