Jump to content
Sign in to follow this  
Jigsor

Gather all editor placed markers into an array

Recommended Posts

I'm using EOS and have a ton of markers on the map. I would like to somehow detect all markers so I can put them into an array rather than manually type them or copy/paste them into an array. Is there a way to automate this?

Share this post


Link to post
Share on other sites

That works. Was unaware of allMapmarkers. Thanks Grumpy Old Man.

Share this post


Link to post
Share on other sites

Or you could retreive all the eos Markers from

server GetVariable "eosMarkers";

Share this post


Link to post
Share on other sites

"allmapmarkers" also takes those into account that are placed by players during the gameplay by doubleclick.

This code returns only those (_allmarkers) that were actually placed in the editor or spawned by "createmarker(local)":

_mapclick = [];
_allmarkers = [];
{private "_a"; _a = toArray _x; _a resize 15; if (toString _a == "_USER_DEFINED #") then {_mapclick = _mapclick + [_x]}} forEach allMapMarkers;
if (!(_x in _mapclick)) then {_allmarkers = _allmarkers + [_x]}} forEach allMapMarkers;

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×