Raised This Month: $32 Target: $400
 8% 

Solved [CSGO] Nightvision for Terrorist


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
srvmil
Senior Member
Join Date: Oct 2010
Old 02-28-2018 , 01:38   [CSGO] Nightvision for Terrorist
Reply With Quote #1

Should this be correct?

PHP Code:
#include <sourcemod>
#include <sdkhooks>
#include <sdktools>
#include <cstrike>
#include <smlib>

#pragma newdecls required

ConVar g_bNV;
new 
Handle:Cvar_Enable;

public 
void OnPluginStart()
{
    
g_bNV CreateConVar("mod_nightvision""1""Set Nightvision for terror");
    
Cvar_Enable CreateConVar("mod_enable""1""Enable/disable XX Mod");
}

public 
Action Event_RoundStart(Event event, const char[] namebool dontBroadcast){
{
    new 
client GetClientOfUserId(GetEventInt(event"userid"))
    
    if (
GetClientTeam(client) == 2)
    {    
        if (
GetConVarInt(Cvar_Enable) == 1)
        {
            
SetEntityModel(client,"models/player/custom/player/batman.mdl");
            
SetEntityRenderMode(client,  RENDER_TRANSCOLOR);
            
SetEntityRenderColor(client255255255255);
            
SetEntityHealth(client250);
            
SetEntProp(clientProp_Send"m_bNightVisionOn"1);
            
SetEntPropFloat(clientProp_Data"m_flLaggedMovementValue"1.2);    
        }
        for(new 
04i++)
        {
            new 
weapon GetPlayerWeaponSlot(clienti);
            if(
weapon != -1)
            {
            }
        }
    }
    else if (
GetClientTeam(client) == 3)
    {
        
SetEntPropFloat(clientProp_Data"m_flLaggedMovementValue"1.0);
    
//SetEntityModel(client,"models/player/.mdl Add CT Custom Here");
        
SetEntityRenderColor(client255255255255);
        
SetEntityHealth(client100);
    }

What I want is that nightvision is turned on by default for terrorist that doesn't need to type anything.

Last edited by srvmil; 03-01-2018 at 02:37.
srvmil is offline
srvmil
Senior Member
Join Date: Oct 2010
Old 02-28-2018 , 02:58   Re: [CSGO] Nightvision for Terrorist
Reply With Quote #2

Well I tested it, and it does work.

I wish I tested it before I posted it. Oh well.
srvmil is offline
Zyten
Senior Member
Join Date: Jan 2018
Old 03-14-2018 , 20:28   Re: [CSGO] Nightvision for Terrorist
Reply With Quote #3

what nightvision exacly do?
Zyten is offline
Reply


Thread Tools
Display Modes

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 09:06.


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