Поиск Anti Team Flash

Сообщения
256
Реакции
12
I am searching for anti team flash plugin. The one available on forum seems to be bugged & author has stopped the support for it. Can anyone please help me with a proper anti team flash plugin.
Thanks :)
 
Сообщения
702
Реакции
54
Код:
// Copyright © 2016 Vaqtincha

/**
*    Credits:
*    - Adidasman - за подсказки
*    - wopox1337 - за поддержку топика
*/


#include <amxmodx>
#include <reapi>

// const BLINDED_PARTLY = 200
// const BLINDED_FULLY = 255

public plugin_init()
{
    register_plugin("[ReAPI] No Team Flash lite", "0.0.3", "Vaqtincha")

    RegisterHookChain(RG_PlayerBlind, "PlayerBlind", .post = false)
}

public PlayerBlind(const index, const inflictor, const attacker, const Float:fadeTime, const Float:fadeHold, const alpha, Float:color[3])
{
    // server_print("INFLICTOR: %d", inflictor)
    if (index != attacker && get_member(index, m_iTeam) == get_member(attacker, m_iTeam))
    {
        if(Float:get_member(killer, m_blindStartTime) + Float:get_member(killer, m_blindFadeTime) - 6.0 < get_gametime()) // check if he is still blind or not
        {
            // don't let a 3rd party to know that this the player is blind
            set_member(index, m_blindAlpha, 0);
            //set_member(index, m_blindStartTime, 0);
            //set_member(index, m_blindHoldTime, 0);
            return HC_SUPERCEDE;
        }
    }

    return HC_CONTINUE;
}
or this
 
Сообщения
256
Реакции
12
Код:
// Copyright © 2016 Vaqtincha

/**
*    Credits:
*    - Adidasman - за подсказки
*    - wopox1337 - за поддержку топика
*/


#include <amxmodx>
#include <reapi>

// const BLINDED_PARTLY = 200
// const BLINDED_FULLY = 255

public plugin_init()
{
    register_plugin("[ReAPI] No Team Flash lite", "0.0.3", "Vaqtincha")

    RegisterHookChain(RG_PlayerBlind, "PlayerBlind", .post = false)
}

public PlayerBlind(const index, const inflictor, const attacker, const Float:fadeTime, const Float:fadeHold, const alpha, Float:color[3])
{
    // server_print("INFLICTOR: %d", inflictor)
    if (index != attacker && get_member(index, m_iTeam) == get_member(attacker, m_iTeam))
    {
        if(Float:get_member(killer, m_blindStartTime) + Float:get_member(killer, m_blindFadeTime) - 6.0 < get_gametime()) // check if he is still blind or not
        {
            // don't let a 3rd party to know that this the player is blind
            set_member(index, m_blindAlpha, 0);
            //set_member(index, m_blindStartTime, 0);
            //set_member(index, m_blindHoldTime, 0);
            return HC_SUPERCEDE;
        }
    }

    return HC_CONTINUE;
}
or this
Both are the same I guess... And I am using the same one on server. That's the one which is bugged
 
Сообщения
256
Реакции
12
Код:
// Copyright © 2016 Vaqtincha

/**
*    Credits:
*    - Adidasman - за подсказки
*    - wopox1337 - за поддержку топика
*/


#include <amxmodx>
#include <reapi>

// const BLINDED_PARTLY = 200
// const BLINDED_FULLY = 255

public plugin_init()
{
    register_plugin("[ReAPI] No Team Flash lite", "0.0.3", "Vaqtincha")

    RegisterHookChain(RG_PlayerBlind, "PlayerBlind", .post = false)
}

