Credits and Thanks:
This script owes it's roots to Sushi's breaching script, found here: http://www.armaholic.com/page.php?id=30573 This is based off V. 1.3 of sushi's script, which had a lot of good fixes and code. I helped with some of the code in the past, but the reality is 99% of this work is Sushi's and as such, here are Sushi's original credits and thanks:
"This script is inspired by great Jarhead (http://www.armaholic.com/page.php?id=25202) script and i use little part of his code to place explosives on doors and stun AI. All credits for this part of code should go to him. Version 1.2 was created with huge help of Yakavetta. Thank You for Your feedback and parts of code."
I don't own any rights to this script, and can not give you permission to edit, modify or release it. I am only releasing this on my own because I have helped sushi in the past, and he has been unresponsive and radio silent after his v 1.3 release. I have contacted administrators for Armaholic prior to releasing this, as well, to inform them of my intent. If he shows back up, I fully expect this mod to become defunct and all of the work I've done to be rolled into a new version of his mod.
Sorry for any trouble this may cause future modders who want to edit this script.
Add this entire package to your mission folder in "\Documents\Arma 3 - Other Profiles\(Profile Name)\Missions\(Misison Name)"
If you already have a description.ext, just copy and paste the contents of this description into your existing one
Add a marker over the area you wish to close/lock doors to
Name the marker something using simple naming (no spaces, symbols, etc for simplicity. Uses something like: "LockAllDoors1, "CloseAllDoors", etc)
Save the mission file go into the mission folder as described above, and open up the "sushi_scripts" folder Edit the "breach-settings.cpp" in your favorite editing tool. I prefer Notepad++
Decide which features you want to use "LockFrontDoorsOnly, AllowLockPick, lockall, etc."
Check the "class lockDoor, class zone_1, and change the zone = "doorlockall1" to the marker name you made.
Save, export the mission file to MP, and host a local MP server to test.
If you have doors you want to close, and they are not closing, try changing closefix to 1. ArmA buildings are funny, and this can often work.
Yak's Fix Version 1.0
Initial Release from V1.3 of Sushi's Script
Added multiple CUP Building Doors
Fixed Join in Progress Multiplayer errors
Fixed bug caused by player death (menu items would disappear)
Fixed initial load times when marker covers the entire screen (reduced load times from upwards of 30 minutes to 1-3 minutes)
This will not work in the editor/SP only missions. It depends on a multiplayer environment, and at least a locally hosted MP game to work. Sorry, but unfortunately that's how I was able to fix a lot of the code]
This post was edited by Yakavetta (2016-08-17 20:08, ago)
Sorry for my absence, i was forced to reduce my "arma time" to minimum, and i cant work at arma scripts anymore.
Anyway, Yakavetta, thank you very much for your work, and keeping this script alive. I will update first post and add you to credits.
I can understand having to reduce ArmA time. I'll keep working on it! I've found one more slight bug I'm working on now and will be fixed in the next update. Thanks again for the original, though! I wouldn't be able to create this like you did.
It seems that the script isn't working properly on Takistan - I have not tried it on other maps besides Altis, though (it works on Altis). The script seems to work, but the doors don't close. Using the closeFix option will close the doors, but the script doesn't seem to run after that (no option to check lock and doors don't lock).
The problem was for some reason (I haven't investigated yet why, I'll do that later), the CUP ME buildings were returning the wrong variable. I'd guess somewhere it's reported name is different than their skeleton name in the p3d or something. Either way, it's working now.
edit: there's a bug with the feature to lock only the front doors while door fix=1. I'm looking into it and hope to have an update out soon.
Added 17 hours 52 minutes later:
Fixed the issue where closefix = 1 and closefrontdoorsonly = 1 would cause doors to fail to lock
@DoRo - yes. But be careful because, especially with CUP, some of the buildings will lock properly and some won't unless you change the door fix variable. Basically, half of CUP buildings use one style of variables to open/close doors, while the others reverse it. I know the two main style of buildings that conflict are the Middle East, and Eastern European.
Copyright (c) 2006 - 2020 Armaholic.com All Rights Reserved.
Armed Assault, ArmA: Combat Operations, ArmA: Queen's Gambit, Arma 2, Arma 2: Operation Arrowhead, Arma 2: Combined Operations, Arma 2: British Armed Forces, Arma 2: Private Military Company, Arma 2: Army of the Czech Republic, Arma 2: Reinforcements, Arma 2: Firing Range and Arma 3 are trademarks or registered trademarks of Bohemia Interactive a.s.