Jump to content
Frankdatank1218

How to use Virtual Arsenal like the Virtual Ammobox System?

Recommended Posts

how about - this addaction ["Open VA",{["Open",true] call BIS_fnc_arsenal}];

perfect

this addaction ["Virtual Arsenal",{["Open",true] call BIS_fnc_arsenal}];

Share this post


Link to post
Share on other sites

hi

just try :

["Open",true] spawn BIS_fnc_arsenal;

no way to put missiles in bag (dev or stable branch) in some bags where there are in the menu. Random choice, doesnt put missiles too in bags. Is there a way to fix that ?

Edited by code34

Share this post


Link to post
Share on other sites

Will VA work with saved profiles from the mission maker to a box? So i get one of the 2:

1. action menü "Load XYZ profile"

2. Get in VA and with "Load profile" i get 10 loadouts the mission maker made for the players?

Share this post


Link to post
Share on other sites

Any ideas how to apply a whitelist using '[] spawn BIS_fnc_arsenal' ?

Specifically:

https://community.bistudio.com/wiki/Arsenal

Access

You can use Arsenal in a scenario you're designing simply by calling the following function:

[] spawn BIS_fnc_arsenal;

This version has several limitations as opposed to the Virtual one:

Voice, Face and Insignia are not available (to avoid clashing with profile)

Not all assets are automatically present, designer has to whitelist allowed classes. By default, only player's current equipment is available.

To open Arsenal with full options, execute:

["Open",true] spawn BIS_fnc_arsenal;

The section in bold, and more precisely the bolded and underlined portion.

No, I do not want to use "AmmoboxInit" argument.

Share this post


Link to post
Share on other sites
Any ideas how to apply a whitelist using '[] spawn BIS_fnc_arsenal' ?

Specifically:

https://community.bistudio.com/wiki/Arsenal

The section in bold, and more precisely the bolded and underlined portion.

No, I do not want to use "AmmoboxInit" argument.

You can find the add, remove and get functions below. Though I am not sure how well they work yet. Someone had troubles using those.

Share this post


Link to post
Share on other sites

Hi,

Any tips how to blacklist and whitelist arsenal?

I would like to ad VA to my mission, but to black list all NVGoogles at start, any ideas how to do this?

Thank You,

Share this post


Link to post
Share on other sites
You can find the add, remove and get functions below. Though I am not sure how well they work yet. Someone had troubles using those.

AFAIK those are applied to the "AmmoboxInit" argument, since an object must be specified to apply the add-action to.

Share this post


Link to post
Share on other sites

Is there any option to launch the Virtual Arsenal not for the player but for a particular AI teammate, without switching to the AI with "U" ?

Share this post


Link to post
Share on other sites

Did anyone find out how to blacklist certain weapons and items in the VA? I'm still scratchin' my noggin. :headscratch:

I've worked out how to whitelist but a blacklist is what i need. I'd like all gear available (including active weapon mods) with a few exceptions. Eg. No NVGs or AA launchers.

Share this post


Link to post
Share on other sites

Hi,

Do you know how can enter virtual arsenal when you are in mission briefing? It would be nice in missions without respawn.

Thanks!!

Share this post


Link to post
Share on other sites

I want to have virtual arsenal in place of VAS due to player wait time for VAS. I have this on a radio trigger. But no virtual arsenal. ideas? J.Shock? :)

VABox = createVehicle ["B_supplyCrate_F", position thisTrigger, [], 0, ""]; clearMagazineCargoGlobal VABox; clearWeaponCargoGlobal VABox; clearItemCargoGlobal VABox; clearBackpackCargoGlobal VABox; ["AmmoboxInit",[this,true]] call BIS_fnc_arsenal; hint "Supply drop at marker"; "supply drop" setMarkerAlpha 1; chemlight = createVehicle ["chemlight_blue", position thisTrigger, [], 0, ""]; this allowDamage false;

Share this post


Link to post
Share on other sites
I want to have virtual arsenal in place of VAS due to player wait time for VAS. I have this on a radio trigger. But no virtual arsenal. ideas? J.Shock? :)

