Admin Hiding detects commands as a unknown CMD
#1

Hey guys, I made a hide command though after typing up some admin commands seems to me that the commands work though a clientmessage is sent showing: You have entered a invalid command.

Does anyone know the case to this?

pawn Код:
public OnPlayerCommandPerformed( playerid, cmdtext [ ], success )
{
    if( success == 0 ) return SendError( playerid, "You have entered a invalid command." );
    return ( 1 );
}
Reply
#2

pawn Код:
public OnPlayerCommandPerformed( playerid, cmdtext [ ], success )
{
    if(!success) return SendError( playerid, "You have entered a invalid command." );
    return ( 1 );
}
Try this ?
Reply
#3

Quote:
Originally Posted by Darnell
Посмотреть сообщение
pawn Код:
public OnPlayerCommandPerformed( playerid, cmdtext [ ], success )
{
    if(!success) return SendError( playerid, "You have entered a invalid command." );
    return ( 1 );
}
Try this ?
' ! ' = false statement
' == 0 ' = false statement

They're the same, I would guess this is some bug i need to fix soon otherwise I need to remove the feature
Reply
#4

are you using
pawn Код:
return 0;
in the end of your commands (if in strcmp).
that would cause the problem too.
Reply
#5

PHP код:
forward OnPlayerCommandPerformed(playeridcmdtext[], success); 
public 
OnPlayerCommandPerformed(playeridcmdtext[], success

    if(!
successSendClientMessage(playeridCOLOR"You have entered a invalid command."); 
    return 
1

Try that, won't think it'll help, check if there's return 0; in the end of OnPlayerCommandText if you use strcmp.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)