|
Author
|
Message
|
|
Junior Member
|

05-31-2010
, 00:25
Re: Trigger Light
|
#1
|
Quote:
Originally Posted by wrecked_
Are you looking to just disable the lights? Or do you want them to just be turned off by default at round start?
This plugin removes all lights (make sure the classname is right, wasn't too sure): Code:
#include <amxmodx></p><p>#include <fakemeta></p><p> </p><p>// not sure, correct me if i'm wrong</p><p>new const LightClassname[] = "func_light"</p><p> </p><p>public plugin_precache()</p><p>{</p><p> register_forwar d( FM_Spawn, "SpawnForward" )</p><p>}</p><p> </p><p>public SpawnForward( Ent )</p><p>{</p><p> if( pev_valid( Ent ) )</p><p> {</p><p> &nbs p; new cname[32]</p><p> &nbs p; pev( Ent, pev_classname, cname, 31 )</p><p> </p><p> &nbs p; if( equal( cname, LightClassname ) )</p><p> &nbs p; {</p><p> &nbs p; engfunc( EngFunc_RemoveEntity, Ent )</p><p> &nbs p; }</p><p> }</p><p>}</p><p> </p><p>public plugin_init()</p><p>{</p><p> register_plugin( "Light Remover", "1.0", "Wrecked" )</p><p>}
BTW, HLTV isn't called on the map start, so you'll have to wait until a new round restart for that to be called. This might be your issue, and you just weren't waiting for another round and assumed it wasn't working right away.
|
Sorry, it did not work. I try to restart round still it is not working.
|
|
|
|