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

Seach Noscope Plugins for SSG [CSGO]


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Vicoshow
Junior Member
Join Date: Nov 2017
Location: France
Old 11-21-2017 , 19:43   Seach Noscope Plugins for SSG [CSGO]
Reply With Quote #1

Hello i'm searching a plugin noscop for my server Cs:go, i have a old plugin we works fine on css but it doesnt works on Cs:go,
can we found a plugin which does exactly the same thing : scop = HUD messageand refill of the SSG, thanks you if u help me sorry for my english. (this topics was affiliate whith the one frome below)




Noscope.sp
#pragma semicolon 1
#include <sourcemod>
#include <sdktools>
#define VERSION "1.0.1"

public Plugin:myinfo =
{
name = "Scout No Scope",
author = "XARiUS",
description = "Plugin which will force scout no scoping!",
version = "1.0.1",
url = "http://www.the-otc.com/"
};

new String:language[4];
new String:languagecode[4];
new bool:g_enabled;
new bool:g_bulletpath;
new g_laser;
new Handle:g_Cvarenabled = INVALID_HANDLE;
new Handle:g_Cvarbulletpath = INVALID_HANDLE;

public OnPluginStart()
{
LoadTranslations("noscope.phrases");
CreateConVar("sm_noscope_version", VERSION, "Scout No Scope Version", FCVAR_PLUGIN|FCVAR_SPONLY|FCVAR_REPLICATED|FC VAR_NOTIFY|FCVAR_DONTRECORD);
g_Cvarenabled = CreateConVar("sm_noscope_enabled", "1", "Enable this plugin. 0 = Disabled");
g_Cvarbulletpath = CreateConVar("sm_noscope_bulletpath", "0", "Show the bullet path using a small laser beam. 0 = Disabled");
GetLanguageInfo(GetServerLanguage(), languagecode, sizeof(languagecode), language, sizeof(language));

HookEvent("weapon_zoom", EventWeaponZoom, EventHookMode_Post);
HookEvent("weapon_fire", EventWeaponFire, EventHookMode_Post);

HookConVarChange(g_Cvarenabled, OnSettingChanged);
HookConVarChange(g_Cvarbulletpath, OnSettingChanged);

g_enabled = GetConVarBool(g_Cvarenabled);
g_bulletpath = GetConVarBool(g_Cvarbulletpath);

g_laser = PrecacheModel("materials/sprites/laser.vmt");
}

public OnSettingChanged(Handle:convar, const StringldValue[], const String:newValue[])
{
if (convar == g_Cvarenabled)
{
if (newValue[0] == '1')
{
PrintHintTextToAll("%t", "Noscope enabled");
EmitSoundToAll("weapons/zoom.wav");
g_enabled = true;
}
else
{
PrintHintTextToAll("%t", "Noscope disabled");
EmitSoundToAll("weapons/zoom.wav");
g_enabled = false;
}
}
if (convar == g_Cvarbulletpath)
{
if (newValue[0] == '1')
{
g_bulletpath = true;
}
else
{
g_bulletpath = false;
}
}
}

public Action:EventWeaponFire(Handle:event,const String:name[],bool:dontBroadcast)
{
if (g_enabled && g_bulletpath)
{

new clientid = GetClientOfUserId(GetEventInt(event, "userid"));
new String:weaponname[32];
GetEventString(event, "weapon", weaponname, sizeof(weaponname));
if (StrEqual(weaponname, "scout", false))
{
DrawLaser(clientid);
}
}
}

public Action:EventWeaponZoom(Handle:event,const String:name[],bool:dontBroadcast)
{
if (g_enabled)
{
new client = GetClientOfUserId(GetEventInt(event, "userid"));
new String:weaponname[32];
GetClientWeapon(client, weaponname, sizeof(weaponname));
if (StrEqual(weaponname, "weapon_scout", false))
{
new weapon = GetPlayerWeaponSlot(client, 0);
if (IsValidEdict(weapon))
{
RemovePlayerItem(client, weapon);
RemoveEdict(weapon);
CreateTimer(0.1, GiveScout, client);
PrintHintText(client, "%t", "Not Allowed");
}
return Plugin_Continue;
}
return Plugin_Continue;
}
return Plugin_Continue;
}

public Action:GiveScout(Handle:Timer, any:client)
{
GivePlayerItem(client, "weapon_scout");
}

public DrawLaser(client)
{
new Float:clientOrigin[3], Float:impactOrigin[3];
new Float:vAngles[3], Float:vOrigin[3];
GetClientEyePosition(client,vOrigin);
GetClientEyeAngles(client,vAngles);
new color[4];

new Handle:trace = TR_TraceRayFilterEx(vOrigin, vAngles, MASK_SHOT, RayType_Infinite, TraceEntityFilterPlayer, client);

if (TR_DidHit(trace))
{
TR_GetEndPosition(impactOrigin, trace);
GetClientEyePosition(client, clientOrigin);
clientOrigin[2] -= 1;
if (GetClientTeam(client) == 3)
{
color = {75, 75, 255, 255};
}
else
{
color = {255, 75, 75, 255};
}
TE_SetupBeamPoints(clientOrigin, impactOrigin, g_laser, 0, 0, 0, 0.5, 1.0, 1.0, 10, 0.0, color, 0);
TE_SendToAll();
}
CloseHandle(trace);
}

public bool:TraceEntityFilterPlayer(entity, mask, any:data)
{
return data != entity;
}


Noscope.txt
"Phrases"
{
"Not Allowed"
{
"en" "Scoping is not allowed!"
"de" "Verwenden des Zielfernrohrs ist nicht erlaubt!"
}
"Noscope enabled"
{
"en" "Scout No Scoping is ENABLED!"
}

"Noscope disabled"
{
"en" "Scout No Scoping is DISABLED!"
}
}

Thanks More for your Help
__________________

Last edited by Vicoshow; 11-21-2017 at 19:46. Reason: Bad Englich
Vicoshow is offline
 



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 17:59.


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