VABox = createVehicle ["B_supplyCrate_F", position thisTrigger, [], 0, ""]; clearMagazineCargoGlobal VABox; clearWeaponCargoGlobal VABox; clearItemCargoGlobal VABox; clearBackpackCargoGlobal VABox; ["AmmoboxInit",[this,true]] call BIS_fnc_arsenal; hint "Supply drop at marker"; "supply drop" setMarkerAlpha 1; chemlight = createVehicle ["chemlight_blue", position thisTrigger, [], 0, ""]; this allowDamage false;

Well, actually I haven't messed with the VA much, but for slow VAS loading times, I know how to fix that (unless your running MCC, which seems to unfix this fix).

So in the VAS folder there is a config.sqf, open it, in it you will see a number of comments and a few lines of actual code at the top, the last line of actual code says: "vas_disableSafteyCheck", you will want to set that to true, not false, and that should allow VAS to load instantly (unless you have MCC, like I said), now there might not be any items loaded right away, but you will be able to get to all your saved loadouts to gear up.

//Allow player to respawn with his loadout? If true unit will respawn with all ammo from initial save! Set to false to disable this and rely on other scripts!
vas_onRespawn = true;

//Preload Weapon Config?
vas_preload = true;

//If limiting weapons its probably best to set this to true so people aren't loading custom loadouts with restricted gear.
vas_disableLoadSave = false;

//Amount of save/load slots
vas_customslots = 14; //14 is actually 15 slots, starts from 0 to whatever you set, so always remember when setting a number to minus by 1, i.e 12 will be 11.

//Disable 'VAS hasn't finished loading' Check !!! ONLY RECOMMENDED FOR THOSE THAT USE ACRE AND OTHER LARGE ADDONS !!!
vas_disableSafetyCheck = true;/*<<<<<<<<<<<*/
//^^^^^^^This one

Share this post


Link to post
Share on other sites
thanks JShock.

dang, this group I play with uses MCC. :681:

Yea I have been to lazy myself to read through the copious amounts of posts in the MCC thread to see if there was a fix for that, but eh, most of my guys end up using Outfit Gear or other things like that.

Share this post


Link to post
Share on other sites

Hi, im using this for whitelist on virtual arsenal.

_this = cargonet;

//--- BACKPACKS
[_this,[

"B_AssaultPack_cbr",
"B_Kitbag_cbr",
"B_FieldPack_cbr",
"B_TacticalPack_cbr",
"B_Carryall_mcamo",

"rhsusf_assault_eagleaiii_ocp",

"tf_rt1523g_rhs",
"tf_rt1523g_big_rhs"

],true] call BIS_fnc_addVirtualBackpackCargo;

//--- MAGAZINES
[_this,[

"30Rnd_556x45_Stanag",
"30Rnd_556x45_Stanag_Tracer_Red",

"rhsusf_100Rnd_556x45_soft_pouch",

"rhsusf_100Rnd_762x51",

"20Rnd_762x51_Mag",

"16Rnd_9x21_Mag",

"6Rnd_GreenSignal_F",
"6Rnd_RedSignal_F",

"rhs_m136_mag",
"rhs_fim92_mag",
"rhs_fgm148_magazine_AT",

"Laserbatteries",

"SmokeShell",
"SmokeShellBlue",
"SmokeShellYellow",
"SmokeShellGreen",
"SmokeShellOrange",
"SmokeShellPurple",
"SmokeShellRed",

"HandGrenade",
"MiniGrenade",
"B_IR_Grenade",

"AGM_M84",

"AGM_HandFlare_Green",
"AGM_HandFlare_Red",
"AGM_HandFlare_White",
"AGM_HandFlare_Yellow",

"rhs_mag_M441_HE",
"rhs_mag_M433_HEDP",
"rhs_mag_M4009",
"rhs_mag_m576",
"rhs_mag_M585_white",
"rhs_mag_M661_green",
"rhs_mag_M662_red",
"rhs_mag_M713_red",
"rhs_mag_M714_white",
"rhs_mag_M715_green",
"rhs_mag_M716_yellow",

"UGL_FlareCIR_F",
"UGL_FlareGreen_F",
"UGL_FlareRed_F",
"UGL_FlareWhite_F",

"Chemlight_green",
"Chemlight_red",
"Chemlight_yellow",
"Chemlight_blue",

"ATMine_Range_Mag",
"APERSTripMine_Wire_Mag",
"DemoCharge_Remote_Mag",
"SatchelCharge_Remote_Mag"

],true] call BIS_fnc_addVirtualMagazineCargo;


