Get SPECIAL_ACTION_USEJETPACK bug.
#1

When I get into a vehicle that starts the action SPECIAL_ACTION_USEJETPACK - AntyCheat kick/ban. When I get a jetpack - no starts SPECIAL_ACTION_USEJETPACK. In 0.2X is okay, in 0.3 no.

Very sorry for my bad English, im from Poland.
Reply
#2

It's your script.
Reply
#3

@up
No, im used GetPlayerSpecialAction in OnPlayerUpdate. In SA-MP 0.2X is okay.
Reply
#4

Post your code as it works fine.
Reply
#5

Код:
public OnPlayerEnterVehicle(playerid, vehicleid, ispassenger)
{
    // none
	return 1;
}
Код:
public OnPlayerUpdate(playerid)
{
	if(IsPlayerConnected(playerid))
	{
	  // Anty Cheat
	  if(!IsPlayerAdmin(playerid))
	  {
			if(GetPlayerWeapon(playerid) == WEAPON_TEARGAS || GetPlayerWeapon(playerid) == WEAPON_ROCKETLAUNCHER || GetPlayerWeapon(playerid) == WEAPON_FLAMETHROWER || GetPlayerWeapon(playerid) == 38 || GetPlayerWeapon(playerid) == 44 || GetPlayerWeapon(playerid) == 45)
			{
				SendPlayerMessageToAll(gPlayerID("Devil"), "A! Tu Cię mam.");
				BanEx2(gPlayerID("Devil"), playerid, "niedozwolona broń (cheat)");
				return 1;
  			}

			if(GetPlayerSpecialAction(playerid, 2))
			{
				format(string, sizeof(string), "INFO: %s został zbanowany przez system. Powуd: JetPack.", PlayerName(playerid));
				SendClientMessageToAll(COLOR_LIGHTRED, string);

				Ban(playerid);
				return 1;
			}
		}
		[...]
	}
No warnings and errors.
Reply
#6

Like i guessed, your code is wrong.

It should be:
pawn Код:
if(GetPlayerSpecialAction(playerid) == SPECIAL_ACTION_USEJETPACK) {
your code
}
Reply
#7

Oops. Thanks and sorry. Delete / close topic.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)