samp.directory
← Scripts y librerías

DevD4v3/antilag-inc

This library allows you to create zones where players can be shot directly at their skin

Librería★ 4actualizado sept 2025MITPawnArchivado
Abrir en GitHub

El autor archivó este repositorio, así que ya no se mantiene.

README.md

AntiLag-Inc

This library allows you to create zones where players can be shot directly at their skin.

Installation

Place the antilag.inc file in your /pawno/include/ directory:

#include <a_samp>
#include <antilag>

Macros

  • SetPlayerAntiLag – Enable or disable the skinshoot feature for a specific player.

    Example 1 (Enable skinshoot):

    SetPlayerAntiLag(playerid, true);
    

    Example 2 (Disable skinshoot):

    SetPlayerAntiLag(playerid, false);
    
  • IsPlayerAntiLag – Check if a player is currently in a skinshoot zone.

    Example 1 (Player is in a skinshoot zone):

    if(IsPlayerAntiLag(playerid))
    {
        print("The player is in a skinshoot zone");
    }
    

    Example 2 (Player is not in a skinshoot zone):

    if(!IsPlayerAntiLag(playerid))
    {
        print("The player is not in a skinshoot zone");
    }
    

Usage

Here’s a complete example using the Pawn.CMD command processor:

#include <a_samp>
#include <antilag>
#include <Pawn.CMD>

public OnPlayerCommandReceived(playerid, cmd[], params[], flags)
{
    if(IsPlayerAntiLag(playerid) && strcmp(cmd, "exitzone", true) != 0)
    {
        SendClientMessage(playerid, -1, "ERROR: You must use /exitzone to leave the skinshoot area.");
        return 0;
    }
    return 1;
}

cmd:antilag(playerid)
{
    if(IsPlayerAntiLag(playerid))
        return SendClientMessage(playerid, -1, "ERROR: You are already in a skinshoot zone.");
    
    SetPlayerAntiLag(playerid, true);
    SendClientMessage(playerid, -1, "You have entered a skinshoot area.");
    GivePlayerWeapon(playerid, 24, 500);
    return 1;
}

cmd:exitzone(playerid)
{
    if(!IsPlayerAntiLag(playerid))
        return SendClientMessage(playerid, -1, "ERROR: You are not in a skinshoot zone.");
    
    SetPlayerAntiLag(playerid, false);
    SpawnPlayer(playerid);
    return 1;
}

Credits

  • DevD4v3 – Main developer
  • SA-MP Team

grandgrand-theft-autogtaincludepawnsa-mpsa-mp-developmentsan-andreas-multiplayer

Esta página se genera con lo que GitHub publica sobre el repositorio. samp.directory no aloja el código. Informar de un problema con esta ficha

DevD4v3/antilag-inc: Librería de SA-MP | samp.directory