Argonauta 0 Posted March 20, 2016 the ai teammate can rearm at VABox? is correct make a custom ammo box like this: crater init of virtual suply drop: nul = [] execVM "ammobox.sqf"; ammobox.sqf clearWeaponCargo _this; clearMagazineCargo _this; clearItemCargo _this; _this addweaponcargo ["launch_NLAW_F",1]; _this addweaponcargo ["launch_B_Titan_short_F",1]; _this addweaponcargo ["srifle_DMR_01_F",2]; _this addweaponcargo ["srifle_EBR_F",2]; Share this post Link to post Share on other sites
Argonauta 0 Posted March 20, 2016 don't worked!! this too!! AmmoBox.sqf _crate = _crate select 0; while {alive _crate} do { clearMagazineCargo _crate; clearWeaponCargo _crate; clearItemCargoGlobal _crate; //---------------------------Weapon _crate addweaponcargoGlobal ["launch_NLAW_F", 1]; _crate addweaponcargoGlobal ["launch_B_Titan_short_F", 1]; _crate addweaponcargoGlobal ["srifle_DMR_01_F", 2]; _crate addweaponcargoGlobal ["srifle_EBR_F", 2]; Share this post Link to post Share on other sites
barbolani 198 Posted March 20, 2016 You are messing with variables. Correct way: crater init of virtual suply drop: nul = [this] execVM "ammobox.sqf"; ammobox.sqf _crate = _this select 0; clearWeaponCargo _crate; clearMagazineCargo _crate; clearItemCargo _crate; _crate addweaponcargo ["launch_NLAW_F",1]; etc etc 1 Share this post Link to post Share on other sites
Ilias48rus 32 Posted March 20, 2016 I guies the question is answered so sorry what using the theme, but i have a question: Is it possible to simulate like some space in inventory bisy? Want to add new item to game, but it have difficult system for it, so it would be easier if it would stay in gui, but for it need to simulate weight and size in inventory.Appreciate any help | ideas. Share this post Link to post Share on other sites
barbolani 198 Posted March 20, 2016 Can be done and there are some scripts to make an alternative inventory, but definetly not an easy task. Share this post Link to post Share on other sites
Ilias48rus 32 Posted March 20, 2016 Can be done and there are some scripts to make an alternative inventory, but definetly not an easy task. Thanks for explanation, if its to difficult then another question, is it possible to store some information for exact item? (can be picked up few the items, each one should have own information) Share this post Link to post Share on other sites
Argonauta 0 Posted March 20, 2016 You are messing with variables. Correct way: crater init of virtual suply drop: nul = [this] execVM "ammobox.sqf"; ammobox.sqf _crate = _this select 0; clearWeaponCargo _crate; clearMagazineCargo _crate; clearItemCargo _crate; _crate addweaponcargo ["launch_NLAW_F",1]; etc etc Works with ammobox on the graund, but don't works with virtual supply drop. ammobox.sqf _crate = _this select 0; clearWeaponCargo _crate; clearMagazineCargo _crate; clearItemCargo _crate; //---------------------------Weapon _crate addweaponcargo ["launch_NLAW_F", 1]; _crate addweaponcargo ["launch_B_Titan_short_F", 1]; _crate addweaponcargo ["srifle_DMR_01_F", 2]; _crate addweaponcargo ["srifle_EBR_F", 2]; _crate addweaponcargo ["srifle_GM6_F", 1]; _crate addweaponcargo ["srifle_LRR_F", 1]; _crate addweaponcargo ["LMG_Mk200_F", 1]; _crate addweaponcargo ["LMG_Zafir_F", 1]; _crate addweaponcargo ["hgun_ACPC2_F", 5]; _crate addweaponcargo ["hgun_P07_F", 5]; _crate addweaponcargo ["hgun_Rook40_F", 5]; _crate addweaponcargo ["arifle_MXC_F", 3]; _crate addweaponcargo ["arifle_MX_F", 3]; _crate addweaponcargo ["arifle_MX_GL_F", 1]; _crate addweaponcargo ["arifle_MX_SW_F", 3]; _crate addweaponcargo ["arifle_MXM_F", 3]; _crate addweaponcargo ["hgun_PDW2000_F", 2]; _crate addweaponcargo ["rhs_weap_m16a4_carryhandle_grip", 2]; _crate addweaponcargo ["rhs_weap_m4a1_carryhandle_grip", 2]; _crate addweaponcargo ["rhs_weap_m249_pip_S", 1]; _crate addweaponcargo ["rhsusf_weap_m1911a1", 5]; _crate addweaponcargo ["rhsusf_weap_m9", 5]; //---------------------------Magazine _crate addmagazinecargo ["30Rnd_556x45_Stanag", 30]; _crate addmagazinecargo ["20Rnd_556x45_UW_mag", 30]; _crate addmagazinecargo ["30Rnd_65x39_caseless_mag", 30]; _crate addmagazinecargo ["20Rnd_762x51_Mag", 30]; _crate addmagazinecargo ["7Rnd_408_Mag", 30]; _crate addmagazinecargo ["5Rnd_127x108_Mag", 30]; _crate addmagazinecargo ["100Rnd_65x39_caseless_mag", 5]; _crate addmagazinecargo ["200Rnd_65x39_cased_Box", 5]; _crate addmagazinecargo ["30Rnd_9x21_Mag", 30]; _crate addmagazinecargo ["16Rnd_9x21_Mag", 30]; _crate addmagazinecargo ["RPG32_F", 5]; _crate addmagazinecargo ["RPG32_HE_F", 5]; _crate addmagazinecargo ["NLAW_F", 5]; _crate addmagazinecargo ["Titan_AT", 5]; _crate addmagazinecargo ["Titan_AP", 5]; _crate addmagazinecargo ["1Rnd_HE_Grenade_shell", 30]; _crate addmagazinecargo ["3Rnd_HE_Grenade_shell", 15]; _crate addmagazinecargo ["1Rnd_Smoke_Grenade_shell", 30]; _crate addmagazinecargo ["3Rnd_Smoke_Grenade_shell", 15]; _crate addmagazinecargo ["1Rnd_SmokeRed_Grenade_shell", 30]; _crate addmagazinecargo ["3Rnd_SmokeRed_Grenade_shell", 15]; _crate addmagazinecargo ["1Rnd_SmokeGreen_Grenade_shell", 30]; _crate addmagazinecargo ["3Rnd_SmokeGreen_Grenade_shell", 15]; _crate addmagazinecargo ["1Rnd_SmokeYellow_Grenade_shell", 30]; _crate addmagazinecargo ["3Rnd_SmokeYellow_Grenade_shell", 15]; _crate addmagazinecargo ["1Rnd_SmokePurple_Grenade_shell", 30]; _crate addmagazinecargo ["3Rnd_SmokePurple_Grenade_shell", 15]; _crate addmagazinecargo ["1Rnd_SmokeBlue_Grenade_shell", 30]; _crate addmagazinecargo ["3Rnd_SmokeBlue_Grenade_shell", 15]; _crate addmagazinecargo ["1Rnd_SmokeOrange_Grenade_shell", 30]; _crate addmagazinecargo ["3Rnd_SmokeOrange_Grenade_shell", 15]; _crate addmagazinecargo ["HandGrenade", 30]; _crate addmagazinecargo ["MiniGrenade", 30]; _crate addmagazinecargo ["HandGrenade_Stone", 30]; _crate addmagazinecargo ["SmokeShell", 30]; _crate addmagazinecargo ["SmokeShellRed", 30]; _crate addmagazinecargo ["SmokeShellGreen", 30]; _crate addmagazinecargo ["SmokeShellYellow", 30]; _crate addmagazinecargo ["SmokeShellPurple", 30]; _crate addmagazinecargo ["SmokeShellBlue", 30]; _crate addmagazinecargo ["SmokeShellOrange", 30]; _crate addmagazinecargo ["Chemlight_green", 50]; _crate addmagazinecargo ["Chemlight_red", 50]; _crate addmagazinecargo ["Chemlight_yellow", 50]; _crate addmagazinecargo ["Chemlight_blue", 50]; _crate addmagazinecargo ["60Rnd_CMFlareMagazine", 15]; _crate addmagazinecargo ["60Rnd_CMFlare_Chaff_Magazine", 15]; _crate addmagazinecargo ["SmokeLauncherMag", 30]; _crate addmagazinecargo ["UGL_FlareWhite_F", 30]; _crate addmagazinecargo ["3Rnd_UGL_FlareWhite_F", 15]; _crate addmagazinecargo ["11Rnd_45ACP_Mag", 30]; _crate addmagazinecargo ["6Rnd_45ACP_Cylinder", 30]; _crate addmagazinecargo ["10Rnd_762x51_Mag", 30]; //---------------------------Item _crate additemcargo ["optic_Hamr", 10]; _crate additemcargo ["optic_Holosight", 10]; _crate additemcargo ["optic_Arco", 10]; _crate additemcargo ["optic_ACO_grn", 10]; _crate additemcargo ["optic_DMS", 10]; _crate additemcargo ["optic_LRPS", 10]; _crate additemcargo ["optic_SOS", 10]; _crate additemcargo ["optic_Nightstalker", 10]; _crate additemcargo ["acc_flashlight", 10]; _crate additemcargo ["acc_pointer_IR", 10]; _crate additemcargo ["muzzle_snds_B", 10]; _crate additemcargo ["muzzle_snds_L", 10]; _crate additemcargo ["rhsusf_acc_ACOG_pip", 10]; _crate additemcargo ["rhsusf_acc_ACOG_sa", 10]; _crate additemcargo ["rhsusf_acc_ACOG_d", 10]; _crate additemcargo ["rhsusf_acc_ACOG_wd", 10]; _crate additemcargo ["rhsusf_acc_ACOG", 10]; Share this post Link to post Share on other sites
barbolani 198 Posted March 20, 2016 then you should have said you want to do it with virtual ammobox, don't you think? In that case I think you have to put all the stuff in the box init textbox with some reference, no _crate.. Share this post Link to post Share on other sites
Argonauta 0 Posted March 20, 2016 the problem is I want to find a way to make the AI teammates rearm with a box of ammunition by suply drop. I have a virtual arsenal, but the AI teamate can't rearm with it. Share this post Link to post Share on other sites
Ilias48rus 32 Posted March 20, 2016 You can use commands to add and remove items on units and the ammobox. 1 Share this post Link to post Share on other sites
Argonauta 0 Posted March 20, 2016 I found a script that solve my probem ... Thx!! Share this post Link to post Share on other sites
zagor64bz 1225 Posted March 21, 2016 I found a script that solve my probem ... Thx!! Which is? TnX!!!! Share this post Link to post Share on other sites
Argonauta 0 Posted March 21, 2016 Which is? TnX!!!! this one https://forums.bistudio.com/topic/177299-customizable-supply-drop-release/ Share this post Link to post Share on other sites
Argonauta 0 Posted March 21, 2016 Anyone can explain me how can i do to change this script below, by soolie (https://forums.bistudio.com/topic/177299-customizable-supply-drop-release/), to work with this mod >> http://www.armaholic.com/page.php?id=28024 /*TUTORIAL */_supplyBoxFnc = _this select 1;_supplyCargoFnc = _this select 2;openMap [true,true];clicked = 0;//hintc "Left click on the map where you want the supplies dropped";["supplymapclick", "onMapSingleClick", {_supplyLocArray = [+1000,-1375,-1500,-1125,+1250,-1000,+1375,-1250,+1500,+1125];//:::::::::::|USE THE ONE BELOW FOR TESTING, IT SPAWNS THE HELI MUCH CLOSER|:::::::::::// _supplyLocArray = [+500,-500]; ////////////////////////////////////////////////////////////////////////////////////////////////_supplyRandomLocX = _supplyLocArray select floor random count _supplyLocArray;_supplyRandomLocY = _supplyLocArray select floor random count _supplyLocArray;_supply = [[(_pos select 0)+_supplyRandomLocX,(_pos select 1)+_supplyRandomLocY,(_pos select 2)+50], 180, "sab_C130_H_CSAT3", WEST] call bis_fnc_spawnvehicle;_supplyHeli = _supply select 0;_supplyHeliPos = getPos _supplyHeli;_supplyMrkrHeli = createMarker ["supplyMrkrHeli", _supplyHeliPos];_supplyCrew = _supply select 1;_supplyGrp = _supply select 2;_supplyGrp setSpeedMode "FULL";_supplyGrp setBehaviour "CARELESS";_supplyWP1 =_supplyGrp addWaypoint [(_pos),1];_supplyWP1 setWaypointType "MOVE";_supplyWP2 = _supplyGrp addWaypoint [[(_pos select 0)+_supplyRandomLocX,(_pos select 1)+_supplyRandomLocY,_pos select 2], 2];_supplyMrkrLZ = createMarker ["supplyMrkrLZ", _pos];"supplyMrkrLZ" setMarkerType "Empty";"supplyMrkrHeli" setMarkerType "Empty";_supplyHeli flyInHeight 150;clicked = 1;openmap [false,false];onMapSingleClick '';}] call BIS_fnc_addStackedEventHandler;waitUntil {(clicked == 1)};hint "The supplies are on the way";_supplyMrkrHeliPos = getMarkerPos "supplyMrkrHeli";_supplyMrkrHeliPos2 = [_supplyMrkrHeliPos select 0,_supplyMrkrHeliPos select 1,(_supplyMrkrHeliPos select 2)+50];_supplyHeli = _supplyMrkrHeliPos2 nearestObject "sab_C130_H_CSAT3";_supplyMrkrLZPos = getMarkerPos "supplyMrkrLZ";_supplyLZ = createVehicle ["Land_Laptop_device_F", getMarkerPos "supplyMrkrLZ", [], 0, "NONE"];deleteMarker "supplyMrkrHeli";deleteMarker "supplyMrkrLZ";_supplyLZ hideObject true;waitUntil {( _supplyLZ distance _supplyHeli)<400};_supplyHeli animateDoor ["CargoRamp_Open",1];waitUntil {( _supplyLZ distance _supplyHeli)<200};sleep 2;_supplyHeli allowDammage false;_supplyBox = createVehicle[_supplyBoxFnc, position _supplyHeli, [], 0, "CAN_COLLIDE"];clearBackpackCargoGlobal _supplyBox;clearWeaponCargoGlobal _supplyBox;clearMagazineCargoGlobal _supplyBox;clearItemCargoGlobal _supplyBox;//_supplyBox addAction ["Open Garage",{_pos = [ player, 30, getDir player ] call BIS_fnc_relPos; BIS_fnc_garage_center = createVehicle [ "Land_HelipadEmpty_F", _pos, [], 0, "CAN_COLLIDE" ]; [ "Open", true ] call BIS_fnc_garage;}];//Virtual Vehicle Arsenal_supplyBox addAction ["Virtual Arsenal", {["Open",true] spawn BIS_fnc_arsenal}]; //put here to open VA_supplyBox disableCollisionWith _supplyHeli;_supplyHeli disableCollisionWith _supplyBox;_supplyBox allowDammage false;_supplyBox attachTo [_supplyHeli, [0, 0, 0], "CargoRamp"];_supplyBox setDir ([_supplyBox, _supplyHeli] call BIS_fnc_dirTo);detach _supplyBox;deleteVehicle _supplyLZ;[_supplyBox,_supplyCargoFnc,nil,true] spawn BIS_fnc_MP;[_supplyBox,"FncSupplyLight",nil,true] spawn BIS_fnc_MP;_supplyChute = createVehicle ["B_parachute_02_F", position _supplyBox, [], 0, "CAN_COLLIDE"];_supplyBox attachTo [_supplyChute,[0,0,-0.5]];_supplyChute hideObject true;_supplyChute setPos getPos _supplyBox;//:::::::::::|LIGHT|:::::::::::_supplyLight = "Chemlight_green" createVehicle (position _supplyBox);_supplyLight attachTo [_supplyBox, [0,0,0]];//:::::::::::::::::::::::::::::sleep 1;hint "The supplies have been dropped";_supplyChute hideObject false;_supplyHeli allowDammage true;_supplyBox allowDammage true;_supplyHeli animateDoor ["CargoRamp_Open",0];//:::::::::::|SMOKE|:::::::::::_supplySmoke = "SmokeShellYellow" createVehicle (position _supplyBox);_supplySmoke attachTo [_supplyBox, [0,0,0]];//:::::::::::::::::::::::::::::waitUntil {(getPos _supplyBox select 2)<2};detach _supplyBox;_supplyChute setPos [ (getPos _supplyChute select 0)+0.75, getPos _supplyChute select 1, getPos _supplyChute select 2];hint "";sleep 5;{deleteVehicle _x;}forEach crew _supplyHeli;deleteVehicle _supplyHeli;//hint "end"; in this script i only changed the vehicle to "sab_C130_H_CSAT3", it sometimes works and sometimes don't. this Supply Drop consists of two scripts, one is already all right, I'm having trouble with this up to make the C130 drop the suply. Share this post Link to post Share on other sites