details
#1

after my script got deleted and when i recovered it i still had some strange erors:
PHP код:
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(637) : error 035argument type mismatch (argument 3)
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(656) : error 035argument type mismatch (argument 3)
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(755) : warning 203symbol is never used"Org1Vozila"
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(755) : warning 203symbol is never used"PolicijaVozila"
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
2 Errors

dont mind those warning i solved them.
script:
PHP код:
CMD:skinilidera(playerid,params[])
{
    if(
PlayerInfo[playerid][pAdmin] <= 5) return SCM(playerid,COLOR_RED,"Nisi admin!");
    new 
targetid;
    if(
sscanf(params,"u",targetid)) return SCM(playerid,COLOR_RED,"Koristi:/skinilidera [Id/Ime]!");
    if(
PlayerInfo[targetid][pRank] < 6) return SCM(playerid,COLOR_RED,"Taj igrac nije lider!");
    
OrgInfo[PlayerInfo[targetid][pOrgID]][oBrojClanova]--;
    new 
str[100];
     
format(str,sizeof(str),COLOR_RED,"Admin %s ti je skinuo lidera.",GetName(playerid)); // and here
     
SCM(targetid,COLOR_RED,str);
    
PlayerInfo[targetid][pOrgID] = -1;
    
PlayerInfo[targetid][pRank] = 0;
    
SetPlayerSkin(playerid,100);
    
UpdateOrgTexts();
       for(new 
o=1;o<MAX_ORGS;o++)
    {
        
SacuvajOrg(o);
    }
    return 
1;

and
PHP код:
CMD:postavilidera(playerid,params[])
{
    if(
PlayerInfo[playerid][pAdmin] <= 5) return SendClientMessage(playerid,COLOR_RED,"[RMT:RP]:Morate biti Admin(level 6), da koristite ovu komandu!");
    if(
PlayerInfo[playerid][pAdmin] == 0) return SendClientMessage(playerid,COLOR_RED,"[RMT:RP]:Morate biti Admin, da koristite ovu komandu!");
    new 
targetid,orgname[25];
    if(
sscanf(params,"us[25]",targetid,orgname))
    {
        
SendClientMessage(playerid,COLOR_RED,"[RMT:RP]:Upotreba: /postavilidera [ID/Ime][Ime organizacije]!");
        
SCM(playerid,COLOR_RED,"1:Grove Street Families!");
        return 
1;
 }
    if(
PlayerInfo[targetid][pRank] == 6) return SCM(playerid,COLOR_RED,"[RMT:RP]:Igrac je vec lider neke organizacije. Da mu skinete lidera koristi /skinilidera!");
    if(
PlayerInfo[playerid][pOrgID] == 1)
    {
        
OrgInfo[1][oBrojClanova]--;
    }
    new 
str[100];
    if(!
strcmp(orgname,"Grove Street Families",true))
    {
        
PlayerInfo[targetid][pOrgID] = 1;
        
PlayerInfo[targetid][pRank] = 6;
        
OrgInfo[1][oBrojClanova]++;
        
format(str,sizeof(str),COLOR_RED,"Admin %s ti je dao lidera organizacije Grove Street Families.",GetName(playerid));
        
SCM(targetid,-1,str);
        
SetPlayerSkin(targetid,ORGGROVE_SKIN_RANK_6); // its up there admin %s ti je dao lidera...
    
}
    
UpdateOrgTexts();
       for(new 
o=1;o<MAX_ORGS;o++)
    {
        
SacuvajOrg(o);
    }
    return 
1;

any help is welcome and it can result as reputation point
Reply
#2

CTRL + G and give me lines 637 and 656
Reply
#3

format(str,sizeof(str),COLOR_RED,"Admin %s ti je dao lidera organizacije Grove Street Families.",GetName(playerid));

and

SetPlayerSkin(targetid,ORGGROVE_SKIN_RANK_6);
Reply
#4

so? it cant be that hard
Reply
#5

Remove "COLOR_RED" from format and the comma beside it, So it would be like that

PHP код:
format(str,sizeof(str),"Admin %s ti je dao lidera organizacije Grove Street Families.",GetName(playerid)) 
and show me the define of
PHP код:
ORGGROVE_SKIN_RANK_6 
Reply
#6

Quote:
Originally Posted by JasonRiggs
Посмотреть сообщение
Remove "COLOR_RED" from format and the comma beside it, So it would be like that

PHP код:
format(str,sizeof(str),"Admin %s ti je dao lidera organizacije Grove Street Families.",GetName(playerid)) 
and show me the define of
PHP код:
ORGGROVE_SKIN_RANK_6 
#define ORGGROVE_SKIN_RANK_1 106
#define ORGGROVE_SKIN_RANK_2 105
#define ORGGROVE_SKIN_RANK_3 107
#define ORGGROVE_SKIN_RANK_4 268
#define ORGGROVE_SKIN_RANK_5 271
#define ORGGROVE_SKIN_RANK_6 270
those are just skins for rank of grove street

i still got some warnings and 1 error:
PHP код:
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(637) : warning 202number of arguments does not match definition
C
:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(637) : warning 202number of arguments does not match definition
C
:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(638) : error 001expected token";"but found "-identifier-"
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(656) : warning 202number of arguments does not match definition
C
:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(656) : warning 202number of arguments does not match definition
C
:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(755) : warning 203symbol is never used"Org1Vozila"
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(755) : warning 203symbol is never used"PolicijaVozila"
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase
1 Error

Reply
#7

Ye sorry, Make the first line like that..

PHP код:
format(str,sizeof(str),"Admin %s ti je dao lidera organizacije Grove Street Families.",GetName(playerid)); 
and I guess that's all to remove the "error"
Reply
#8

Quote:
Originally Posted by JasonRiggs
Посмотреть сообщение
Ye sorry, Make the first line like that..

PHP код:
format(str,sizeof(str),"Admin %s ti je dao lidera organizacije Grove Street Families.",GetName(playerid)); 
and I guess that's all to remove the "error"
thank you very much. only got those warnings left. should they worry me?
btw +rep i luv u
Reply
#9

They should worry you a bit yeah, As it might cause some in game bugs, Show me the warnings with their lines please.
Reply
#10

PHP код:
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(637) : warning 202number of arguments does not match definition 
C
:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(637) : warning 202number of arguments does not match definition  
C
:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(656) : warning 202number of arguments does not match definition 
C
:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(656) : warning 202number of arguments does not match definition 
C
:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(755) : warning 203symbol is never used"Org1Vozila" 
C:\Program Files\Rockstar Games\GTA San Andreas\SAMP\Server\gamemodes\AdminPlugin.pwn(755) : warning 203symbol is never used"PolicijaVozila" 
Pawn compiler 3.2.3664              Copyright (c1997-2006ITB CompuPhase 
6 Warnings

line 637:
PHP код:
format(str,sizeof(str),"Admin %s ti je dao lidera organizacije Grove Street Families.",GetName(playerid)); 
lie 656: you fixed it moment ago
other 2 i know solution idc i never used them
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)