Raised This Month: $51 Target: $400
 12% 

add simple code to this plugin


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
generals
Senior Member
Join Date: Aug 2018
Old 03-20-2019 , 06:32   add simple code to this plugin
Reply With Quote #1

hi guys .. i have a simple request

how can enable "autoflash" and "autoflashswitch" and "autojump" on player by default . when join the server ..no need to enable this atributies
Can someone help?

PHP Code:
#pragma semicolon 1

//Include
#include <sourcemod>
#include <sdktools>
#include <sdkhooks>
#include <cstrike>
#include <smlib>
#undef REQUIRE_EXTENSIONS
#include <steamtools>
#undef REQUIRE_PLUGIN
#include <updater>

//Defines
#define MESS            "\x04[Trikz] \x01%t"
#define GAMEDESC        ""
#define dGAMEDESC        ""
#define SERVERTAG        ""
#define PLUGIN_VERSION     "1.0.0"
#define MAX_CLIENTS        64
#define MAX_BUFF        512
#define SMOKE_SPRITE    "materials/sprites/smoke.vmt"
#define EXPLOSION_SOUND    "/weapons/flashbang/flashbang_explode2.wav"
#define UPDATE_URL         "http://dl.dropbox.com/u/19991857/trikz/update.txt"

//Client Things
new autoswitch[MAX_CLIENTS];
new 
autoflash[MAX_CLIENTS];
new 
autojump[MAX_CLIENTS];
new 
crespawns[MAX_CLIENTS];
new 
nteleport[MAXPLAYERS+1];
new 
jteleport[MAXPLAYERS+1];
new 
bteleport[MAXPLAYERS+1];
new 
Float:lastrespawn[MAX_CLIENTS];
new 
Float:coords1[MAX_CLIENTS][3];
new 
Float:coords2[MAX_CLIENTS][3];
new 
g_iSmokeSprite = -1;

//Trikz Cvars
new Handle:sm_trikz_enableautoflash                INVALID_HANDLE;
new 
Handle:sm_trikz_enableautoflashswitch        INVALID_HANDLE;
new 
Handle:sm_trikz_settings                     INVALID_HANDLE;
new 
Handle:sm_trikz_airaccelerate                 INVALID_HANDLE;
new 
Handle:sm_trikz_ignoreradio                     INVALID_HANDLE;
new 
Handle:sm_trikz_override_gamedesc             INVALID_HANDLE;
new 
Handle:sm_trikz_add_servertag                 INVALID_HANDLE;
new 
Handle:sm_trikz_enableteleport                INVALID_HANDLE;
new 
Handle:sm_trikz_enableblock                     INVALID_HANDLE;
new 
Handle:sm_trikz_enableblockinvis            INVALID_HANDLE;
new 
Handle:sm_trikz_enablerespawn                INVALID_HANDLE;
new 
Handle:sm_trikz_version                         INVALID_HANDLE;
new 
Handle:sm_trikz_effects                         INVALID_HANDLE;
new 
Handle:sm_trikz_nofall                      INVALID_HANDLE;
new 
Handle:sm_trikz_autojump                    INVALID_HANDLE;
new 
Handle:sm_trikz_autoupdate                  INVALID_HANDLE;
new 
Handle:sm_trikz_respawnmin                  INVALID_HANDLE;
new 
Handle:sm_trikz_enableteleporttp            INVALID_HANDLE;
new 
Handle:sm_trikz_teleporttime                   INVALID_HANDLE;

//Cvars
new enableautoflash;
new 
enableautoflashswitch;
new 
settings;
new 
airaccelerate;
new 
ignoreradio;
new 
override_gamedesc;
new 
add_servertag;
new 
enableteleport;
new 
enableblock;
new 
enableblockinvis;
new 
enablerespawn;
new 
effects;
new 
enablenofall;
new 
enableautojump;
new 
autoupdate;
new    
respawnmin;
new    
enableteleporttp;
new    
Float:teleportinvis;

new 
ammoOffset = -1;
new 
m_hMyWeapons = -1;
new 
m_GroundEntity = -1;

new 
bool:g_UseSteamTools false;

//Plugin Info
public Plugin:myinfo 
{
    
name "Trikz",
    
author "johan123jo",
    
version PLUGIN_VERSION,
};

