Jump to content
Sign in to follow this  
Cooks Corner

Add scroll option to custom ace arsenal

Recommended Posts

Im not too sure how to add a scroll option to access the custom arsenal ive made the code ive attached is whats in the init field for the ammo box that has unit specific loadouts  

[vabox, false, false] call ace_arsenal_fnc_initBox

Share this post


Link to post
Share on other sites

You don't. You use ACE interaction. 

Share this post


Link to post
Share on other sites

thats not very helpful i know you can use ace interact but id rather use a scroll option 

Share this post


Link to post
Share on other sites

Interaction is at the core of ACE, but to each their own.

 

https://ace3.acemod.org/wiki/framework/arsenal-framework.html#12-opening-an-arsenal-box-manually

 

//  in box init

this addAction
[
	"ACE Arsenal",
	{
		params ["_target", "_caller", "_actionId", "_arguments"];
		[_target, _caller] call ace_arsenal_fnc_openBox
	},
];

 

Share this post


Link to post
Share on other sites
23 minutes ago, Harzach said:

Interaction is at the core of ACE, but to each their own.

 

https://ace3.acemod.org/wiki/framework/arsenal-framework.html#12-opening-an-arsenal-box-manually

 


//  in box init

this addAction
[
	"ACE Arsenal",
	{
		params ["_target", "_caller", "_actionId", "_arguments"];
		[_target, _caller] call ace_arsenal_fnc_openBox
	},
];

 

i got it working with this code but the range on it seems to be unlimited would you know how to make it say 4 or 5 meters 

this addAction["Open Arsenal", {[vabox, player, false] call ace_arsenal_fnc_openBox}];

 

Share this post


Link to post
Share on other sites

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

this addAction
[
	"ACE Arsenal",
	{
		params ["_target", "_caller", "_actionId", "_arguments"];
		[_target, _caller] call ace_arsenal_fnc_openBox
	},
	nil,
	1.5,
	true,
	true,
	"",
	"true",
	5
];

 

You don't need the "false" param in your call as it's the default value.

Share this post


Link to post
Share on other sites
7 minutes ago, Harzach said:

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


this addAction
[
	"ACE Arsenal",
	{
		params ["_target", "_caller", "_actionId", "_arguments"];
		[_target, _caller] call ace_arsenal_fnc_openBox
	},
	nil,
	1.5,
	true,
	true,
	"",
	"true",
	5
];

 

You don't need the "false" param in your call as it's the default value.

thanks very much got that working now that helped a lot 

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  

×