SA-MP Forums Archive
SERVER: UNKNOWN COMMAND, ??? - 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)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: SERVER: UNKNOWN COMMAND, ??? (/showthread.php?tid=122196)



SERVER: UNKNOWN COMMAND, ??? - JoeDaDude - 20.01.2010

I have several commands on dcmd,
But ingame it just says Unknown Command?


Re: SERVER: UNKNOWN COMMAND, ??? - thiaZ_ - 20.01.2010

maybe you forget the return 1;

pawn Код:
dcmd_heal(playerid,params[])
{
  SetPlayerHealth(playerid,100.0);
  return 1;
}



Re: SERVER: UNKNOWN COMMAND, ??? - JoeDaDude - 20.01.2010

Nope not that, I would get loads of errors if i did


Re: SERVER: UNKNOWN COMMAND, ??? - Lajko1 - 20.01.2010

it was happening to me too,but i am sure it should be returns... return 1; etc


Re: SERVER: UNKNOWN COMMAND, ??? - thiaZ_ - 20.01.2010

yea, when i was using dcmd i it always executed the command first and after that it returned the message command is invalid blabla. im pretty sure that you have forgotten a return 1; otherwise you'll have to show your code here.

//: Are you sure you have return 1; too in your onplayercommandtext callback?
Quote:

Returns: Returning 0 in this callback will pass the command to another script or display 'SERVER: Unknown command' if there are no scripts to pass it on to




Re: SERVER: UNKNOWN COMMAND, ??? - JoeDaDude - 20.01.2010

Its nothing to do with any returns,


Re: SERVER: UNKNOWN COMMAND, ??? - boelie - 20.01.2010

Quote:

Its nothing to do with any returns

yes it does actually, can you show us a piece you have under onplayercommandtext ?


Re: SERVER: UNKNOWN COMMAND, ??? - Correlli - 20.01.2010

Post any of these commands.


Re: SERVER: UNKNOWN COMMAND, ??? - JoeDaDude - 20.01.2010

Quote:
Originally Posted by boelie
Quote:

Its nothing to do with any returns

yes it does actually, can you show us a piece you have under onplayercommandtext ?
Its nothing to do with returns,
If it was a returns problem then the command wouldnt show at all,
But it just says SERVER: UNKNOWN COMMAND, If it was returns,
It wouldnt do anything, It would just be blank,

One of my codes

pawn Код:
dcmd_kill(playerid, params[])
{
    #pragma unused params
    SetPlayerHealth(playerid, 0);
    return 1;
}



Re: SERVER: UNKNOWN COMMAND, ??? - JoeDaDude - 20.01.2010

Bumpetty Bump Bump