Jump to content
Sign in to follow this  
Tand3rsson

Placing markers randomly on click map (AIRSTRIKE question)

Recommended Posts

Hi!

I really aint got much, so this is more like one of those "do my work for me" questions. Which I appologize for.

My idea is this, you call an airstrike, just like you do the on map click request for example mortars (radio, click on map for target pos). When clicking on the map, eight markers are either spawned or moved to a random position within 75 meters of the mapclick (That is a random pos for each marker). Then a flying aircraft is spawned at high altitude, flying over the target area and the munitions are deployed like:

 


_bomb = "Bo_MK82" createVehicle getmarkerPos "bomb1";

sleep 0.1;

_bomb = "Bo_MK82" createVehicle getmarkerPos "bomb2";
_bomb = "Bo_MK82" createVehicle getmarkerPos "bomb3";

sleep 0.5;

_bomb = "Bo_MK82" createVehicle getmarkerPos "bomb4";

sleep 0.3;

_bomb = "Bo_MK82" createVehicle getmarkerPos "bomb5";

sleep 0.7;

_bomb = "Bo_MK82" createVehicle getmarkerPos "bomb6";

sleep 0.2;

_bomb = "Bo_MK82" createVehicle getmarkerPos "bomb7";

sleep 0.2;

_bomb = "Bo_MK82" createVehicle getmarkerPos "bomb8"; 

the airplane continues it flight, and is later deleted.

The part I need help with is really the whole part up untill, and included the position of the markers. The rest, with spawning the aircraft, dropping the bombs, and deleting the aircraft, I can sort out my self.

If you dont understand what I'm after, hopefully this will clear things up:

 http://www.youtube.com/watch?v=3OpMGAuslFY 

Thanks!

Share this post


Link to post
Share on other sites

Hmm.. I should have thought this through a bit more. Anyway, if anyone else is interested, this is how I solved the random bombs within a 75 m area from a marker

 _pos = _this select 0;

_bombUno = createVehicle ["Bo_MK82", getMarkerPos _pos, [], 75, "NONE"]; 

and then like the first script I posted. It is called using:

nul = ["marker"] execVm "bombTwo.sqf";

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  

×