Jump to content
Sign in to follow this  
madbull

[R3F] Artillery and Logistic: Manual artillery and advanced logistic (mission script)

Recommended Posts

i have some bugs. im using scripts with domi 1.33 ACE on dedicated server.

when i unistall artillery computer, tent and other stuff staying. only computer depolying and cant load any vehicle or container.

after the transport container with a chopper by roping view content dissapering. there is only load in action until load in c130 or osprey.

im using init like that:

[] spawn
{
waitUntil {!(isNull player)};
if (player in [delta_1,delta_2,delta_3,delta_4,delta_5]) then
{
	execVM "R3F_ARTY_AND_LOG\init.sqf";
};
};

Edited by murtoo

Share this post


Link to post
Share on other sites

@murtoo :

Ok, I didn't think about a detail : the server needs to execute the init script too.

So you should replace your previous code by :

// Always init the server (even if it is not in the allowed slots)
if (isServer) then
{
execVM "R3F_ARTY_AND_LOG\init.sqf";
}
else
{
// Init the features only for allowed people
[] spawn
{
	waitUntil {!(isNull player)};
	if (player in [delta_1,delta_2,delta_3,delta_4,delta_5]) then
	{
		execVM "R3F_ARTY_AND_LOG\init.sqf";
	};
};
};

If a player hosts the game (non-dedicated), he will get all the features even if he is not in a allowed slot.

You could resolve this thing by editing the init.sqf files of the R3F arty & log.

Edited by madbull

Share this post


Link to post
Share on other sites

Has anyone managed to shoe-horn this into Xeno's Domination yet? I followed the install instructions to add it, and wasn't too suprised it didn't work :(

The demo mission looks awesome, and I will definately use it with any maps I make from scratch - but most of my time is spent tweaking Xeno's mission for my online community....

~Z~

Share this post


Link to post
Share on other sites

@zach72 :

Some guys (including me) already proved that the integration works fine.

Your problem to integrate it in a Dom' is probably about the stringtable.csv

Dom' stringtable has 3 languages : English, German, French

R3F arty & log has 2 languages : English, French

You need to insert a dummy column (or a german translation) for all strings in the three different stringtable files (listed in the manual).

To go faster, use the "replace" feature of your text editor :

Search string : quote + comma + tabulation + quote

Replace string : quote + comma + tabulation + quote + dummytrans + quote + comma + tabulation + quote

Example :

Before :

STR_R3F_LOG_action_heliport_larguer,	"Drop the object",	"Larguer l'objet"

After :

STR_R3F_LOG_action_heliport_larguer,	"Drop the object"[b][color="Red"],	"***GERMAN TRANS***"	[/color][/b],"Larguer l'objet"

Share this post


Link to post
Share on other sites

that find replace looks a bit beyond my abilities off the cuff, but looking at domination, it's only 2 languages - English,German. So can I just change 'French' to 'German' in the R3F stringtable, so the columns match?

I'll try that and see if it's still broken.

~Z~

Edit - looks like i'd put some bad characters in the csv file I edited. After re-doing everything, it all just works! 2 language, one English/French the other English/German, but the code doesn't care.

thx for the help!

Edited by zach72

Share this post


Link to post
Share on other sites

Loving the logistics and artillary now in Domination. Another question, if I may though:

I know how to disable the logistics feature in objects (object_variable setVariable ["R3F_LOG_disabled", true];) - but can't work out where to put this to disable the main base flag and ammo box in Domination - as they are spawned somewhere deep in Xeno's code!

I realise this is strictly a domination question, but as you said several people have already merged this script with that mission, I thought someone may have a quick answer for me? Getting eye sore scanning Zeno's code trying to work out what they are called.

Thanks

~Z~

Share this post


Link to post
Share on other sites

Hi zach72,

Yes, there are several objects on the Domi's military base which are spawned by script.

The ammo crate is spawned by a script but not the main flag (it is in the mission editor).

Anyway, the easier way to disable the features on objects of desired types (which have been created via a script or the mission editor) is to use this kind of code :

if (isServer) then
{
   [] spawn
   {
       // Wait a bit to be sure that the Domi has finished to do its stuff
       sleep 5;

       {
           _x setVariable ["R3F_LOG_disabled", true, true];
       } forEach (nearestObjects [getPos FLAG_BASE, ["CLASS_NAME_TO_DISABLE1", "CLASS_NAME_TO_DISABLE2"], 450]);
   };
};

