Zippy32 10 Posted August 11, 2009 Hopefully a nice easy question, I've done a quick search but couldn't see an answer. I want to make two markers appear on the map when a certain point is reached. How do I link the trigger to the markers? I've tried synchro, but it doesn't let me connect the trigger to the marker? Thanks Share this post Link to post Share on other sites
Tinker 10 Posted August 11, 2009 (edited) Put a marker on the map then change its coordinates to be off the map in the mission file. So it is there, but you cannot see it. Trigger / On Act: "MyMarker" setMarkerPos [12899.89,4457.31]; Put in coordinates where you want it to be. Put something where you want it, look in the mission file using notepad to find correct coords... So instead of creating a marker, you are just teleporting it to your position. Works for anything else too I think. There are 3 sets of numbers in the coords. Use the first and last set, forget the second. Edited August 11, 2009 by Tinker Share this post Link to post Share on other sites
nominesine 0 Posted August 11, 2009 Or place an empty marker and give it the correct shape/color/etc with the commands: setMarkerType setmarkerColor setMarkerText You can read more about the commands in Ofpec's comreh here: http://www.ofpec.com/COMREF/ Share this post Link to post Share on other sites
dummy_01 10 Posted August 11, 2009 Does this work on units also? Would it be possible to place a soldier on some remote part of the island and then teleport him to the location you want him to be, at the time you him to appear? Just like a spawn script? Share this post Link to post Share on other sites
shuko 59 Posted August 11, 2009 Does this work on units also?Would it be possible to place a soldier on some remote part of the island and then teleport him to the location you want him to be, at the time you him to appear? Just like a spawn script? I often use this method, just place them in a corner of a map (on land obviously) and then setpos them when/where needed. Seems to lag less than creating them on the spot as they were already made at the start of the mission. Share this post Link to post Share on other sites
dummy_01 10 Posted August 11, 2009 Then do you use setUnitPos instead of setMarkerPos? A script-snippet would be much appreciated... :) Share this post Link to post Share on other sites
Murklor 10 Posted August 11, 2009 For a unit you just use setPos (works the same as setMarkerPos for markers). Share this post Link to post Share on other sites
nuxil 2 Posted August 11, 2009 Take a look at this.. this is a script that sets a marker on the player and follows him... not exactly what you want. but it might help you understand how markers work better _player = this; // the name of the marker is the same as the player name _name = format["%1",name player]; _plMarker = createMarker [_name, position player]; _plMarker setMarkerColor "ColorBlue"; _plMarker setMarkerType "Air"; _plMarker setMarkerText format["%1",name player]; _plMarker setMarkerSize [1, 1]; _plMarker setMarkerDir getdir player; // Now update the Marker on the map while {alive player} do { _playerpos = getpos player; format["%1",name player] setmarkerpos [_playerpos select 0,_playerpos select 1]; //adjust this for updatespeed sleep 0.1; }; Share this post Link to post Share on other sites