//Plugin Load
public OnPluginStart ()
{
    
LoadTranslations("common.phrases");
    
LoadTranslations("trikz.phrases");
    
    
RegConsoleCmd("sm_block",                Command_Block,            "Toggle blocking");
    
RegConsoleCmd("sm_respawn",                Command_Respawn,        "Respawn player");
    
RegConsoleCmd("sm_flash",                Command_Flash,            "Give 1 flashbang");
    
RegConsoleCmd("sm_autoflash",            Command_AutoFlash,        "Autoflash");
    
RegConsoleCmd("sm_autoflashswitch",        Command_AutoFlashSwitch,"Autoflash Switch");
    
RegConsoleCmd("sm_autojump",            Command_Autojump,        "AutoJump");
    
RegConsoleCmd("sm_save1",                Command_Save1,            "Save checkpoint 1");
    
RegConsoleCmd("sm_tele1",                Command_tele1,            "Teleport to checkpoint 1");
    
RegConsoleCmd("sm_save2",                Command_Save2,            "Save checkpoint 2");
    
RegConsoleCmd("sm_tele2",                Command_tele2,            "Teleport to checkpoint 2");
    
RegConsoleCmd("sm_teleport_noti",         Command_TeleNoti);
    
    
//Menus
    
RegConsoleCmd("sm_trikz",                Command_trikz,            "Show trikz menu");
    
RegConsoleCmd("sm_tpmenu",                Command_TPMenu,            "Show teleport menu");
    
RegConsoleCmd("sm_automenu",            Command_AutoMenu,        "Show Auto menu");
    
    
//Cvars
    
sm_trikz_enableautoflash        CreateConVar("sm_trikz_enableautoflash",        "1",             "Enable or disable autoflash command: 0 - disable, 1 - enable");
    
sm_trikz_enableautoflashswitch    CreateConVar("sm_trikz_enableautoflashswitch","1",             "Enable or disable autoflashswitch command (requires sm_trikz_enableautoflash to be 1): 0 - disable, 1 - enable");
    
sm_trikz_settings                 CreateConVar("sm_trikz_settings",                "1",             "Enable or disable trikz settings (Airaccelerate, flashboost, friendlyfire and bhopenable): 0 - disable, 1 - enable");
    
sm_trikz_airaccelerate             CreateConVar("sm_trikz_airaccelerate",        "999999",             "What should sv_airaccelerate  be (requires sm_trikz_settings to be 1)");
    
sm_trikz_ignoreradio             CreateConVar("sm_trikz_ignoreradio",            "1",             "Enable or disable grenade radio (Fire in the hole!): 1 - disable, 0 - enable");
    
sm_trikz_override_gamedesc         CreateConVar("sm_trikz_override_gamedesc",     "0",             "Enable or disable override of the game description (standard Counter-Strike: Source, override to SM_Trikz/Trikz): 0 - disable, 1 - enable");
    
sm_trikz_add_servertag             CreateConVar("sm_trikz_add_servertag",         "0",             "Enable or disable new server tag : \"Trikz\" : 0 - disable, 1 - enable");
    
sm_trikz_enableteleport         CreateConVar("sm_trikz_enableteleport",         "1",             "Enable or disable teleport menu/commands: 0 - disable, 1 - enable");
    
sm_trikz_enableblock             CreateConVar("sm_trikz_enableblock",             "1",             "Enable or disable block command (!trikz_block): 0 - disable, 1 - enable");
    
sm_trikz_enableblockinvis         CreateConVar("sm_trikz_enableblockinvis",     "1",             "Enable or disable invisibility when ghost (requires sm_trikz_enableblock to be 1): 0 - disable, 1 - enable");
    
sm_trikz_enablerespawn             CreateConVar("sm_trikz_enablerespawn",         "1",             "Enable or disable respawn command: 0 - disable, 1 - enable");
    
sm_trikz_effects                 CreateConVar("sm_trikz_effects",                "3",             "Enable or disable effects on flashbang explosions: 0 - disable, 1 - enable sparks, 2 - enable sound, 3 - enable sparks & sound");
    
sm_trikz_nofall                 CreateConVar("sm_trikz_nofall",                 "1",            "Enable or disable no fall damage: 0 - disable, 1 - enable");
    
sm_trikz_autojump                 CreateConVar("sm_trikz_autojump",             "1",             "Enable or disable auto jump (!trikz_autojump): 0 - disable, 1 - enable");
    
sm_trikz_autoupdate                CreateConVar("sm_trikz_autoupdate",             "1",             "Enable or disable autoupdate: 0 - disable, 1 - enable");
    
sm_trikz_respawnmin                CreateConVar("sm_trikz_respawnmin",             "2",             "How many times a player can respawn pr. minute. default 2 times pr. minute (requires sm_trikz_enablerespawn to be 1): 0 - disabled");
    
sm_trikz_enableteleporttp        CreateConVar("sm_trikz_enableteleporttp",        "1",             "Enable or disable that a player can teleport to another player (if the other player allows): 0 - disable, 1 - enable");
    
sm_trikz_teleporttime            CreateConVar("sm_trikz_teleporttime",            "5",             "How much time after 2 players has teleport to each other they should not collide (block each other)");
    
sm_trikz_version                 CreateConVar("sm_trikz_version",                 PLUGIN_VERSION"SM_Trikz plugin version (unchangeable)"FCVAR_PLUGIN|FCVAR_SPONLY|FCVAR_REPLICATED|FCVAR_NOTIFY);
    
    
HookConVarChange(sm_trikz_enableautoflash,             ConVarChange);
    
HookConVarChange(sm_trikz_enableautoflashswitch,     ConVarChange);
    
HookConVarChange(sm_trikz_settings,                 ConVarChange);
    
HookConVarChange(sm_trikz_airaccelerate,             ConVarChange);
    
HookConVarChange(sm_trikz_ignoreradio,                 ConVarChange);
    
HookConVarChange(sm_trikz_override_gamedesc,         ConVarChange);
    
HookConVarChange(sm_trikz_add_servertag,             ConVarChange);
    
HookConVarChange(sm_trikz_enableteleport,             ConVarChange);
    
HookConVarChange(sm_trikz_enableblock,                 ConVarChange);
    
HookConVarChange(sm_trikz_enableblockinvis,         ConVarChange);
    
HookConVarChange(sm_trikz_enablerespawn,             ConVarChange);
    
HookConVarChange(sm_trikz_effects,                     ConVarChange);
    
HookConVarChange(sm_trikz_nofall,                     ConVarChange);
    
HookConVarChange(sm_trikz_autojump,                 ConVarChange);
    
HookConVarChange(sm_trikz_autoupdate,                 ConVarChange);
    
HookConVarChange(sm_trikz_respawnmin,                 ConVarChange);
    
HookConVarChange(sm_trikz_enableteleporttp,         ConVarChange);
    
HookConVarChange(sm_trikz_teleporttime,             ConVarChange);
    
    
HookConVarChange(sm_trikz_versionVersionChange);

    
enableautoflash         GetConVarInt(sm_trikz_enableautoflash);
    
enableautoflashswitch     GetConVarInt(sm_trikz_enableautoflashswitch);
    
settings                 GetConVarInt(sm_trikz_settings);
    
airaccelerate             GetConVarInt(sm_trikz_airaccelerate);
    
ignoreradio             GetConVarInt(sm_trikz_ignoreradio);
    
override_gamedesc         GetConVarInt(sm_trikz_override_gamedesc);
    
add_servertag             GetConVarInt(sm_trikz_add_servertag);
    
enableteleport             GetConVarInt(sm_trikz_enableteleport);
    
enableblock             GetConVarInt(sm_trikz_enableblock);
    
enableblockinvis         GetConVarInt(sm_trikz_enableblockinvis);
    
enablerespawn             GetConVarInt(sm_trikz_enablerespawn);
    
effects                 GetConVarInt(sm_trikz_effects);
    
enablenofall             GetConVarInt(sm_trikz_nofall);
    
enableautojump             GetConVarInt(sm_trikz_autojump);
    
autoupdate                 GetConVarInt(sm_trikz_autoupdate);
    
respawnmin                GetConVarInt(sm_trikz_respawnmin);
    
enableteleporttp        GetConVarInt(sm_trikz_enableteleporttp);
    
teleportinvis            GetConVarFloat(sm_trikz_teleporttime);
    
    
AutoExecConfig(true"trikz");
    
    
HookEvent("player_spawn"Event_spawn);  
    
HookEvent("weapon_fire"Event_WeaponFire);
    
    
//Offsets
    
ammoOffset FindSendPropInfo("CCSPlayer""m_iAmmo");
    
    if(
ammoOffset == -1)
    {
        
SetFailState("Failed to find m_iAmmo offset");
    }
    
    
m_hMyWeapons FindSendPropOffs("CBasePlayer""m_hMyWeapons");  
    
    if(
m_hMyWeapons == -1)
    {
        
SetFailState("Failed to find m_hMyWeapons offset");
    }

    
m_GroundEntity FindSendPropOffs("CBasePlayer""m_hGroundEntity");
    
    if(
m_GroundEntity == -1)
    {
        
SetFailState("Failed to find m_hGroundEntity offset");
    }
}