To be copied at the end of the R3F_ARTY_AND_LOG\init.sqf for example.

Replace ["CLASS_NAME_TO_DISABLE1", "CLASS_NAME_TO_DISABLE2"] by the array of class names (specific or inherited) that you want to disable.

See the CfgVehicles reference list here : http://community.bistudio.com/wiki/ArmA_2:_CfgVehicles

Share this post


Link to post
Share on other sites

Thanks for the quick reply, madbull!

I've just tried it out using

["USVehicleBox", "FlagCarrierSmall", "FlagCarrierCore"]

as the array. This now prevents the flag from being moved (wasn't sure which it was, so I put both in) - but the ammobox (which I've changed from default to a USVehicleBox in Xenos script) is still movable.

The flag wasn't placed in the editor, just a marker for it was. I'm going to try to remove the ammobox type from config.sqf within the R3F_LOG folder and see if that does it :)

Thanks for the help again,

~Z~

EDIT: taking out the ammo box type has done it - a bit heavy handed, but i'm happy :) Also added another bunker type to the loadable list, which worked.

Now I just need to add camo nets (doesn't seem to like these), and try to pre-load stuff in a cargo containers ........

Edited by zach72

Share this post


Link to post
Share on other sites

> "but the ammobox (which I've changed from default to a USVehicleBox in Xenos script) is still movable"

This is probably because the ammo crate at base is not really of type "USVehicleBox". Use the generic type "ReammoBox" which include all types of ammo box instead.

Or maybe the ammo box is spawned after the disabling script ?

> "to pre-load stuff in a cargo containers"

This is a planned feature but I'm currently too busied by IRL. Anyway, you can try it to do it yourself ;)

I think you can create a copy of "R3F_ARTY_AND_LOG\R3F_LOG\transporteur\charger_selection.sqf", replace

_objet = R3F_LOG_objet_selectionne;

by a parameter for example (this is the object to load) and "_transporteur" is the vehicle which transports. Remove all sleep and globalChat commands.

Be sure to don't execute two instance in parallel (use call compile preprocessFile for example)

Edited by madbull

Share this post


Link to post
Share on other sites

Thanks for the prompt advice again, madbull.

Unfortunately, the ammo box, although unmovable when I tried the game in the editor, once uploaded to a dedicated server, it's movable again. I'll try using ReammoBox as you suggested. I think the problem may be that this isn't spawned at map start, but instead when a client joins. I'll try putting your initial code snipped to disable stuff in there too.

Your notes on pre-load stuff I'm not good enough at reading to code to understand. I'll have to wait for someone more able to have a look at it!

I'll keep hacking at it, as I'm loving the potential of your scripts :)

~Z~

Share this post


Link to post
Share on other sites

Thx zach72,

About the ammo box on the domi base... I'm wondering if it is not a local object at each player's computer (created with createVehicleLocal).

So the solution is to execute this code for each client and for the server :

[] spawn
{
   // Wait a bit to be sure that the Domi has finished to do its stuff
   sleep 5;

   {
       _x setVariable ["R3F_LOG_disabled", true, false];
   } forEach (nearestObjects [getPos FLAG_BASE, ["ReammoBox", "FlagCarrierSmall", "FlagCarrierCore"], 450]);
};

I suggest you to copy/paste it at the end of the R3F_ARTY_AND_LOG\init.sqf.

Share this post


Link to post
Share on other sites

Is there any way in getting R3F Artillery without the logistics part?

Share this post


Link to post
Share on other sites

Can't you turn it off in the script folder somehow? I thought there was an option to turn it off.

Share this post


Link to post
Share on other sites
TODO

- add some ammo type from the BIS artillery module like smoke, WP and illumi OR make a little addon adding different charges (and maybe somke, illumi, ...)

:) If you do it think of the fuzes to

like

PD (point detonating or "Quick") Do-it-all fuze

VT (Proximity) For Soft targets , higher kill radius but significantly less damage to armored/dug targets

Delay (For Structures)

Time (For ilums)

Yes artillery makes me happy lol

And my clanmates are happy to when i throw 105mm rounds one street ahead of them lol

