pawn Код:
public OnPlayerCommandText(playerid, cmdtext)
{
dcmd(kill,4,cmdtext);
return 0;
}
Now normally you'd write the command here... Below OnPlayerCommandText li
dcmd_kill(playerid, params[])
{
#pragma unused params
SetPlayerHealth(playerid, 0);
return 1;
}
instead, write the commands in another file, save it as pwn file. So it could be plcmds.pwn
So now it would look like this..
pawn Код:
public OnPlayerCommandText(playerid, cmdtext)
{
dcmd(kill,4,cmdtext);
return 0;
}
#include "gmfiles/plcmds.pwn"
That #include like assumes you create a folder with the plcmds.pwn file inside. its easier i find to do it that way, rather than clutter up the gamemode folder.