Just asking to be sure I understand you right...
Do you have to know the object id for every streetlamp in general or for every single streetlamptype? (in an array maybe)
)
Now I hope you understand me :-\
Anyway, I was thinking, why not workingh in the other way?
Object id's are numbers and numers can be updated so...
I tried something on Malden, I could return the id's from one type of streetlamp, but it takes some time (more than a minute to check 50000 objects)...
; you have to know how many object there are on the island, so took 50000 just to test, there are much more on island offcourse
_maxid = 50000
_ids = []
_i = 0
#loop
if (typeof object _i == "StreetLampMetal") then {_ids = _ids + [_i] } else {goto "checknext"}
#checknext
?_i > _maxid : hint format ["%1",_ids];exit
_i = _i + 1
goto "loop"
Run it with
[] exec "whatever.sqs"
and wait a minute...
Return was [1251,2003,28419,28420,32938,37326,28424,28664]
Al these objects id's are "StreetLampMetal" lamps stored in the _ids array.
Offcourse I only check one object here and I'm 50000 of them, but I think you got the point.
The delay in the loop is nada, so it will take a loooong time when you check every object on the island
Hope it helps m8!