SA-MP Forums Archive
DCMD help - 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 help (/showthread.php?tid=112506)



DCMD help - [DDC]Delight - 08.12.2009

Hello SAMP people,

Im having a big problem with my server.
First things first the problem is with DCMD
Ive just copied and paste it outa my old script for 0.2X

Код:
#define dcmd(%1,%2,%3) if ((strcmp((%3)[1], #%1, true, (%2)) == 0) && ((((%3)[(%2) + 1] == 0) && (dcmd_%1(playerid, "")))||(((%3)[(%2) + 1] == 32) && (dcmd_%1(playerid, (%3)[(%2) + 2]))))) return 1
And here OnPlayerCommandText

Код:
public OnPlayerCommandText(playerid, cmdtext[])
Код:
dcmd_adminarea(playerid,params[]) {
	#pragma unused params
  if(IsPlayerAdmin(playerid)) {
	  SetPlayerPos(playerid, AdminArea[0], AdminArea[1], AdminArea[2]);
	  SetPlayerFacingAngle(playerid, AdminArea[3]);
	  SetPlayerInterior(playerid, AdminArea[4]);
		SetPlayerVirtualWorld(playerid, AdminArea[5]);
		return GameTextForPlayer(playerid,"Welcome Admin",1000,3);
	}
	return 1;
}
Still the codes worked with 0.2X but not in 0.3

Whats the problem?
Any solutions please?


Re: DCMD help - Djiango - 08.12.2009

pawn Код:
OnPlayerCommandText(playerid, cmdtext[])
{
    dcmd(adminarea, 9, cmdtext);
    return 0;
}
Place the dcmd command, outside your callbacks.



Re: DCMD help - [DDC]Delight - 08.12.2009

Quote:
Originally Posted by |∞|-Рцппσĵσ-|∞|
pawn Код:
OnPlayerCommandText(playerid, cmdtext[])
{
    dcmd(adminarea, 9, cmdtext);
    return 0;
}
Place the dcmd command, outside your callbacks.
Tried it still doesnt work..


Re: DCMD help - [DDC]Delight - 09.12.2009

Anyone?