Jump to content
7erra

Add single object to Zeus

Recommended Posts

Hello everyone,

 

just got back to scripting again. Here's my problem: Is there a way to add only a specific object to the Zeus so he can place it wherever he wants? Current workarounds (which are not what I really want to use though):

  • addCuratorAddons adds the entire addon to which the object belongs, making far more objects accessible than wanted
  • spawn the object and add it to Zeus with addCuratorEditableObjects
  • adding a cfgPatches entry to the description.ext didn't work (just as expected)
  • making the cost of unwanted objects too high to purchase

 

Thanks,

 

Terra

Share this post


Link to post
Share on other sites

Alright I've found a solution on my own: Using BIS_fnc_curatorObjectRegisteredTable you can only add the classnames of the objects that you want. If you want to place an unlimited amount of objects just set the cost to 0. The Zeus module has to have all addons unlocked beforehand, otherwise the objects won't be added. Example:

[curatorObj,[
	"Land_HBarrier_01_line_1_green_F", 0,
	"Land_HBarrier_01_wall_corridor_green_F", 0
]] call BIS_fnc_curatorObjectRegisteredTable;

This will only unlock the Hesco barriers.

 

As to what I want to achieve after all is a building system and it just got a lot better ;) I may make a guide for this at some point.

  • Thanks 1

Share this post


Link to post
Share on other sites

I wanted to do the same, add only single objects and not whole collection with addCuratorAddons but 7erra's code is not working for me... Any ideas?

 

Edit: nevermind! it seems removeAllCuratorAddons prevented the items to be listed

 

 

Edited by gc8

Share this post


Link to post
Share on other sites

Have to ask here if someone knows, can you use both the  BIS_fnc_curatorObjectRegisteredTable and addCuratorAddons?

 

I tried and it didn't work but maybe I called the functions in wrong order or something, any one knows if this is possible?

 

Share this post


Link to post
Share on other sites
21 minutes ago, gc8 said:

Have to ask here if someone knows, can you use both the  BIS_fnc_curatorObjectRegisteredTable and addCuratorAddons?

 

I tried and it didn't work but maybe I called the functions in wrong order or something, any one knows if this is possible?

 

Both are different things afaik.
One sets the cost, which doesn't help you anything if the object isn't even available. And the other makes objects available.

Share this post


Link to post
Share on other sites
6 minutes ago, Dedmen said:

One sets the cost, which doesn't help you anything if the object isn't even available. And the other makes objects available.

 

Hmm I have in the past used addCuratorAddons to make objects available for placing. So it seems they are two approaches to same problem. 

Share this post


Link to post
Share on other sites
On ‎2‎/‎15‎/‎2018 at 7:16 PM, 7erra said:

Alright I've found a solution on my own: Using BIS_fnc_curatorObjectRegisteredTable you can only add the classnames of the objects that you want. If you want to place an unlimited amount of objects just set the cost to 0. The Zeus module has to have all addons unlocked beforehand, otherwise the objects won't be added. Example:


[curatorObj,[
	"Land_HBarrier_01_line_1_green_F", 0,
	"Land_HBarrier_01_wall_corridor_green_F", 0
]] call BIS_fnc_curatorObjectRegisteredTable;

This will only unlock the Hesco barriers.

 

As to what I want to achieve after all is a building system and it just got a lot better ;) I may make a guide for this at some point.

 

I am very new to scripting with Arma 3, and I am having trouble getting this to work (currently trying to test what you have done).

 

It keeps coming up with an error when I load from the Eden Editor into a multiplayer game to test the map.

 

This is what I put into my "init.sqf".

 

[curatorObj,[
 "Land_HBarrier_01_line_1_green_F", 0,
 "Land_HBarrier_01_wall_corridor_green_F", 0]] call

BIS_fnc_curatorObjectRegisteredTable;

 

It does not seem to like this at all. Just wondering what I am doing wrong.

Share this post


Link to post
Share on other sites
21 hours ago, rkemsley said:

It keeps coming up with an error when I load from the Eden Editor into a multiplayer game to test the map.

So what does the error say? Did you name your Gamemaster module curatorObj?

 

Share this post


Link to post
Share on other sites

I've now managed to get it working

 

This is the code I'm using in my init.sqf

 

[BLUFOR_Zeus_Module,

['ModuleRemoteControl_F',0,
'B_Soldier_SL_F',2,
'B_soldier_LAT_F',2.6,
'B_soldier_M_F',2,
'B_Soldier_TL_F',1.6,
'B_soldier_AR_F',2,
'B_Soldier_A_F',1.4,
'B_medic_F',2,
'B_Soldier_F',1,
'B_Soldier_GL_F',1.4,
'B_sniper_F',4,
'B_spotter_F',2,
'B_engineer_F',2.6,
'B_soldier_repair_F',2.4,
'B_soldier_exp_F',2.6,
'B_recon_TL_F',1.2,
'B_recon_medic_F',1.6,
'B_recon_LAT_F',2.2,
'B_recon_JTAC_F',2,
'B_recon_exp_F',2.2,
'B_recon_M_F',1.6,
'B_recon_F',0.6,

'B_Quadbike_01_F',3,
'B_MRAP_01_F',5,

'B_HMG_01_F',2,
'B_HMG_01_high_F',2,
'B_GMG_01_F',3,
'B_GMG_01_high_F',3]]

call bis_fnc_curatorObjectRegisteredTable;

 

This seems to do the trick (for anyone else who is still having problems)

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

×