Share this post


Link to post
Share on other sites

@RonnieJ :

> "Is there any way in getting R3F Artillery without the logistics part? "

Yes you can.

You have to empty all the arrays in the R3F_LOG\config.sqf :

R3F_LOG_CFG_remorqueurs = [];
R3F_LOG_CFG_objets_remorquables = [];
R3F_LOG_CFG_heliporteurs = [];
R3F_LOG_CFG_objets_heliportables = [];
R3F_LOG_CFG_transporteurs = [];
R3F_LOG_CFG_objets_transportables = [];
R3F_LOG_CFG_objets_deplacables = [];

In addition, you must disabled the ability to be moved to all arty HQ. To be copy/pasted in each arty HQ init line :

this setVariable ["R3F_ARTY_demontable", false];
nul = [this] execVM "R3F_ARTY_AND_LOG\create_arty_quarter.sqf";

(Note that the setVariable must be BEFORE the execVM).

@Hbomber110 :

I will study that.

Yes artillery makes me happy lol

And my clanmates are happy to when i throw 105mm rounds one street ahead of them lol

Lol ;)

Share this post


Link to post
Share on other sites

madbull> Great got it working....:yay:

One more question

nul = [this] execVM "R3F_ARTY_AND_LOG\create_arty_quarter.sqf";

creates a quarter... is there any way of linking the option to an vehicle or person (and without the uninstall option) ??

Share this post


Link to post
Share on other sites

Execute the following when and where you want :

YOUR_OBJECT_OR_PLAYER addAction [("<t color=""#dddd00"">" + (localize "STR_R3F_ARTY_action_ouvrir_dlg_SM") + "</t>"), "R3F_ARTY_AND_LOG\R3F_ARTY\poste_commandement\ouvrir_dlg_saisie_mission.sqf", nil, 6, true, true];

"YOUR_OBJECT_OR_PLAYER" can be the keyword this in the init line of the unit/object/vehicle.

Edited by madbull

Share this post


Link to post
Share on other sites

madbull> thats über... works like a charm besides one last little thing... We have a special mod we use and in this pack we have an armed personal carrier that contains a morter in the back (M252 81mm) same type as the one on the ground.. now I cant get the artillery display up in this APC when im gunner on the morters... is there any way to add the vehicle to the artillery mod? Im not sure if there is a vehicle list somewhere? :rolleyes:

Edited by RonnieJ

Share this post


Link to post
Share on other sites
madbull> thats über... works like a charm besides one last little thing... We have a special mod we use and in this pack we have an armed personal carrier that contains a morter in the back (M252 81mm) same type as the one on the ground.. now I cant get the artillery display up in this APC when im gunner on the morters... is there any way to add the vehicle to the artillery mod? Im not sure if there is a vehicle list somewhere? :rolleyes:

In the artillery config file you will find the class names for the things that this works with. It should be that simple, but there may be more to display the proper elevation and direction.

Share this post


Link to post
Share on other sites

Yes there is a way.

Add your mortar class name in the config variable named "R3F_ARTY_CFG_pieces_artillerie" in the file "R3F_ARTY\config.sqf"

You probably have to add the new ammo type associated with your mortar.

Read the instructions about that in this message : http://forums.bistudio.com/showpost.php?p=1566035&postcount=171

Share this post


Link to post
Share on other sites

i have a problem i dont know whenit happened but i cant view the content of anything i can put stuff in but cant view it or take it out:681:

Share this post


Link to post
Share on other sites

You probably missed to copy/paste the #include code in the description.ext.

Give more informations about the problem to get more help...

Share this post


Link to post
Share on other sites

Any idea why I cant see the newly added ammo and artillery in the artillery menu?

When I open the Ammo type select box none of the added vehicles or ammo types are in the list...

R3F_ARTY_CFG_pieces_artillerie = ["M119", "D30_Base", "M252", "2b14_82mm", "DDAMM113MTD", "DDAM_vil_m109_sph"];
R3F_ARTY_tables =

[

#include "tables\table_M119_et_D30.sqf"

,

#include "tables\table_M252_et_2b14_82mm.sqf"

,

#include "tables\table_M105_et_DDAM_vil_m109_sph.sqf"

];

Edited by RonnieJ

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  

×