Execute multiple scripts at once

Posts 113 of 13 · Page 1 of 1
Execute multiple scripts at once
In the root of your Operation Arrowhead directory, create a folder called 'MyScripts'. Then you need to put all of the scripts you would like to use inside this new folder.

Then, create a new file in 'C:\' called 'execall.sqf'
Now edit the file, and type this:

Code:

Code:
player execVM "MyScripts\Script1.sqf";
player execVM "MyScripts\Script2.sqf";
player execVM "MyScripts\Script3.sqf";
player execVM "MyScripts\Script4.sqf";
You can place as many scripts as you want.

Replace 'Script#.sqf' with the exact name of your script. Also, it is important to note that the order that the scripts are executed in is determined by the order written in the file. For example, if you have a script that spawns a truck, and then another script that gives that truck infinite fuel, you would want to place

Code:

Code:
player execVM "MyScripts\SpawnTruck.sqf";
before

Code:
Code:
player execVM "MyScripts\InfiniteFuel.sqf";
Finally, just execute this script like you would any other.

Credits to HarrisonTZ and Tat.
Basic setup for noobs_mpgh.net.rar4 KB · 286 downloads Scanning…
Thanks for this. I really hope some people in this forum now ask "How i excut skript?".

Notes:
  • You can put scripts anywhere, whether it is MyScripts, wuat, Scripts, etc. (Just change the "MyScripts\xxx.txt")
  • The files set to be executed can be in any format, whether it is .sqf, .sqs, .txt, etc.
  • If you have a script in the root directory, you don't need to put the script in a folder. Just use
    Code:
    player execVM "XXXXXXX.sqf";
  • You can name execall whatever, mine is personally called "execute.txt"
I have changed it to .sqf because most of the people got used it to now.
Quote Originally Posted by stickd34th View Post
I have changed it to .sqf because most of the people got used it to now.
Thank you! Didn't want to have a shit storm over WAIT SO CAN THIS BE USED WITH SCRiPTS?
Quote Originally Posted by lockdown6435 View Post
Thank you! Didn't want to have a shit storm over WAIT SO CAN THIS BE USED WITH SCRiPTS?
Can you use scripts with this?
Quote Originally Posted by jessedayz View Post
Can you use scripts with this?
Seriously?
Quote Originally Posted by stickd34th View Post
Seriously?
I think there was a hint at sarcasm...lol
Approved
I dont even know anymore if its sarcasm or not.
Quote Originally Posted by stickd34th View Post
I dont even know anymore if its sarcasm or not.
It was :3 lololol
An important update to this thread. As of BE server update 1.69:

It is currently not safe to keep script files inside your ARMA directory, as BE now scans that folder for script files and (as of 08.27.2012) has been insta-banning anyone with even a blank script file in the ARMA directory

They may update this behavior soon as it is causing even legit Mission developers to be banned for making advanced script files for their custom missions. But for now, use at your own risk.
Quote Originally Posted by mixerz View Post
An important update to this thread. As of BE server update 1.69:

It is currently not safe to keep script files inside your ARMA directory, as BE now scans that folder for script files and (as of 08.27.2012) has been insta-banning anyone with even a blank script file in the ARMA directory

They may update this behavior soon as it is causing even legit Mission developers to be banned for making advanced script files for their custom missions. But for now, use at your own risk.
Source of this info please?
Quote Originally Posted by lockdown6435 View Post
Source of this info please?
I haven't been around lately to retest this, but part of the patch notes for the 1.69 update referenced scanning the ARMA II directory for illegal files.

The day the patch went live and a bunch of people were banned, I did my own testing with spare keys. I removed all script files from my ARMA II directory and was able to play hack-free with no troubles. I then added a blank script file to my ARMA directory in a folder called "scripts". I named the script something obscure and meaningless like "jehdkee.sqf". My next attempt to log in was greeted with a Global Ban.

I removed the script file again, loaded a new key and again had no problems for 24-hours playing legit.

There was of course the global message from BE along the lines of, "There is a rumor that innocent people were banned with the latest BE update. This is untrue." But I believe that was just a cover for their initial flaw in properly filtering their scan of script files in the ARMA directory.

It is possible that they have since sorted this out. Especially considering there are many people that create legitimate scripts for use with custom Mission files.

But as I said, I haven't really been around to do much testing in the last week. I would love to hear other people's current results with this.
Posts 113 of 13 · Page 1 of 1

Post a Reply

Similar Threads

Tags for this Thread

None

Need help?