public 
APLRes:AskPluginLoad2(Handle:myselfbool:lateString:error[], err_max)
{
    
MarkNativeAsOptional("Steam_SetGameDescription");
    return 
APLRes_Success;
}

public 
Action:Command_TeleNoti(clientargs)
{
    if(
enableteleporttp == 1)
    {
        if(
nteleport[client] == 0)
        {
            
nteleport[client] = 1;
            
            
PrintToChat(clientMESS"TZ teleporttp no longer notified");
        }
        else if(
nteleport[client] == 1)
        {
            
nteleport[client] = 0;
            
            
PrintToChat(clientMESS"TZ teleporttp notify me");
        }
    }

    return 
Plugin_Handled;
}

public 
Action:Command_TeleporttpMenu(clientargs)
{
    if(
enableteleporttp == 1)
    {
        if(
IsClientInGame(client) && IsPlayerAlive(client))
        {
            
decl String:name[32];
            
decl String:identifier[32];
            
            new 
Handle:menu CreateMenu(MenuHandler);
            
            if (
args == -1)
            {
                
SetMenuExitBackButton(menu,true);
            }
            
            
SetMenuTitle(menu"%t""TZ menu teleporttp");
            
            new 
count 0;
            
            for (new 
1<= MaxClientsi++)
            {
                if (
client != && IsClientInGame(i) && IsPlayerAlive(client) && !IsFakeClient(i) && !IsClientSourceTV(i))  
                {
                    
GetClientName(inamesizeof(name));
                    
Format(identifiersizeof(identifier), "%i"i);
                    
AddMenuItem(menuidentifiername);
                    
                    
count++;
                }
            }

            
SetMenuExitButton(menutrue);
            
            if(
count 0)
            {
                
DisplayMenu(menuclientMENU_TIME_FOREVER);
            }
            else
            {
                
PrintToChat(clientMESS"TZ teleporttp no players");
            }
        }
        else
        {
            
PrintToChat(clientMESS"TZ Dead");
        }
    }
    else
    {
        
PrintToChat(clientMESS"TZ Command disabled");
    }

    return 
Plugin_Handled;
}

public 
MenuHandler(Handle:menuMenuAction:actionparam1param2)
{
    
decl String:info[32];
    
decl String:name[32];
    
    
GetMenuItem(menuparam2infosizeof(info), _namesizeof(name));
    
    new 
client StringToInt(info);
    
    if(
action == MenuAction_Select)
    {
        if(
IsClientInGame(client) && IsPlayerAlive(client))
        {
            if(
nteleport[client] == 0)
            {
                
askmenu(clientparam1);
            }
            else
            {
                
PrintToChat(param1MESS"TZ teleporttp not allowed");
            }
        }
        else
        {
            
PrintToChat(param1MESS"TZ Dead");
        }
    }
    else if(
action == MenuAction_Cancel)
    {
        if (
param2 == MenuCancel_ExitBack)
        {
            
Command_trikz(param1,0);
        }
    }
    else if(
action == MenuAction_End)
    {
        
CloseHandle(menu);
    }
}

askmenu(clientclient2)
{
    if(
IsClientInGame(client) && IsPlayerAlive(client))
    {
        
decl String:buff[MAX_BUFF];
        new 
String:asker[255];
        
Format(askersizeof(asker), "%i"client2);
        
        new 
Handle:menu CreateMenu(handler_ask);
        
        
SetMenuTitle(menu"%t""TZ menu teleporttp ask"client2);
        
        
        
Format(buffsizeof(buff), "%t""TZ teleporttp menu allow",client);
        
AddMenuItem(menuaskerbuff);
        
        
Format(buffsizeof(buff), "%t""TZ teleporttp menu deny",client);
        
AddMenuItem(menuaskerbuff);
        
        
Format(buffsizeof(buff), "%t""TZ teleporttp menu allways deny",client);
        
AddMenuItem(menuaskerbuff);

        
SetMenuExitButton(menutrue);

        
DisplayMenu(menuclient30);
    }
}

public 
handler_ask(Handle:menuMenuAction:actionparam1param2)
{
    
decl String:info[32];
    
decl String:name[32];
    
    
GetMenuItem(menuparam2infosizeof(info), _namesizeof(name));
    
    new 
client StringToInt(info);
    
    if(
action == MenuAction_Select)
    {
        if(
IsClientInGame(param1) && IsPlayerAlive(param1))
        {
            switch(
param2)
            {
                case 
0:
                {
                    new 
Float:coords[3];
                    
                    
GetEntPropVector(param1Prop_Send"m_vecOrigin"coords);
                    
                    
TeleportEntity(clientcoordsNULL_VECTORNULL_VECTOR);
                    
                    
jteleport[param1]++;
                    
jteleport[client]++;
                    
                    
bteleport[client] = GetEntProp(clientProp_Data"m_CollisionGroup");
                    
bteleport[param1] = GetEntProp(param1Prop_Data"m_CollisionGroup");
                    
                    if(
bteleport[client] != 2)
                    {
                        
SetEntProp(clientProp_Data"m_CollisionGroup"2);
                    }
                    
                    if(
bteleport[param1] != 2)
                    {
                        
SetEntProp(param1Prop_Data"m_CollisionGroup"2);
                    }
                    
                    
CreateTimer(teleportinvisteleport_collideclient);
                    
CreateTimer(teleportinvisteleport_collideparam1);
                    
                    new 
String:s_time[255];
                    
                    
FloatToString(teleportinviss_timesizeof(s_time));
                    
                    new 
time StringToInt(s_time);
                    
                    
PrintToChat(clientMESS"TZ teleporttp collide for"time);
                }
                case 
1:
                {
                    
PrintToChat(clientMESS"TZ teleporttp request denied");
                }
                case 
2:
                {
                    
nteleport[param1] = 1;
                    
                    
PrintToChat(param1MESS"TZ teleporttp no longer notified");
                }
            }
        }
        else
        {
            
PrintToChat(clientMESS"TZ teleporttp asker no longer available");
        }
    }
    else if(
action == MenuAction_End)
    {
        
CloseHandle(menu);
    }
}


