Jump to content
Sign in to follow this  
SoLoSniper

-[TdC]- Convoy Script

Recommended Posts

TdC_ArmA_1.gif

-[TdC]- Convoy Script

by

-[TdC]-Socrate.it

Description:

Creation of totally personalizzed convoys (with some randmoness, if you want) that reacts under fire.

You can create friendly convoy if you want too.

Protected SCUD convoy, black jeeps convoy, protected supply convoy, infantry convoy, bus convoy, whatever...

Features:

-control the structure of the convoy (number limit is the number of group arma can handle, hypotetically, suggested is 6/9/12)

-creation of vehicle divided by subsides, also giving them some randomness

-creation of vehicle divided by subtype category (transport full/empty/random, supply repair/refuel/reammo/random, ecc...)

-creation of special vehicles by special names (zsu, scud, black jeeps, ecc...)

-creation of custom vehicles by class (tanks or apc, ecc..)

-creation of covering attack heli (or filled transport=paradrops) (on/off) with his own reaction under fire (search and destroy)

-set multiple road/path, in sequence or random or both, by easy to configure by copy/paste markers

-set convoy cycle waypoint

-convoy stay strongly together thanks to forcespeed (couln't be called convoy if not)

-convoy react to fire (dead/canmove/knowsabout)

-different infantry reactions underfire hardcoded (smoke, disembark then task defense/attack)

-random fleeing reaction of the convoy underfire

-fleeing convoy under given death ratio

-convoy overall skill

-convoy creation direction by first marker

-convoy tracking (on/off) (do not support multiple convoy, working on this)

-convoy infantry cover color smoke

-vehicle are automatically filled with soldiers

-deletedead bodies

Installation:

Editing MPmissions Folder

Included files:

Mission test on zargabad for MPeditor

Mission example for MPeditor

Usage:

Do not edit without contacting the owners

Change log:

1.0 Public Release Version

Notes:

Easy need to work:

Configure your convoy structure editing scr_convoy_cfg.sqf

Functions Module in editor

Initalization of script ([] execVM "scr_convoy_cfg.sqf") by trigger, by init or wantelse

Pathway markers

Params locations for description.ext and others for editing if necessary:

DeleteDead is in scr_cnv/scr_deletedead.sqf line 6

Cycle Waypoint is in scr_cnv/scr_convoy_init.sqf line 47

others are in main scr_convoy_cfg.sqf

Special Names for Special Class are in scr_cnv/scr_convoy.sqf line 89

Credits & Thanks:

-[TdC]-Socrate.it (Scripter)

-[TdC]-SoLo.it (Manager)

-[TdC]- Clan (beta testing)

Contacts:

admin@tdcclan.it

www.tdcclan.it

File:

http://www.armaholic.com/page.php?id=14429

Edited by SoLoSniper

Share this post


Link to post
Share on other sites

tried using this with ace and it didnt work. i really only make missions for ace so.....

Share this post


Link to post
Share on other sites
tried using this with ace and it didnt work. i really only make missions for ace so.....

What didn't work? I played around today with it (and ACE) and it worked for me. I was going to add it into one of my missions so any heads up on potential problems would be good to hear.

Share this post


Link to post
Share on other sites
tried using this with ace and it didnt work. i really only make missions for ace so.....

And ... the description of why and how and steps taken ... is .......

Share this post


Link to post
Share on other sites

Me and Solo are planning to clean up the code and improve the documentation for the next release..there's still a lot of work to do. I'd like to document better the functions we wrote.

For those interested in scripting take a look at how the path for the convoy are generated. Basically you can generate a mix between random and sequential paths. Furthermore this is done in a seperate function so you can use it also for other projects.

This function is the file scr_fnc_rndPathPos.sqf and use internally the function in the scr_fnc_rndPath.sqf file.

Some examples:

path = ["seq", a]; 

this simply take all the marker you placed a,a_1,a_2 etc and generate an array of positions

path = ["seq",a,b,c];

generate an array of positions made by all the a,b,c markers in that order

path = ["seq",a, ["rnd",b,c],d]

generate and array of positions composed by:

  1. all the marker of a
  2. all the markers of b OR c
  3. all the marks of d

so the possible paths are abd or acd etc...

i know it's not so simple but you can create very complex expressions like

["rnd",["seq",a,b],["seq",c,["rnd",d,e]]]

where the possible paths are: ab,cd,ce!! Notice the random starting point!!!

probably this function will be released standalone

Edit:

I forgot to underline that when writing "a" in ALL the markers named a,a_1,a_2... contribute to the path!!

Edited by Socrate

Share this post


Link to post
Share on other sites

Just tested excellent work.

Possible to make these scripts for Single player ?

Share this post


Link to post
Share on other sites
This is awesome... :inlove:

Nice work!

Just tested excellent work.

Possible to make these scripts for Single player ?

First thank you all! :bounce3:

panda123 right now i think that in the next release we'll fix some bugs, clean up the code and improve the documentation. I cannot guarantee but maybe in future releases we can try to make it work in single player!

Share this post


Link to post
Share on other sites

ok I gonna wait a little to see if can implement in my campaign.

Grazie mille. Buon lavoro :)