public PlayerBlind(const index, const inflictor, const attacker, const Float:fadeTime, const Float:fadeHold, const alpha, Float:color[3])
{
    // server_print("INFLICTOR: %d", inflictor)
    if (index != attacker && get_member(index, m_iTeam) == get_member(attacker, m_iTeam))
    {
        if(Float:get_member(killer, m_blindStartTime) + Float:get_member(killer, m_blindFadeTime) - 6.0 < get_gametime()) // check if he is still blind or not
        {
            // don't let a 3rd party to know that this the player is blind
            set_member(index, m_blindAlpha, 0);
            //set_member(index, m_blindStartTime, 0);
            //set_member(index, m_blindHoldTime, 0);
            return HC_SUPERCEDE;
        }
    }

    return HC_CONTINUE;
}
or this
I am so sorry Just figured out this was diffrent.. Will Give a try :)
 
Сообщения
256
Реакции
12
Код:
// Copyright © 2016 Vaqtincha

/**
*    Credits:
*    - Adidasman - за подсказки
*    - wopox1337 - за поддержку топика
*/


#include <amxmodx>
#include <reapi>

// const BLINDED_PARTLY = 200
// const BLINDED_FULLY = 255

public plugin_init()
{
    register_plugin("[ReAPI] No Team Flash lite", "0.0.3", "Vaqtincha")

    RegisterHookChain(RG_PlayerBlind, "PlayerBlind", .post = false)
}

public PlayerBlind(const index, const inflictor, const attacker, const Float:fadeTime, const Float:fadeHold, const alpha, Float:color[3])
{
    // server_print("INFLICTOR: %d", inflictor)
    if (index != attacker && get_member(index, m_iTeam) == get_member(attacker, m_iTeam))
    {
        if(Float:get_member(killer, m_blindStartTime) + Float:get_member(killer, m_blindFadeTime) - 6.0 < get_gametime()) // check if he is still blind or not
        {
            // don't let a 3rd party to know that this the player is blind
            set_member(index, m_blindAlpha, 0);
            //set_member(index, m_blindStartTime, 0);
            //set_member(index, m_blindHoldTime, 0);
            return HC_SUPERCEDE;
        }
    }

    return HC_CONTINUE;
}
or this
I tried the first one.. I got compile error

Код:
//AMXXPC compile.exe
// by the AMX Mod X Dev Team


//// rinfmain-noteamflash2.sma
//
// D:\Amx Versions\5406\pub1\rinfmain-noteamflash2.sma(28) : error 017: undefined symbol "killer"
//
// 1 Error.
// Could not locate output file D:\Amx Versions\5406\pub1\compiled\rinfmain-noteamflash2.amx (compile failed).
//
// Compilation Time: 0.19 sec
// ----------------------------------------

Press enter to exit ...
 
Сообщения
702
Реакции
54
pheronix, sorry, try this
Код:
// Copyright © 2016 Vaqtincha

/**
*    Credits:
*    - Adidasman - за подсказки
*    - wopox1337 - за поддержку топика
*/


#include <amxmodx>
#include <reapi>

// const BLINDED_PARTLY = 200
// const BLINDED_FULLY = 255

public plugin_init()
{
    register_plugin("[ReAPI] No Team Flash lite", "0.0.3", "Vaqtincha")

    RegisterHookChain(RG_PlayerBlind, "PlayerBlind", .post = false)
}

public PlayerBlind(const index, const inflictor, const attacker, const Float:fadeTime, const Float:fadeHold, const alpha, Float:color[3])
{
    // server_print("INFLICTOR: %d", inflictor)
    if (index != attacker && get_member(index, m_iTeam) == get_member(attacker, m_iTeam))
    {
        if(Float:get_member(index, m_blindStartTime) + Float:get_member(index, m_blindFadeTime) - 6.0 < get_gametime()) // check if he is still blind or not
        {
            // don't let a 3rd party to know that this the player is blind
            set_member(index, m_blindAlpha, 0);
            //set_member(index, m_blindStartTime, 0);
            //set_member(index, m_blindHoldTime, 0);
            return HC_SUPERCEDE;
        }
    }

    return HC_CONTINUE;
}
 

Пользователи, просматривающие эту тему

Сейчас на форуме нет ни одного пользователя.
Сверху Снизу