Jump to content
Sign in to follow this  
theavonlady

Universal Script Folders

Recommended Posts

After seeing the recent thread about mod folder subdirectories, I decided to do a little experiment and see if OFP missions can handle scripts located outside of the mission's PBO file or folder.

Works like a charm. For example, I used my AMORE method to install a script into \Operation FlashPoint\AMORE\Avon\Scripts.

I then ran a test mission calling the script with:

<table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">[] exec "\AMORE\Avon\Scripts\mytestscript.sqs"

What is this good for? A few things:

1. Let's say you're a mission maker and you're using other people's scripts. If those scripts get updated/corrected, using this method of a universal script folder, you just need to replace the script. No changes are required to missions that execute the script.

2. Using AMORE, scripts are kept in separate AMORE folders, based on a scripterwriter's OFPEC tag name (mine is "Avon", for example). This would allow for 2 scriptmakers to produce competing scripts with the same file names, allowing the mission maker the choice to simply chose which of the scripts the prefer to use by specifying the script's folder path.

3. Keeping scripts outside of PBOs makes it much easier to find and manage them when you need them again.

Anyway, just an observation I made. smile_o.gif

Share this post


Link to post
Share on other sites

Very interesting observation, AvonLady. Thanks!

I once had an idea to do a sort of "JAM for scripts", where simple, or easy to use scripts not requiring much editing of the file itself could be put into a .pbo archive, and distributed. Imagine, for instance, helicopter dust scripts or all these great AI scripts, put into a .pbo (or a series), and then executed by the user in an init line, quickly and easily. I think this method would work pretty well for simple scripts that do not require much in the way of manually editing the file. Updates would be quick and painless, as the .pbo files would be relatively small.

But, not many people make missions anymore, let alone scripts, so I don't know if it would pan out. sad_o.gif

Sorry, I digress. Thank you very much for enlightening me to this. smile_o.gif

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  

×