Raised This Month: $ Target: $400
 0% 

Getting light entities in a map


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
MousePad
Junior Member
Join Date: Apr 2012
Old 04-24-2013 , 17:01   Getting light entities in a map
Reply With Quote #1

I'm trying to find all the light entities in the map. I decompiled the maps I tested and I can see int the entity report of Hammer that they have several light entities with the classname "light". This is how I'm trying to detect light entities:
PHP Code:
new g_max_clients global_get(glb_maxClients)
new 
entitiesnum global_get(glb_maxEntities)
new 
classname[33]

for(new 
g_max_clients 1entitiesnum i++)
{
    if (!
pev_valid(i))
    {
    }
    else
    {
        
pev(ipev_classnameclassname32)
        
log_amx("Entity %d: %s"iclassname)
    }

However I can't see any entities with the classname "light". I also tried several entity related plugins here none of them could find the light entities. Is it possible that you can only detect lights which have actual switches in the map for them? If so, is there any other way I can detect the ones that don't? Any comment would be appreciated.
MousePad 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 10:48.


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