//--- WEAPONS
[_this,[

//--- rifles 
"rhs_weap_m4a1_grip",

//--- GLs
"rhs_m4a1_m320",
"rhs_weap_M320",

//--- mgs
"rhs_weap_m240B",
"rhs_weap_m249_pip",

//--- snipers
"rhs_weap_m14ebrri",
"RH_mk12mod1",

//--- smgs

//--- launchers
"rhs_weap_M136",
"rhs_weap_fgm148",
"rhs_weap_fim92",

//--- pistols
"hgun_Rook40_F",
"hgun_Pistol_Signal_F",

//--- binoc types
"AGM_Vector",
"Binocular"

],true] call BIS_fnc_addVirtualWeaponCargo;

//--- ITEMS
[_this,[

//--- ITEMS
"ItemCompass",
"ItemGPS",
"ItemMap",
"ItemWatch",
"NVGoggles_OPFOR",
"ToolKit",

"tf_rf7800str",
"tf_anprc152",

"AGM_ItemKestrel",
"AGM_EarBuds",
"AGM_UAVBattery",
"AGM_MapTools",
"AGM_CableTie",
"AGM_Clacker",
"AGM_M26_Clacker",
"AGM_DefusalKit",

"AGM_Bandage",
"AGM_Morphine",
"AGM_Epipen",
"AGM_Bloodbag",

"AGM_SpareBarrel",

//--- SIGHT

"rhsusf_acc_HAMR",
"rhsusf_acc_ELCAN",

"RH_compM4s",
"RH_eotech553",
"RH_t1",
"RH_reflex",
"RH_Delft",
"RH_ta31rco",
"RH_m3lr",

//--- SUPS

"RH_spr_mbs",

//--- ATTACHMENTS

"RH_peq2",
"RH_peq2_top",
"RH_peq15",
"RH_peq15_top",
"RH_m4covers_s",
"RH_m4covers_f",

//--- UNIFORMS

"rhs_uniform_cu_ocp",

//--- VESTS

"rhsusf_iotv_ocp",
"rhsusf_iotv_ocp_grenadier",
"rhsusf_iotv_ocp_medic",
"rhsusf_iotv_ocp_repair",
"rhsusf_iotv_ocp_rifleman",
"rhsusf_iotv_ocp_SAW",
"rhsusf_iotv_ocp_squadleader",
"rhsusf_iotv_ocp_teamleader",

//--- HELMETS

"rhsusf_ach_helmet_ocp",
"rhsusf_ach_helmet_camo_ocp",
"rhsusf_ach_helmet_ess_ocp",
"rhsusf_ach_helmet_headset_ocp",
"rhsusf_ach_helmet_headset_ess_ocp",

"rhsusf_cvc_helmet",
"rhsusf_cvc_ess",
"H_PilotHelmetHeli_B",
"H_CrewHelmetHeli_B",


//--- GOOGLES

"G_Spectacles",
"G_Combat",
"G_Aviator",
"G_Sport_Blackred",
"G_Lowprofile",
"G_Shades_Black"

],true] call BIS_fnc_addVirtualItemCargo;	

["Preload"] call BIS_fnc_arsenal; 

It works fine, but when i save a loadout i cant load it again.

Someone know whats happening?? im not using other items that arent in whitelist.

Thanks!!

Share this post


Link to post
Share on other sites

Hi first of all.

I want to know how can i add all the items of the CSE (bandages,blood bags,etc..) into the Virtual Arsenal used like a Virtual Ammobox.

Thanks in advance for the reply.

Share this post


Link to post
Share on other sites
Hi first of all.

I want to know how can i add all the items of the CSE (bandages,blood bags,etc..) into the Virtual Arsenal used like a Virtual Ammobox.

