SA-MP Forums Archive
ID System - 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: ID System (/showthread.php?tid=81431)



ID System - JoeDaDude - 10.06.2009

Im making a new server which involves ID,
I have never in my life made an id system,
I cant find any tutorials and im wondering how i do it?
Does anyone have an example code like,
A setname command or setnamecolor command,
Just anything with a basic id system, as i cant find one nywhere


Re: ID System - JoeDaDude - 11.06.2009

Any help will be much appreciated,

EDIT: Sorry for double post


Re: ID System - yom - 11.06.2009

What do you mean exactly, i don't know what is a id system.


Re: ID System - JoeDaDude - 11.06.2009

Well instead of,
SendClientMessage(playerid, COLOR_WHITE, "You have been chosen for lottery");

That would send it only to player in which said the command,
But i want it to it sends it to whatever ID i put it,

Like,
/choose 4
It will send that message to ID 4,

But if /choose 7
It will send that message to ID 7,
And so on...


Re: ID System - wijnkamp - 12.06.2009

Код:
  if(strcmp(cmd, "/command", true) == 0 ) {

  tmp = strtok(cmdtext, idx);
  if(!strlen(tmp)) {
  SendClientMessage(playerid, COLOR_ERROR, "USAGE: /command (id)");
  return 1;
  }
  giveplayerid = strval(tmp);

  if(!IsNumeric(tmp)) {
  SendClientMessage(playerid, COLOR_ERROR, "USAGE: /command (id) ID Must be a number");
  return 1;
  }
	if (IsPlayerConnected(giveplayerid)) {
  
  SendClientMessage(giveplayerid, COLOR_ROYALBLUE, "your message");
  }
  else {
  format(string, sizeof(string), "ID (%d) Is not an active player", giveplayerid);
  SendClientMessage(playerid, COLOR_ERROR, string);
  }
  return 1;
  }
You wanted something like this ?


Re: ID System - JoeDaDude - 12.06.2009

i sorted now thts why i opened nutha about isplayerinvehicle