Jump to content

[Anti-Sobeit] NOP RemovePlayerFromVehicle simplu


MeNyX

Recommended Posts

Poate ati observat pe b-zone e posibil sa mergi cu un vehicul chiar daca nu esti in factiunea respectiva daca nulifici functia "RemovePlayerFromVehicle" prin intermediul la sobeit.

 

Pai astazi am gasit o solutie.


new ScoateID[MAX_PLAYERS]; 
public OnPlayerConnect(playerid)
{

    ScoateID[playerid] = 0; // Thanks Awesome
}
stock RemovePlayerFromVehicleEx(playerid)
{
	ScoateID[playerid] = GetPlayerVehicleID(playerid);
	RemovePlayerFromVehicle(playerid);
	return SetTimerEx("VerificaRemove", 1500, false, "i", playerid); //vom verifica peste 1,5 secunde deoarece dureaza 1,3 secunde ca personajul sa iasa din masina (animatia)
}
stock VerificaRemove(playerid)
{
	if(ScoateID[playerid] == GetPlayerVehicleID(playerid)) //daca el este inca in masina asta insemnand ca functia nu are efect pe el (sob)
	{
            Kick(playerid);
	}
	return 0;
}

Modificati pe oriunde aveati  RemovePlayerFromVehicle(playerid); in  RemovePlayerFromVehicleEx(playerid);

Y!M: menyx.official

Skype: menyx.official

 

 

Inainte de a critica o persoana indiferent de etnie/varsta/inteligenta ei uita-te la tine si nu uita ca toti suntem Oameni si ca nu are sens sa incerci sa pari diferit!Daca esti mai prost/destept decat cel scos/aflat in discutie incearca sa nu faci pe "MR. Inteligent" TACI si FACI!

Respecta membrii acestei comunitati daca ai pretentia sa fi respectat si tratat(a) ca pe o fiinta umana!

 

Nu fac nimic remarcabil, dar ceea ce fac este esenţial.•

 

Link to comment
Share on other sites

O medoda mai simpla:

new vehicleid = GetPlayerVehicleID(playerid);
   if(newstate == PLAYER_STATE_DRIVER && GetVehicleModel(vehicleid) == 596)
   {
      if(GetPlayerSkin(playerid) != 280)
      {
         SendClientMessage(playerid, COLOR_WHITE, "Ai primit kick pentru ca ai s0beit.");
         Kick(playerid);
      }
   }
Edited by Adrian_Petre

 

 

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.