public 
Action:teleport_collide(Handle:timerany:client)
{
    if(
IsClientInGame(client) && IsPlayerAlive(client))
    {
        if(
jteleport[client] == 1)
        {        
            
SetEntProp(clientProp_Data"m_CollisionGroup"bteleport[client]);
            
            
PrintToChat(clientMESS"TZ teleporttp block setting reset");
            
            
            
jteleport[client] = 0;
        }
        else
        {
            
jteleport[client]--;
        }
    }
    else
    {
        
jteleport[client]--;
    }
}

public 
OnLibraryAdded(const String:name[])
{
    if(
autoupdate == && StrEqual(name"updater"))
    {
        
Updater_AddPlugin(UPDATE_URL);
    }
    
    if (
StrEqual(name"SteamTools"))
    {
        
g_UseSteamTools true;
    }
}

public 
OnLibraryRemoved(const String:name[])
{
    if(
autoupdate == && StrEqual(name"updater"))
    {
        
Updater_RemovePlugin();
    }
    
    if (
StrEqual(name"SteamTools"))
    {
        
g_UseSteamTools false;
    }
}

public 
OnAllPluginsLoaded()
{
    
g_UseSteamTools LibraryExists("SteamTools");
}

//Convar Change
public ConVarChange(Handle:cvar, const String:oldValue[], const String:newValue[])
{
    new 
nval StringToInt(newValue);
    
    if(
cvar == sm_trikz_enableautoflash)
    {
        
enableautoflash nval;
    }
    else if(
cvar == sm_trikz_enableautoflashswitch)
    {
        
enableautoflashswitch nval;
    }
    else if(
cvar == sm_trikz_settings)
    {
        if(
nval == 1)
        {
            
ServerCommand("sv_enablebunnyhopping 1");
            
ServerCommand("sv_enableboost 1");
            
ServerCommand("mp_friendlyfire 0");
            
ServerCommand("sv_airaccelerate %i"airaccelerate);
        }
    }
    else if(
cvar == sm_trikz_airaccelerate)
    {
        if(
GetConVarInt(sm_trikz_settings) == 1)
        {
            
ServerCommand("sv_airaccelerate %i"nval);
        }
    }
    else if(
cvar == sm_trikz_ignoreradio)
    {
        if(
nval == 1)
        {
            
ServerCommand("sv_ignoregrenaderadio 1");
        }
    }
    else if(
cvar == sm_trikz_override_gamedesc)
    {
        if(
nval == 1)
        {
            
override_gamedesc 1;
            
            if(
g_UseSteamTools)
            {
                new 
String:game_override[255];
                
Format(game_overridesizeof(game_override), GAMEDESC);
                
Steam_SetGameDescription(game_override);
            }
        }
        else
        {
            
override_gamedesc 0;
            
            if(
g_UseSteamTools)
            {
                new 
String:game_override[255];
                
Format(game_overridesizeof(game_override), dGAMEDESC);
                
Steam_SetGameDescription(game_override);
            }
        }
    }
    else if(
cvar == sm_trikz_add_servertag)
    {
        if(
nval == 1)
        {
            
ServerCommand("sv_tags %s\n"SERVERTAG);
        }
    }
    else if(
cvar == sm_trikz_enableteleport)
    {
        
enableteleport nval;
    }
    else if(
cvar == sm_trikz_enableblock)
    {
        
enableblock nval;
    }
    else if(
cvar == sm_trikz_enableblockinvis)
    {
        
enableblockinvis nval;
        
        if(
nval == 0)
        {
            for (new 
1<= MaxClientsi++)
            {
                if (
IsClientInGame(i) && IsPlayerAlive(i) && != 0)
                {
                    
CreateInvis(i255);
                }
            }
        }
    }
    else if(
cvar == sm_trikz_enablerespawn)
    {
        
enablerespawn nval;
    }
    else if(
cvar == sm_trikz_effects)
    {
        
effects nval;
    }
    else if(
cvar == sm_trikz_nofall)
    {
        
enablenofall nval;
    }
    else if(
cvar == sm_trikz_autojump)
    {
        
enableautojump nval;
        
        if(
nval == 0)
        {
            for (new 
1<= MaxClientsi++)
            {
                if (
IsClientInGame(i) && IsPlayerAlive(i) && != 0)
                {
                    
autojump[i] = 0;
                }
            }
        }
    }
    else if(
cvar == sm_trikz_autoupdate)
    {
        if(
nval == 1)
        {
            if(
autoupdate == 0)
            {
                
Updater_AddPlugin(UPDATE_URL);
            }
        }
        else if(
nval == 0)
        {
            if(
autoupdate == 1)
            {
                
Updater_RemovePlugin();
            }
        }
        
        
autoupdate nval;
    }
    else if(
cvar == sm_trikz_respawnmin)
    {
        
respawnmin nval;
    }
    else if(
cvar == sm_trikz_enableteleporttp)
    {
        
enableteleporttp nval;
    }
    else if(
cvar == sm_trikz_teleporttime)
    {
        
teleportinvis StringToFloat(newValue);
    }
}

//Version Change
public VersionChange(Handle:convar, const String:oldValue[], const String:newValue[])
{
    
SetConVarString(convarPLUGIN_VERSION);
}

//Configs load
public OnConfigsExecuted()
{    
    if(
override_gamedesc == && g_UseSteamTools)
    {
        new 
String:game_override[255];
        
Format(game_overridesizeof(game_override), GAMEDESC);
        
Steam_SetGameDescription(game_override);
    }
    
    if(
ignoreradio == 1)
    {
        
ServerCommand("sv_ignoregrenaderadio 1");
    }
    
    if(
settings == 1)
    {
        
ServerCommand("sv_enablebunnyhopping 1");
        
ServerCommand("sv_enableboost 1");
        
ServerCommand("mp_friendlyfire 0");
        
ServerCommand("sv_airaccelerate %i"airaccelerate);
    }
    
    if(
add_servertag == 1)
    {
        
ServerCommand("sv_tags %s\n"SERVERTAG);
    }
}

