Jump to content
damsous

Random sqf selection

Recommended Posts

Hello i would like to init few sqf randomly on a mission with a radio trigger, for exemple mission1.sqf or mission2.sqf or  mission3.sqf....  but i dont know how to do it.

 

There is a simple way do do that ? thanks

Share this post


Link to post
Share on other sites

As @beno_83au said. Example:

_randomMission = selectRandom ["rescue_mission", "kill_mission", "defend_mission"];
_mission = [] execVM format ["scripts\missions\%1.sqf", _randomMission];

 

  • Like 2
  • Thanks 2

Share this post


Link to post
Share on other sites
46 minutes ago, HazJ said:

As @beno_83au said. Example:


_randomMission = selectRandom ["rescue_mission", "kill_mission", "defend_mission"];
_mission = [] execVM format ["scripts\missions\%1.sqf", _randomMission];

 

ok i will try that thanks for your help

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

×