Thanks in advance for the reply.

Reference this page, especially the BIS_fnc_addVirtualItemCargo function.

Share this post


Link to post
Share on other sites

Hi...

i am having a little trouble with my script...

I want to add the Arsenal to four boxes by executing a script called "arsenal.sqf". Only when this script is executed those boxes shall have the option to enter the arsenal.

if( isServer ) then {

{ 
arsenalbox_1 addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];
arsenalbox_2 addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];
arsenalbox_3 addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];
arsenalbox_4 addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];

} forEach ["arsenalbox_1","arsenalbox_2","arsenalbox_3","arsenalbox_4"];

};

if(true) exitWith{};

So far so good, but now every box has 4 addactions in the scroll menu. What am i doing wrong?

Share this post


Link to post
Share on other sites

audio you are naming each box in the foreach loop, so in effect running the script 4 times.

[color=#333333]if( isServer ) then {[/color]
   { 
   _x addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];

   } forEach [arsenalbox_1,arsenalbox_2,arsenalbox_3,arsenalbox_4];

};

if(true) exitWith{};

also you need to make sure they are not strings in the array of the foreach as these are objects you are referring to. (i guess)

alternative option

[color=#333333]if( isServer ) then {[/color]
   arsenalbox_1 addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];
   arsenalbox_2 addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];
   arsenalbox_3 addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];
   arsenalbox_4 addaction ["Open Virtual Arsenal", { ["Open",true] call BIS_fnc_arsenal; }];


};

Edited by KevsnoTrev

Share this post


Link to post
Share on other sites

It because your adding the action to each box, for each box because of the loop, take off the forEach loop and you should be good to go.

EDIT: Ninja'd

Share this post


Link to post
Share on other sites

is it possible to add filters to the virtual arsenal, so if you are CSAT player you can have acces only to CSAT weapons clothes backpacks...

Share this post


Link to post
Share on other sites
is it possible to add filters to the virtual arsenal, so if you are CSAT player you can have acces only to CSAT weapons clothes backpacks...

At this point I believe you would have to just make the box yourself with the add/remove functions provided, I don't think there are any filters for side or so forth.

Share this post


Link to post
Share on other sites

Maybe could possibly use configClasses

if I remember correctly search for side = 0

I'll maybe post some code later, currently out.

_csatweapons = 'getNumber (_x >> side) == 0' configClass (configFile >> 'cfgWeapons');
_changetoclassname = [];
{_changetoclassname = _changetoclassname + [configName _x];}forEach _csatweapons;
[myBox,_changetoclassname,true] call BIS_fnc_addVirtualWeaponCargo;

now you would need magazines (cfgMagazines), (these will be tricky) then backpacks (cfgVehicles), and then clothes/items (cfgItems)

Share this post


Link to post
Share on other sites
now you would need magazines (cfgMagazines)

Here is an iteration of the code within my redressing script that searches the config for the magazines of the weapon, I changed it to included the magazine add function for Arsenal:

{
_weapon = _x;
_muzzles = getArray(configfile >> "cfgWeapons" >> (_weapon) >> "muzzles");

{ 
	if (_x isEqualTo "this") then 
	{
		_mags = getArray(configfile >> "cfgWeapons" >> (_weapon) >> "magazines");
		[_box,_mags,true] call BIS_fnc_addVirtualMagazineCargo;
	} 
	else 
	{ 
		_mags = getArray(configfile >> "cfgWeapons" >> (_weapon) >> _x >> "magazines"); 
		[_box,_mags,true] call BIS_fnc_addVirtualMagazineCargo;
	}; 
} forEach _muzzles;  
} forEach _csatweapons;

Share this post


Link to post
Share on other sites

Just did some quick research on my code and it turns out that there is no 'side' for weapons but instead what we could do is change it to this (careful this is for vanilla so you may want to add your own for mods (AK's and such))

_csatweapons = "((configName _x find 'Zafir') OR (configName _x find 'Katiba') OR getText (_x >> 'displayName) find 'Sting'))" configClasses (configFile >> 'cfgWeapons'); 

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

×