Page 1 of 1
Restrict la awp pe o anumita harta. [rezolvat]
Posted: 13 Feb 2019, 02:10
by kEnT89
Plugin Cerut: Vreau ca pe harta de_dust2x2 sa fie interzis awp-ul.
Descriere (adica ce face el mai exact): .Stiu ca este comanda amx_restmenu,dat trebuie bagata de fiecare data
Serverul ruleaza (HLDS/ReHLDS): Hlds
Versiune AMX Mod X:
Modul Serverului: Clasic
Re: Restrict la awp pe o anumita harta.
Posted: 13 Feb 2019, 19:03
by DanN
- | Afiseaza codul
#include <amxmodx>
#include <fun>
new const
PLUGIN[] = "",
VERSION[] = "1.0",
AUTHOR[] = "scosmyn";
new bool:IsWeapons = false
new const szMaps[][] =
{
"awp",
"deagle"
}
public plugin_init() {
register_plugin(PLUGIN,VERSION,AUTHOR)
register_event("CurWeapon","CurrentWeapon","be","1=1")
set_task(1.0,"task_exec")
}
public task_exec() {
new mapname[32]
get_mapname(mapname,charsmax(mapname))
for(new i = 0;i < sizeof szMaps; i++)
{
if(containi(mapname,szMaps) != -1)
{
IsWeapons = true
break
}
else
{
IsWeapons = false
}
}
}
public CurrentWeapon(id) {
if(IsWeapons)
return
else
{
if(!(get_user_flags(id) & ADMIN_LEVEL_H))
{
if(get_user_weapon(id) == CSW_AWP || get_user_weapon(id) == CSW_DEAGLE)
{
client_cmd(id,"drop")
}
}
else
{
return
}
}
}
Re: Restrict la awp pe o anumita harta.
Posted: 22 Feb 2019, 21:23
by kEnT89
Multumesc !
Se poate da T.C
Re: Restrict la awp pe o anumita harta.
Posted: 23 Feb 2019, 09:31
by Laurentiu P.
kEnT89 wrote:Multumesc !
Se poate da T.C
Marcat ca rezolvat.