//On Map Start
public OnMapStart()
{
    
g_iSmokeSprite PrecacheModel(SMOKE_SPRITE);
    
    
PrecacheSound(EXPLOSION_SOUNDtrue);

    for (new 
i=1i<=MaxClientsi++)
    {
        
coords1[i][0] = 0.0;
        
coords1[i][1] = 0.0;
        
coords1[i][2] = 0.0;
        
coords2[i][0] = 0.0;
        
coords2[i][1] = 0.0;
        
coords2[i][2] = 0.0;
    }
}

// Trikz Menu options?
public Action:Command_trikz(clientargs)
{
    if (
client && IsClientInGame(client) && !IsFakeClient(client))
    {
        
decl String:buff[MAX_BUFF];
        
        new 
Handle:menu CreateMenu(MenuHandler_trikz);
        
        
SetMenuTitle(menu"%t""TZ menu title");
        
        
Format(buff,sizeof(buff),"%t","TZ menu flash",client);
        
AddMenuItem(menu,"sm_trikz_flash",buff);
        
        if(
enableautoflash == 1)
        {
            
Format(buff,sizeof(buff),"%t","TZ menu auto title",client);
            
AddMenuItem(menu,"sm_trikz_automenu",buff);
        }
        else
        {
            
Format(buff,sizeof(buff),"%t","TZ menu auto title disabled",client);
            
AddMenuItem(menu,"sm_trikz_automenu",buff);
        }
        
        if(
enableblock == 1)
        {
            
Format(buff,sizeof(buff),"%t","TZ menu block",client);
            
AddMenuItem(menu,"sm_trikz_block",buff);
        }
        else
        {
            
Format(buff,sizeof(buff),"%t","TZ menu block disabled",client);
            
AddMenuItem(menu,"sm_trikz_block",buff);
        }
        
        if(
enableautojump == 1)
        {
            
Format(buff,sizeof(buff),"%t","TZ menu autojump",client);
            
AddMenuItem(menu,"sm_trikz_autojump",buff);
        }
        else
        {
            
Format(buff,sizeof(buff),"%t","TZ menu autojump disabled",client);
            
AddMenuItem(menu,"sm_trikz_autojump",buff);
        }
        
        if(
enableteleport == 1)
        {
            
Format(buff,sizeof(buff),"%t","TZ menu checkpoints",client);
            
AddMenuItem(menu,"sm_trikz_tpmenu",buff);
        }
        else
        {
            
Format(buff,sizeof(buff),"%t","TZ menu checkpoints disabled",client);
            
AddMenuItem(menu,"sm_trikz_tpmenu",buff);
        }
        
        if(
enableteleporttp == 1)
        {
            
Format(buff,sizeof(buff),"%t","TZ menu teleporttp",client);
            
AddMenuItem(menu,"sm_trikz_teleporttp",buff);
        }
        else
        {
            
Format(buff,sizeof(buff),"%t","TZ menu teleporttp disabled",client);
            
AddMenuItem(menu,"sm_trikz_teleporttp",buff);
        }
        
        if(
enablerespawn == 1)
        {
            
Format(buff,sizeof(buff),"%t","TZ menu respawn",client);
            
AddMenuItem(menu,"sm_trikz_respawn",buff);
        }
        else
        {
            
Format(buff,sizeof(buff),"%t","TZ menu respawn disabled",client);
            
AddMenuItem(menu,"sm_trikz_respawn",buff);
        }
        
        
DisplayMenu(menuclientMENU_TIME_FOREVER);
    }
    
    return 
Plugin_Handled;
}

// Trikz Funcs
public MenuHandler_trikz(Handle:menuMenuAction:actionparam1param2)
{
    if (
action == MenuAction_Select)
        switch (
param2)
    {
        case 
0:
        {
            
Command_Flash(param1,0);
            
Command_trikz(param1,-1);
        }
        case 
1:
        {
            if(
enableautoflash == 1)
            {
                
Command_AutoMenu(param1,-1);
            }
            else
            {
                
PrintToChat(param1MESS"TZ Command disabled");
            }
        }
        case 
2:
        {
            if(
enableautoflash == 1)
            {
                
Command_Block(param1,-1);
                
Command_trikz(param1,-1);
            }
            else
            {
                
Command_trikz(param1,-1);
                
PrintToChat(param1MESS"TZ Command disabled");
            }
        }
        case 
3:
        {
            if(
enableautojump == 1)
            {
                
Command_Autojump(param1,-1);
                
Command_trikz(param1,-1);
            }
            else
            {
                
Command_trikz(param1,-1);
                
PrintToChat(param1MESS"TZ Command disabled");
            }
        }
        case 
4:
        {
            if(
enableteleport == 1)
            {
                
Command_TPMenu(param1,-1);
            }
            else
            {
                
Command_trikz(param1,-1);
                
PrintToChat(param1MESS"TZ Command disabled");
            }
        }
        case 
5:
        {
            if(
enableteleporttp == 1)
            {
                
Command_TeleporttpMenu(param1,-1);
            }
            else
            {
                
Command_trikz(param1,-1);
                
PrintToChat(param1MESS"TZ Command disabled");
            }
        }
        case 
6:
        {
            if(
enablerespawn == 1)
            {
                
Command_Respawn(param1,0);
                
Command_trikz(param1,-1);
            }
            else
            {
                
Command_trikz(param1,-1);
                
PrintToChat(param1MESS"TZ Command disabled");
            }
        }
    } 
    else if(
action == MenuAction_End)
    {
        
CloseHandle(menu);
    }
}

