SA-MP Forums Archive
Help me with this FS I made - 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: Help me with this FS I made (/showthread.php?tid=154706)



Help me with this FS I made - KDSTRP - 15.06.2010

Ok so i made a player joiner, it doesnt work. IDK why?
Код:
#include <a_samp>

#if defined FILTERSCRIPT

public OnFilterScriptInit()
{
	print("\n--------------------------------------");
	print(" PLAYER JOINER FILTERSCRIPT BY KDSTRP");
	print("--------------------------------------\n");
	return 1;
}

public OnFilterScriptExit()
{
	return 1;
}


public OnPlayerConnect(playerid)
{
  new string[64], pName[MAX_PLAYER_NAME];
  GetPlayerName(playerid,pName,MAX_PLAYER_NAME);
  format(string,sizeof string,"%s has joined Black Ops",pName);
  SendClientMessageToAll(#define COLOR_BLUE 0x0000BBAA,string);
  return 1;
}
I want it to look like: (EXAMPLE NAME) Has Joined ERP. (IP Address Here) I just dont know what else to add, cause im not really knowing to the IP Address Coding.


Re: Help me with this FS I made - Grim_ - 15.06.2010

pawn Код:
new string[64], name[MAX_PLAYER_NAME], ip[16];
GetPlayerName(playerid, name, sizeof(name));
GetPlayerIp(playerid, ip, sizeof(ip));
format(string, sizeof(string), "%s has joined black ops. (%s)", name, ip);
SendClientMessageToAll(COLOR_BLUE, string);



Re: Help me with this FS I made - Cameltoe - 15.06.2010

u should make it save ip adresses to a flat file or send to online admin only.


Re: Help me with this FS I made - FabianoC - 15.06.2010

well there was your code.


Re: Help me with this FS I made - RedCrownX - 16.10.2010

I have a Admin SYstem, Would this Count?

Код:
if(IsPlayerAdmin(playerid) == 1){
new string[64], name[MAX_PLAYER_NAME], ip[16];
GetPlayerName(playerid, name, sizeof(name));
format(string, sizeof(string), "%s has joined black ops. (%s)", name, ip);
SendClientMessageToAll(COLOR_BLUE, string);
}
I have Admininistration:3


Re: Help me with this FS I made - Austin - 16.10.2010

That is for RCON admin's.


Re: Help me with this FS I made - RedCrownX - 16.10.2010

I dont care.


Re: Help me with this FS I made - Austin - 16.10.2010

Hmmmm... ok then.


Re: Help me with this FS I made - RedCrownX - 16.10.2010

gooooooooood.