Jump to content
Sign in to follow this  
UmbrellaICE

Change SuitCase to ammo box

Recommended Posts

Okay I am trying to create a new ammo box out of the suitcase object, anyone have any idea how to do this so far i am having no luck. or maybe change the object of the ammo crate to the suitcase? this is for a mission i am working on. I am very new to arma 2 scripting.

Share this post


Link to post
Share on other sites

*snipped* script was for ArmA 3, not ArmA 2.

Edited by IT07

Share this post


Link to post
Share on other sites

Oh dang it. I misread the forum section. Sorry the script I gave you is for ArmA 3 :(

Share this post


Link to post
Share on other sites

its okay i need to upgrade to arma 3 eventually anyway :yay: just hope they dont shut down the servers like with arma 2 free, maybe they should have real in game streaming radio though no one would listen lol be to busy trying not to get shot or eaten by zombies lol. I did try a script to see if it would work earlier but epic fail. if only i could see the actual script for the default ammo box maybe i could do something...

Share this post


Link to post
Share on other sites

Only the other day I learnt I can add and remove weapons and magazines from ammo boxes and vehicles.

As a test, I successfully added weapons to a tea pot but my soldier could not pick up the weapons.

I think you need an "event handler" but I have not had the time to search

Share this post


Link to post
Share on other sites

One way is to place an addaction on the suitcase that opens a remote ammo box.

Place an ammobox on the map name it ammobox1 and in the init put

this hideobject true;

Place this in the init of the suitcase

this addaction ["Open Case","ammobox.sqf",ammobox1, 6, true, true, "", "(_this distance (_target))<3  and !(player in _target)"];

and save this script as ammobox.sqf

_ammobox = _this select 3;
_Player = _this select 1;
_ammobox setpos position _player;
_Player action ["Gear", _ammobox];

Share this post


Link to post
Share on other sites

alright now when i try to change the stuff in the ammobox it wont work....jeez...i suck...any ideas? i tried putting weapons on the script but epic fail..

Share this post


Link to post
Share on other sites

In the ammo box init

this hideobject true; clearWeaponCargoGlobal this;this addWeaponCargoGlobal ["arifle_MX_ACO_pointer_F",5];

or if your doing it later from script or trigger you will need the name of the ammo box

clearWeaponCargoGlobal ammobox1;ammobox1 addWeaponCargoGlobal ["arifle_MX_ACO_pointer_F",5];

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  

×