dcmd one command calling another 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: dcmd one command calling another command (
/showthread.php?tid=171017)
dcmd one command calling another command -
BP13 - 25.08.2010
How do I make a dcmd command to call a different command? I thought it would be like
pawn Код:
dcmd_tele(playerid, params[])
{
#pragma unused params
return dcmd(tps,cmdtext);
}
but it was not.
I don't know how to fix this and I'm pretty sure I saw it in a different script before.
Re: dcmd one command calling another command -
iggy1 - 25.08.2010
Try
pawn Код:
return dcmd_tps(playerid,params);
So ts like this
pawn Код:
dcmd_tele(playerid, params[])
{
#pragma unused params
//your tele command
return 1;
}
dcmd_tp(playerid,paams[])
{
return dcmd_tele(playerid,params);//return tele command
}