Jump to content
Sign in to follow this  
BullyBoii

Marker Script Help

Recommended Posts

Here is my code to delete a marker and then replace it with a new one, however, it does not delete the first marker or create a new marker, can some one please help me. Thanks, the code is below.

//removes previous markers
deleteMarker "agia_red_area";
deleteMarker "opfor_controlled_agia";

//creates a blue marker and blufor controlled marker

agia_blue_area = createMarker ["agia_blue_area", position (getmarkerpos "agia_area")];
"agia_blue_area" setmarkerShape "ELLIPSE";
"agia_blue_area" setMarkerSize [300, 300];
"agia_blue_area" setmarkerColor "ColorBlue";

agia_blufor_controlled = createMarker ["agia_blufor_controlled", position (getmarkerpos "agia_text")];
"agia_blufor_controlled" setmarkershape "ICON";
"agia_blufor_controlled" setmarkertype "Warning";
"agia_blufor_controlled" setmarkersize [0, 0];
"agia_blufor_controlled" setmarkertext "BLUFOR controlled";
"agia_blufor_controlled" setmarkercolor "ColorBlue";

Share this post


Link to post
Share on other sites

Little, istintive reply:

Have you tried to save the marker position in a temporary variable and use it in createmarker function?

Share this post


Link to post
Share on other sites

agia_blue_area = createMarker ["agia_blue_area", position (getmarkerpos "agia_area")];

"agia_blue_area" setmarkerShape "ELLIPSE";

"agia_blue_area" setMarkerSize [300, 300];

"agia_blue_area" setmarkerColor "ColorBlue";

would it not be this?

agia_blue_area = createMarker ["agia_blue_area", position (getmarkerpos "agia_area")];

agia_blue_area setmarkerShape "ELLIPSE";

agia_blue_area setMarkerSize [300, 300];

agia_blue_area setmarkerColor "ColorBlue";

and same for other markers

Share this post


Link to post
Share on other sites

Are you sure you have placed the "agia_area" in editor or that is correctly initialized?

Have you tried to use the variable with groundscore like "_var" for in-script marker?

Be sure to start game with the -showscripterrors parameter for see if and where scripts block and/or fall, it's a quite helpfully.

I hope to help you, in waiting of a better ArmA-scripter :)

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  

×