Share this post


Link to post
Share on other sites
ok I gonna wait a little to see if can implement in my campaign.

Grazie mille. Buon lavoro :)

If we haven't done an awfull work, it should work in SP too...

You just need to "remove" and change the ParamsArray linked to the description, then the script should work in SP aswell.

In the details I wrote where are located the ParamsArray so you can easly find them and change. You just need to choose YOUR value. The possible value are wrote in description if you are lost.

Example: deletedead body will be fixed at 600 seconds.

Share this post


Link to post
Share on other sites

Good job and great work with this release,many mission maker would love your work!

Share this post


Link to post
Share on other sites
If we haven't done an awfull work, it should work in SP too...

You just need to "remove" and change the ParamsArray linked to the description, then the script should work in SP aswell.

I've just added in the init.sqf this

if (isNil "param1" && isNumber(missionConfigFile/"defValueParam1")) then

{

param1 = getNumber (missionConfigFile/"defValueParam1");

};

if (isNil "param2" && isNumber(missionConfigFile/"defValueParam2")) then

{

param2 = getNumber (missionConfigFile/"defValueParam2");

};

if (isNil "paramsArray") then

{

paramsArray=[];

if (isClass (missionConfigFile/"Params")) then

{

_c=count (missionConfigFile/"Params");

for [ {_i=0}, {_i<_c}, {_i=_i+1} ] do

{

_paramName = (configName ((missionConfigFile >> "Params") select _i));

paramsArray=paramsArray+[ getNumber (missionConfigFile >> "Params" >> _paramName >> "default") ];

};

};

_c=count paramsArray;

if (isNil "param1" && _c>0)then{param1=paramsArray select 0};

if (isNil "param2" && _c>1)then{param2=paramsArray select 1};

};

to make working the scripts in SP, and it seems to work. May be is there a better way ?

(Quick question : What are param1 and param2 ? Che cosa è param1 e param2 ?)

Edited by panda123

Share this post


Link to post
Share on other sites
Good job and great work with this release,many mission maker would love your work!

Thx Sam!

I've just added in the init.sqf this to make working the scripts in SP, and it seems to work. May be is there a better way ?

(Quick question : What are param1 and param2 ? Che cosa è param1 e param2 ?)

Notes:

Params locations for description.ext and others for editing if necessary:

DeleteDead is in scr_cnv/scr_deletedead.sqf line 6

Cycle Waypoint is in scr_cnv/scr_convoy_init.sqf line 47

others are in main scr_convoy_cfg.sqf

Special Names for Special Class are in scr_cnv/scr_convoy.sqf line 89

If you understand what is wrote here and know what to do well, otherwise this isn't the right place to discuss this.

Anyway you found a script that gives default params value to the params of the mission at start, so that is perfect to make it work on SP.

The better way is to edit the various sqf, removing the params line and setting your value, but you need to know basic editing knowledge, otherwise you risk to break the code.

You found the easiest way to solve the problem without editing knowledge.

Params1 and Params2 are parametric values (set in description.ext and script) that admins can change at mission start on MP missions, but doesn't work in SP.

In the next release I will set a SP version and provide it in the package, so people will not need to edit anything.

Share this post


Link to post
Share on other sites

First of all, thank you guys for your work. I am definitely not as good at scripting as you are but I hope you are interested in my opinion about the script:

1, For some reason I couldn't make the SC-TdCconvoy.Zargabad test mission work in the editor but it did work when I put the mission in the MPmissions folder.

2, While editing scr_convoy_cfg.sqf I realized that always twice as many convoy guard and convoy transport vehicles were created as defined. I couldn't create any support vehicles or helicopters. I have no idea about the reason.

3, The "reaction under fire" is I think very good but I think more smoke shells would be better.

I tried the script with CO 1.59 with and without ACE. Now I am about to incorporate it into one of my missions. I'm looking forward to the next release.

:bounce3:

Share this post


Link to post
Share on other sites

I can get this to work when i test but as soon as i put it on a dedi server i get "scr_fnc_convoy.sqf: Not server or not enough param" ?

Any idea why it will not work on a dedi ?

Share this post


Link to post
Share on other sites

I ´ve the same problem that psvialli. The script works very nice, but on dedicated server shows me this mesagge, (althought runs OK): "Scr_fnc_convoy.sqf: not server or not enought param". In the script demo missions the same mesagge. Any idea to erase that unwelcome dispatch?

th_ForoBI.jpg

Thanks a lot for this wonderfull script!!!

Edited by Josueps

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  

×