Jump to content

player removal of building parts to get back


nova

Recommended Posts

I have it in the  configVariables.sqf

 

add this

DZE_modularConfig = [
        ["CinderWall_DZ", [["CinderBlocks",7],["MortarBucket",2]]],
        ["CinderWallDoor_DZ", [["CinderBlocks",7],["MortarBucket",2],["ItemTankTrap",3],          ["ItemPole",[1,3]]]]
    ];

 
Link to comment
Share on other sites

7 hours ago, juandayz said:

its works without anykind of changes in remove.sqf? just adding the global variable in configvariables?

There are changes for remove.sqf, I realise now that because I don't have commit access on github and I have to do pull requests seperately, they come through seperate.

https://github.com/EpochModTeam/DayZ-Epoch/commit/0507563e17b7e00e2bed0c23cc3e72ba9ababeb7 is the commit for remove.sqf

https://github.com/EpochModTeam/DayZ-Epoch/commit/e1f48ea5579d65b36acf36d6f7d6e50def4042e8 is the commit for configVariables.sqf

So i'm guessing @SKS.Goliath is missing the remove.sqf part (which was easily done considering my first post)

Link to comment
Share on other sites

Hey guys,

For anyone else that wants to switch to this before the release of 1.0.6.2, here's a simple installation example:

1. If you have my zsc/vkc/vg or similar that uses the epoch dayz_code structure in your mission pbo, copy the supplied remove.sqf to your <mission folder>\dayz_code\action folder.

2. Find this line in your fn_selfActions.sqf: 

s_player_deleteBuild = player addAction [format[localize "STR_EPOCH_REMOVE",_text], "\z\addons\dayz_code\actions\remove.sqf",_cursorTarget, 1, false, true];

Change it to reference the updated remove.sqf (if you use a different folder structure other than dayz_code like I do, you can edit this here (boooo!)) like this:

s_player_deleteBuild = player addAction [format[localize "STR_EPOCH_REMOVE",_text], "dayz_code\actions\remove.sqf",_cursorTarget, 1, false, true];

3. If you have a custom variables.sqf (which is where I put all my configVariables.sqf overrides, copy paste this into it somewhere at the top:

DZE_modularConfig = [];
/*
	Array of classnames with magazine based loot to be refunded on deconstruction of modular built items that do not typically refund.
	For example:
	DZE_modularConfig = [
		["CinderWall_DZ", [["CinderBlocks",7],["MortarBucket",2]]],
		["CinderWallDoor_DZ", [["CinderBlocks",7],["MortarBucket",2],["ItemTankTrap",3],["ItemPole",[1,3]]]]
	];
	This would refund 7 cinder blocks and 2 mortar for "CinderWall_DZ"
	For "CinderWallDoor_DZ" you would get 7 cinder blocks, 2 mortar, 3 tank traps and a random number of poles between 1 and 3.
	The refund amount can be an array where the first param is the minimum and the second is the maximum, it will refund a random amount between them.
*/

4. Repack your mission pbo and restart your server.

Link to comment
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
  • Discord

×
×
  • Create New...