//AutoMenu
public Action:Command_AutoMenu(clientargs)
{
    if (
client && IsClientInGame(client) && !IsFakeClient(client))
    {
        if(
enableautoflash == 1)
        {
            
decl String:buff[MAX_BUFF];
            
            new 
Handle:menu CreateMenu(MenuHandler_auto);
            if (
args == -1SetMenuExitBackButton(menu,true);
            
            
SetMenuTitle(menu"%t""TZ menu auto title");
        
            
Format(buff,sizeof(buff),"%t","TZ menu autoflash",client);
            
AddMenuItem(menu,"sm_trikz_autoflash",buff);
            
            if(
enableautoflashswitch == && enableautoflash == 1)
            {
                
Format(buff,sizeof(buff),"%t","TZ menu autoflash switch",client);
                
AddMenuItem(menu,"sm_trikz_autoflashswitch",buff);
            }
            else
            {
                
Format(buff,sizeof(buff),"%t","TZ menu autoflash switch disabled",client);
                
AddMenuItem(menu,"sm_trikz_autoflashswitch",buff);
            }
        
            
DisplayMenu(menuclientMENU_TIME_FOREVER);
        }
        else
        {
            
PrintToChat(clientMESS"TZ Command disabled");
        }
    }
    
    return 
Plugin_Handled;
}

//Auto Funcs
public MenuHandler_auto(Handle:menuMenuAction:actionparam1param2)
{
    switch (
action)
    {
        case 
MenuAction_Select :
        switch (
param2)
        {
            case 
:
            {
                if(
enableautoflash == 1)
                {
                    
Command_AutoFlash(param1,0);
                }
                else
                {
                    
PrintToChat(param1MESS"TZ Command disabled");
                }
                
                
Command_AutoMenu(param1,-1);
            }
            case 
:
            {
                if(
enableautoflashswitch == 1)
                {
                    
Command_AutoFlashSwitch(param1,0);
                }
                else
                {
                    
PrintToChat(param1MESS"TZ Command disabled");
                }
                
                
Command_AutoMenu(param1,-1);
            }
        }
        case 
MenuAction_Cancel :
        if (
param2 == MenuCancel_ExitBackCommand_trikz(param1,0);
        
        case 
MenuAction_End :
        
CloseHandle(menu);
    }
}

public 
Action:Command_TPMenu(clientargs)
{
    if(
enableteleport == 1)
    {
        if (
client && IsClientInGame(client) && !IsFakeClient(client))
        {
            
decl String:buff[MAX_BUFF];
            
            new 
Handle:menu CreateMenu(MenuHandler_TPMenu);
            if (
args == -1SetMenuExitBackButton(menu,true);
            
            
SetMenuTitle(menu"%t""TZ menu checkpoints");
            
            if(
enableteleport == 1)
            {
                
Format(buff,sizeof(buff),"%t","TZ menu save 1",client);
                
AddMenuItem(menu,"sm_save1",buff);
                
                
Format(buff,sizeof(buff),"%t","TZ menu teleport 1",client);
                
AddMenuItem(menu,"sm_tele1",buff);
            }
            else
            {
                
Format(buff,sizeof(buff),"%t","TZ menu save 1 disabled",client);
                
AddMenuItem(menu,"sm_save1",buff);
                
                
Format(buff,sizeof(buff),"%t","TZ menu teleport 1 disabled",client);
                
AddMenuItem(menu,"sm_tele1",buff);
            }
            
            
            
AddMenuItem(menu,"sep","",ITEMDRAW_SPACER);
            
            
            if(
enableteleport == 1)
            {
                
Format(buff,sizeof(buff),"%t","TZ menu save 2",client);
                
AddMenuItem(menu,"sm_save2",buff);
                
                
Format(buff,sizeof(buff),"%t","TZ menu teleport 2",client);
                
AddMenuItem(menu,"sm_tele2",buff);
            }
            else
            {
                
Format(buff,sizeof(buff),"%t","TZ menu save 2 disabled",client);
                
AddMenuItem(menu,"sm_save2",buff);
                
                
Format(buff,sizeof(buff),"%t","TZ menu teleport 2 disabled",client);
                
AddMenuItem(menu,"sm_tele2",buff);
            }
            
            
DisplayMenu(menuclientMENU_TIME_FOREVER);
        }
    }
    else
    {
        
PrintToChat(clientMESS"TZ Command disabled");
    }
    
    return 
Plugin_Handled;
}

//Teleport Funcs
public MenuHandler_TPMenu(Handle:menuMenuAction:actionparam1param2)
{
    switch (
action)
    {
        case 
MenuAction_Select :
        switch (
param2)
        {
            case 
:
            {
                
Command_Save1(param1,0);
                
Command_TPMenu(param1,-1);
            }
            case 
:
            {
                
Command_tele1(param1,0);
                
Command_TPMenu(param1,-1);
            }
            case 
:
            {
                
Command_Save2(param1,0);
                
Command_TPMenu(param1,-1);
            }
            case 
:
            {
                
Command_tele2(param1,0);
                
Command_TPMenu(param1,-1);
            }
        }
        case 
MenuAction_Cancel :
        if (
param2 == MenuCancel_ExitBackCommand_trikz(param1,0);
        
        case 
MenuAction_End :
        
CloseHandle(menu);
    }
}

//Autojump command
public Action:Command_Autojump(clientargs)
{
    if(
enableautojump == 1)
    {
        if(
autojump[client] == 1)
        {
            
autojump[client] = 0;
            
PrintToChat(clientMESS"TZ autojump off");
        }
        else if(
autojump[client] == 0)
        {
            
autojump[client] = 1;
            
PrintToChat(clientMESS"TZ autojump on");
        }
    }
    else
    {
        
PrintToChat(clientMESS"TZ Command disabled");
    }

    return 
Plugin_Handled;
}

//Block
public Action:Command_Block(clientargs)
{
    if(
enableblock == 1)
    {
        if (
IsPlayerAlive(client))
        {
            new 
col GetEntProp(clientProp_Data"m_CollisionGroup");
            
            if (
col == 5)
            {
                if(
jteleport[client] >= 1)
                {
                    
bteleport[client] = 2;
                    
                    
PrintToChat(clientMESS"TZ teleporttp block setting later");
                }
                else
                {
                    
SetEntProp(clientProp_Data"m_CollisionGroup"2);
                    
PrintToChat(clientMESS"TZ block off");
                    
                    if(
enableblockinvis == 1)
                    {
                        
CreateInvis(client100);
                    }
                }
            }
            else
            {
                if(
jteleport[client] >= 1)
                {
                    
bteleport[client] = 5;
                    
                    
PrintToChat(clientMESS"TZ teleporttp block setting later");
                }
                else
                {
                    
SetEntProp(clientProp_Data"m_CollisionGroup"5);
                    
PrintToChat(clientMESS"TZ block on");
                        
                    if(
enableblockinvis == 1)
                    {
                        
CreateInvis(client255);
                    }
                }
            }
        }
        else
        {
            
PrintToChat(clientMESS"TZ Dead");
        }
    }
    else
    {
        
PrintToChat(clientMESS"TZ Command disabled");
    }
    
    return 
Plugin_Handled;
}

// Respawn
public Action:Command_Respawn(clientargs)
{
    if(
enablerespawn == 1)
    {
        if (
IsClientInGame(client) && !IsFakeClient(client) && GetClientTeam(client) > 1)
        {
            if(
respawnmin != 0)
            {
                if(
crespawns[client] >= respawnmin)
                {
                    new 
Float:currenttime lastrespawn[client] + 60.0;
                    
                    if(
currenttime GetTickedTime())
                    {
                        
PrintToChat(clientMESS"TZ respawn min"respawnmin);
                        
                        return 
Plugin_Handled;
                    }
                    else
                    {
                        
lastrespawn[client] = GetTickedTime();
                        
crespawns[client]     = 1;
                    }
                }
                else
                {
                    
lastrespawn[client] = GetTickedTime();
                    
crespawns[client]++;
                }
            }
                
            
CS_RespawnPlayer(client);
            
PrintToChat(clientMESS"TZ respawn");
        }
        else
        {
            
PrintToChat(clientMESS"TZ Spec respawn");
        }
        return 
Plugin_Handled;
    }
    else
    {
        
PrintToChat(clientMESS"TZ Command disabled");
    }
    
    return 
Plugin_Handled;
}

//Weapon Fire
public Action:Event_WeaponFire(Handle:event, const String:name[], bool:dontBroadcast)
{
    new 
client GetClientOfUserId(GetEventInt(event,"userid"));
    
decl String:weapon[MAX_BUFF];
    
GetEventString(event,"weapon",weapon,sizeof(weapon));
    
    if (
StrEqual(weapon,"flashbang"))
    {
        if(
autoflash[client])
        {
            
give(client);
            
            if(
autoswitch[client] == 1)
            {
                
CreateTimer(0.15selectfclient);
            }
        }
    }
}

public 
Action:selectf(Handle:timerany:client)
{
    
FakeClientCommand(client"use weapon_knife");
    
FakeClientCommand(client"use weapon_flashbang");
}

//Flashbang created
public OnEntityCreated(edict, const String:classname[])
{
    if (
IsValidEdict(edict) && IsValidEntity(edict) && StrEqual(classname"flashbang_projectile"))
    {
        
CreateTimer(1.2Timer_RemoveFlashbangedict);
    }
}

//Remove Flashbang
public Action:Timer_RemoveFlashbang(Handle:timerany:edict)
{
    
decl String:classname[MAX_BUFF];
    
GetEdictClassname(edict,classname,sizeof(classname));
    if (!
IsValidEdict(edict) || !IsValidEntity(edict) || !StrEqual(classname"flashbang_projectile"))
    {
        return 
Plugin_Stop;
    }
    if(
effects != 0)
    {
        new 
Float:fPos[3];
        
GetEntPropVector(edictProp_Send"m_vecOrigin"fPos);
        
        if(
effects == 1)
        {
            
TE_SetupSparks(fPosNULL_VECTOR12);
            
TE_SendToAll();
            
TE_SetupSmoke(fPosg_iSmokeSprite1.015);
            
TE_SendToAll();
        }
        else if(
effects == 2)    
        {
            
EmitAmbientSound(EXPLOSION_SOUNDfPos);
        }
        else if(
effects == 3)
        {
            
TE_SetupSparks(fPosNULL_VECTOR12);
            
TE_SendToAll();
            
TE_SetupSmoke(fPosg_iSmokeSprite1.015);
            
TE_SendToAll();
            
            
EmitAmbientSound(EXPLOSION_SOUNDfPos);
        }
    }
    
    
AcceptEntityInput(edict"Kill");
    return 
Plugin_Stop;
}

//Command Flash
public Action:Command_Flash(clientargs)
{
    if (
IsPlayerAlive(client))
    {
        if (
client && IsClientInGame(client) && !IsFakeClient(client))
        {
            if(
autoflash[client])
            {
                
PrintToChat(clientMESS"TZ autoflash flash");
            }
            else
            {
                new 
flashbangs GetClientFlashBangs(client);
                
                if(
flashbangs >= 2)
                {
                    
PrintToChat(clientMESS"TZ flashbangs");
                }
                else
                {
                    
PrintToChat(clientMESS"TZ flash");
                    
give(client);
                }
            }
        }
    }
    else
    {
        
PrintToChat(clientMESS"TZ Dead");
    }
    return 
Plugin_Handled;
}

//Autoflash
public Action:Command_AutoFlash(clientargs)
{
    if(
enableautoflash == 1)
    {
        
auto(client0);
        return 
Plugin_Handled;
    }
    else
    {
        
PrintToChat(clientMESS"TZ Command disabled");
    }
    
    return 
Plugin_Handled;
}

//AutoflashSwitch
public Action:Command_AutoFlashSwitch(clientargs)
{
    if(
enableautoflashswitch == && enableautoflash == 1)
    {
        
auto(client1);
        return 
Plugin_Handled;
    }
    else
    {
        
PrintToChat(clientMESS"TZ Command disabled");
    }
    
    return 
Plugin_Handled;
}

auto(clientopt)
{
    if(
IsPlayerAlive(client))
    {
        if(
opt == 1)
        {
            if(
autoswitch[client] == 1)
            {
                
autoswitch[client] = 0;
                
                
PrintToChat(clientMESS"TZ autoflashswitch off");
            }
            else
            {
                
autoswitch[client] = 1;
                
                
PrintToChat(clientMESS"TZ autoflashswitch on");
                
                if(
autoflash[client] == 0)
                {
                    
autoflash[client] = 1;
                    
PrintToChat(clientMESS"TZ autoflash on");
                
                    if(
GetClientFlashBangs(client) == 0)
                    {
                        
give(client);
                    }
                }
                
                new 
String:weapon_name[255];
    
                
GetClientWeapon(clientweapon_namesizeof(weapon_name));
                    
                if(
strcmp(weapon_name"weapon_flashbang") == 1)
                {
                    
CreateTimer(0.15selectfclient);
                }
            }
        }
        else
        {
            if(
autoflash[client] == 1)
            {
                
autoflash[client] = 0;
                
PrintToChat(clientMESS"TZ autoflash off");
                
                if(
autoswitch[client] == 1)
                {
                    
autoswitch[client] = 0;
                    
PrintToChat(clientMESS"TZ autoflashswitch off");
                }
            }
            else
            {
                
autoflash[client] = 1;
                
PrintToChat(clientMESS"TZ autoflash on");
                
                if(
GetClientFlashBangs(client) == 0)
                {
                    
give(client);
                }
            }
        }
    }
    else
    {
        
PrintToChat(clientMESS"TZ Dead");
    }
}

//Client Put Server
public OnClientPutInServer(client)
{
    if(
enablenofall == 1)
    {
        
SDKHook(clientSDKHook_OnTakeDamageOnTakeDamage);
    }
    
    
CreateTimer(5.0welcomeclient);
}

//Welcome
public Action:welcome(Handle:timerany:client)
{
    if(
IsClientInGame(client) && !IsFakeClient(client))
    {
        
PrintToChat(clientMESS"TZ autohi");
    }
    
    return 
Plugin_Stop;
}

//Spawn
public Action:Event_spawn(Handle:event, const String:name[], bool:dontBroadcast)
{
    new 
client GetClientOfUserId(GetEventInt(event,"userid"));
    
    if(
GetClientTeam(client) >= 2)
    {
        
strip(client);
    }
}

//Save1 Loc
public Action:Command_Save1(clientargs)
{
    if(
enableteleport == 1)
    {
        if (
IsPlayerAlive(client))
        {
            if (
GetEntDataEnt2(clientm_GroundEntity) != -1)
            {
                
GetEntPropVector(clientProp_Send"m_vecOrigin"coords1[client]);
                
PrintToChat(clientMESS"TZ save 1");
            }
            else
            {
                
PrintToChat(clientMESS"TZ Ground");
            }
        }
        else
        {
            
PrintToChat(clientMESS"TZ Dead");
        }
    }
    
    
    return 
Plugin_Handled;
}

//Teleport1
public Action:Command_tele1(clientargs)
{    if(
enableteleport == 1)
    {
        if (
IsPlayerAlive(client))
        {
            if(!(
coords1[client][0] == 0.0 && coords1[client][1] == 0.0 && coords1[client][2] == 0.0))
            {
                
TeleportEntity(clientcoords1[client], NULL_VECTORNULL_VECTOR);
                
PrintToChat(clientMESS"TZ teleport 1");
            }
            else
            {
                
PrintToChat(clientMESS,"TZ no teleport");
            }
        }
        else
        {
            
PrintToChat(clientMESS"TZ Dead");
        }
    }
    
    return 
Plugin_Handled;
}

//Save2 Loc
public Action:Command_Save2(clientargs)
{    if(
enableteleport == 1)
    {
        if (
IsPlayerAlive(client))
        {
            if (
GetEntDataEnt2(clientm_GroundEntity) != -1)
            {
                
GetEntPropVector(clientProp_Send"m_vecOrigin"coords2[client]);
                
PrintToChat(clientMESS"TZ save 2");
            }
            else
            {
                
PrintToChat(clientMESS"TZ Ground");
            }
        }
        else
        {
            
PrintToChat(clientMESS"TZ Dead");
        }
    }
    
    return 
Plugin_Handled;
}

//Teleport2
public Action:Command_tele2(clientargs)
{    if(
enableteleport == 1)
    {
        if (
IsPlayerAlive(client))
        {
            if(!(
coords1[client][0] == 0.0 && coords1[client][1] == 0.0 && coords2[client][2] == 0.0))
            {
                
TeleportEntity(clientcoords2[client], NULL_VECTORNULL_VECTOR);
                
PrintToChat(clientMESS"TZ teleport 2");
            }
            else
            {
                
PrintToChat(clientMESS,"TZ no teleport");
            }
        }
        else
        {
            
PrintToChat(clientMESS"TZ Dead");
        }
    }
    
    return 
Plugin_Handled;
}

//On Take Damage
public Action:OnTakeDamage(client, &attacker, &inflictor, &Float:damage, &damagetype)
{
    if(
enablenofall == 1)
    {
        if (
damagetype DMG_FALL)
        {
            return 
Plugin_Stop;
        }
    }
    
    return 
Plugin_Continue;
}

//When player runs CMD (AutoJump)
public Action:OnPlayerRunCmd(client, &buttons, &impulseFloat:vel[3], Float:angles[3], &weapon)
{
    if(
Client_IsOnLadder(client) || Client_GetWaterLevel(client) > Water_Level:WATER_LEVEL_FEET_IN_WATER)
    {
        return 
Plugin_Continue;
    }

    if(
enableautojump && IsPlayerAlive(client) && autojump[client] == 1)
    {
        if (
buttons IN_JUMP)
        {
            if (!(
GetEntityFlags(client) & FL_ONGROUND))
            {
                
buttons &= ~IN_JUMP;
            }
        }
    }
    
    return 
Plugin_Continue;
}


//Give
give(client)
{
    
GivePlayerItem(client"weapon_flashbang");
}

stock GetClientFlashBangs(client)
{
    new 
String:weaponn[255];
    
    for(new 
0weapon128+= 4)
    {
        
weapon GetEntDataEnt2(clientm_hMyWeapons i);
        
        if(
weapon != -1)
        {
            
GetEdictClassname(weaponweaponnsizeof(weaponn));
            
            if(
StrEqual(weaponn"weapon_flashbang"))
            {
                new 
iPrimaryAmmoType GetEntProp(weaponProp_Send"m_iPrimaryAmmoType"4);
                new 
ammo GetEntData(clientammoOffset+(iPrimaryAmmoType*4));
                
                return 
ammo;
            }
        }
    }
    
    return 
0;
}

//Strip
strip(client)
{
    for(new 
0weapon128+= 4)
    {
        
weapon GetEntDataEnt2(clientm_hMyWeapons i);
        
        if(
weapon != -1)
        {
            
RemovePlayerItem(clientweapon);
        }
    }
    
    
GivePlayerItem(client"weapon_knife");
    
GivePlayerItem(client"weapon_usp");
    
GivePlayerItem(client"weapon_flashbang");
}

//Start Creating Invis
CreateInvis(targetalpha)    
{
    
SetAlpha(target,alpha);
}

//Player Invis
SetAlpha(targetalpha)
{        
    
SetWeaponsAlpha(target,alpha);
    
SetEntityRenderMode(targetRENDER_TRANSCOLOR);
    
SetEntityRenderColor(target255255255alpha);    
}

//Weapon Invis
SetWeaponsAlpha(targetalpha)
{
    if(
IsPlayerAlive(target))
    {
        for(new 
0weapon47+= 4)
        {
            
weapon GetEntDataEnt2(targetm_hMyWeapons i);
            
            if(
weapon > -)
            {
                
SetEntityRenderMode(weaponRENDER_TRANSCOLOR);
                
SetEntityRenderColor(weapon255255255alpha);
            }
        }
    }


Last edited by generals; 03-20-2019 at 06:40.
generals is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 08:33.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode