SA-MP Forums Archive
plzz help me - 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: plzz help me (/showthread.php?tid=116662)



plzz help me - snabbo - 29.12.2009

Nederlands:
Hoi,

Ik vind een commando, maar ik kan niet vinden ...
Je Kunt misschien maakt het voor mij: - [
a / settime rcon commando voor ...
Dus zoon type opdracht: if (strcmp (cmdtext, "/ settime", true) == 0) liever niet zoon dcmd: - [

Bedankt!
snabbo: D

Engels:

hi,

I find a command but I can not find ...
You can maybe make it for me
a / settime rcon command for ...
So son type command: if (strcmp (cmdtext, "/ settime", true) == 0) prefer not son dcmd

Thanks!
snabbo


Re: plzz help me - GforceNL - 29.12.2009

Quote:
Originally Posted by snabbo
hoi,

Ik vind een commando, maar ik kan niet vinden ...
Je kunt misschien maakt het voor mij: - [
a / settime rcon commando voor ...
Dus zoon type opdracht: if (strcmp (cmdtext, "/ settime", true) == 0) liever niet zoon dcmd: - [

Bedankt!
snabbo: D
Dutch:

Misschien is het handiger om het in het engels te posten
Tis een Engels forum

English:
Perhaps you get more reply's iff you post it in English
its a english forum


Re: plzz help me - snabbo - 29.12.2009

ow sorry




Re: plzz help me - CJ101 - 29.12.2009

Код:
dcmd_settime(playerid,params[])
{
  new Index, tmp[80];
  tmp = strtok(params,Index);
  new time = strval(tmp);
  if(IsPlayerAdmin(playerid))
  {
  if(!strlen(params))
    {
    SendClientMessage(playerid,COLOR_RED,"Usage: /settime <time>");
    SendClientMessage(playerid,COLOR_RED,"Will set the time to the time you say.");
    return 1;
    }
	if(time > 24) return SendClientMessage(playerid,COLOR_RED,"Invalid time. Maximum time is 24.");
	for(new i = 0; i < MAX_PLAYERS; i++)
		{
		if(IsPlayerConnected(i)) SetPlayerTime(i,time,0);
		}
	}
	else
	{
	SendClientMessage(playerid,COLOR_RED,"You must be admin level 3 to do this.");
	}

	return 1;
}
Make sure you have strtok


Re: plzz help me - snabbo - 29.12.2009

not work...


Re: plzz help me - CJ101 - 29.12.2009

Put in OnPlayerCommandText

Код:
dcmd(settime,7,cmdtext);



Re: plzz help me - snabbo - 29.12.2009

Another son also can not command dcmd that I still hard (I've only just started)


Re: plzz help me - snabbo - 29.12.2009

not work :S
errors