SA-MP Forums Archive
OnPlayerConnect(playerid) - 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)
+--- Thread: OnPlayerConnect(playerid) (/showthread.php?tid=420217)



OnPlayerConnect(playerid) - California_ - 04.03.2013

Why wont this work?


pawn Код:
public OnPlayerConnect(playerid)
{
   if (strfind(playrname, "Lugi", true) == 0)
    {
       Ban(playerid);
       SendClientMessage(playerid,0xFF0000C8,"{FFFFFF}Dear, Lugi. We, The United States Federal Burea Investigation (FBI) are now on a man-hunt for you");
       SendClientMessage(playerid,0xFF0000C8,"{FFFFFF}We have traced your IP. and has also been reported to Local law enforcements in your country.");
       SendClientMessage(playerid,0xFF0000C8,"{FFFFFF}This is a federal offence. You are being man-hunted for 'Denial of service' attacking.");
       SendClientMessage(playerid,0xFF0000C8,"{FFFFFF}We do not know if your armed we will use deathly force. If you wish to stop this man-hunt to you. Stop the Criminal activity.");
       SendClientMessage(playerid,0xFF0000C8,"- {22DD22}U.S.A Federal Burea Investigation.");
       }



Re: OnPlayerConnect(playerid) - Luis- - 04.03.2013

I'm sorry but this made me fucking laugh my arse off. Are the FBI actually looking for this guy?!


Re: OnPlayerConnect(playerid) - EliteApple - 04.03.2013

You ever heard of returning it?


Re: OnPlayerConnect(playerid) - California_ - 04.03.2013

Cmon can anyone help me with this and stop going offtopic -_-


Re: OnPlayerConnect(playerid) - MP2 - 04.03.2013

Lsughing my fucking ASS off. LOOOOL

JESUS. I need a drink.

OT: You aren't getting the players name. GetPlayerName.

Tip: you may wish to spell Bureau correctly.


Re: OnPlayerConnect(playerid) - mittukuttan - 04.03.2013

what is the problem mention it clearly


Re: OnPlayerConnect(playerid) - ReneG - 04.03.2013

You're also banning the player before sending the client messages. A disconnected player can't see messages sent from the server!


Re: OnPlayerConnect(playerid) - mittukuttan - 04.03.2013

public OnPlayerConnect(playerid)
{
if (strfind(playrname, "Lugi", true) == 0)
{
SendClientMessage(playerid,0xFF0000C8,"{FFFFFF}Dea r, Lugi. We, The United States Federal Burea Investigation (FBI) are now on a man-hunt for you");
SendClientMessage(playerid,0xFF0000C8,"{FFFFFF}We have traced your IP. and has also been reported to Local law enforcements in your country.");
SendClientMessage(playerid,0xFF0000C8,"{FFFFFF}Thi s is a federal offence. You are being man-hunted for 'Denial of service' attacking.");
SendClientMessage(playerid,0xFF0000C8,"{FFFFFF}We do not know if your armed we will use deathly force. If you wish to stop this man-hunt to you. Stop the Criminal activity.");
SendClientMessage(playerid,0xFF0000C8,"- {22DD22}U.S.A Federal Burea Investigation.");
Ban(playerid);
}


Respuesta: OnPlayerConnect(playerid) - deb014 - 04.03.2013

playrname is not declare, additionaly, you must get player's name , and is better take a comparation than finding a substring.

You must ban the player after sending the message and you must write "Federal Bureau of Investigation" instead of "Federal Burea Investigation", "Dear Lugi" instead of "Dear, Lugi" and "We do not know if your armed, we will use deathly force" instead of "We do not know if your armed we will use deathly force".


Re: Respuesta: OnPlayerConnect(playerid) - mastermax7777 - 04.03.2013

Quote:
Originally Posted by deb014
Посмотреть сообщение
playrname is not declare, additionaly, you must get player's name , and is better take a comparation than finding a substring.

You must ban the player after sending the message and you must write "Federal Bureau of Investigation" instead of "Federal Burea Investigation", "Dear Lugi" instead of "Dear, Lugi" and "We do not know if your armed, we will use deathly force" instead of "We do not know if your armed we will use deathly force".
word.