Posts: 3,324
Threads: 96
Joined: Sep 2013
Quote:
Originally Posted by vannesenn
Your? Also, I frist wrote idea with ids, so also that's my idea/suggestion, not only yours.
|
Lol, your idea? No. The original topic on that in this thread was MY idea on more YCMD-like features, starting
here.
And in reply to that, YourShadow suggested this:
Quote:
Originally Posted by YourShadow
Maybe do something like this:
PHP Code:
cmd_id:pm(CMD_PM);
cmd:pm(playerid, params[])
{
return 1;
}
alias:pm("sms");
public OnPlayerCommandReceived(playerid, cmdtext[]) // executed before cmd
{
return 1;
}
public OnPlayerCommandPerformed(playerid, cmd[], params[], cmdid, result) // executed after cmd
{
if (result == -1)
{
SendClientMessage(playerid, 0xFFFFFFFF, "SERVER: Unknown command.");
return;
}
if (cmdid == CMD_PM)
{
//
}
// else if ...
}
?
|