Ghost Posted December 10, 2013 Report Share Posted December 10, 2013 I managed to make the Armored SUV turret opens and closes, the only issue is the gunner sticks out of the SUV when the turret is closed. I utilized this thread as a reference http://opendayz.net/threads/armored-suv-gun-animations.14848/ along with this one http://opendayz.net/threads/release-mv22-ramp-door-animations.12520/ and I'm currently trying to see if the lock turret portion of this script can be utilized to finish it or if the turret can be opened automatically when a player enters the gunner seat if closed http://www.armaholic.com/page.php?id=18709 Anyone got any ideas? Crankyfist 1 Link to comment Share on other sites More sharing options...
0 Ghost Posted December 11, 2013 Author Report Share Posted December 11, 2013 Additional Information: Install Instructions 1) Download the attached script and extract in your main mpmission folder. i.e. \MPMissions\DayZ_Epoch_11.Chernarus\ 2) In your mpmission folder open your init.sqf file and find: if (!isDedicated) then { Insert the following line under the _playerMonitor = [] execVM ....... _Armored_SUV_PMC_DZE_turret = [] execVM "Custom\VehicleActions\suvpmc_init.sqf"; Files: suvpmc_init.sqf #include "suvpmc_functions.sqf" { _vcl = _this select 0; //set the vehicle to _vcl _vcl setVariable ["suvpmc_cover", 0, true]; //create a variable for the cover _closeCover = _x addaction ["Close Cover","Custom\VehicleActions\suvpmc_addAction.sqf",[[],suvpmc_closecover],7,true,false,"","player == gunner _target && format [""%1"",_target getVariable ""suvpmc_cover""] != ""1"""]; //add action to close cover, details to come _openCover = _x addaction ["Open Cover","Custom\VehicleActions\suvpmc_addAction.sqf",[[],suvpmc_opencover],7,true,false,"","player == gunner _target && format [""%1"",_target getVariable ""suvpmc_cover""] == ""1"""]; //add action to open cover } foreach (nearestObjects [[3000,3000,0], ["ArmoredSUV_PMC_DZE"], 50000]); //Get all Armored SUV vehicles in map suvpmc_addAction.sqf _array = _this select 3; _param = _array select 0; _code = _array select 1; _spawn = _param spawn _code; suvpmc_functions.sqf suvpmc_closecover = //function to close Cover { _vcl = vehicle player; //assign the vehicle the pilot is in to _vcl _vcl animate ["HideGun_01",1]; //fold gun down _vcl animate ["HideGun_02",1]; //fold gun down _vcl animate ["HideGun_03",1]; //fold gun down _vcl animate ["HideGun_04",1]; //fold gun down _vcl animate ["CloseCover1",1]; //close cover1 _vcl animate ["CloseCover2",1]; //close cover2 _vcl setVariable ["suvpmc_cover", 1, true]; //set it closed WaitUntil {!Alive _veh || format ["%1",_veh getVariable "suvpmc_cover"] != "1"}; //if suvpmc_cover is 0 or it is destroyed, continue with the script _veh setVariable ["suvpmc_cover", 0,true]; //set suvpmc_cover to 0, not needed, haven't tested if it's needed }; suvpmc_opencover = //function to open cover { _vcl = vehicle player; //assign the vehicle the pilot is in to _vcl _vcl animate ["HideGun_01",0]; //fold gun down _vcl animate ["HideGun_02",0]; //fold gun down _vcl animate ["HideGun_03",0]; //fold gun down _vcl animate ["HideGun_04",0]; //fold gun down _vcl animate ["CloseCover1",0]; //close cover1 _vcl animate ["CloseCover2",0]; //close cover2 _vcl setVariable ["suvpmc_cover", 0,true]; //set it opened }; Included 2 versions one for DZE and one for DZ Vehicles Armored SUV DZ Turret Script.zipArmored SUV DZE Turret Script.zip Rythron and Snobby 2 Link to comment Share on other sites More sharing options...
0 Three Plus Posted December 12, 2013 Report Share Posted December 12, 2013 Added this to my server and It unfortunately did not work. Link to comment Share on other sites More sharing options...
0 Ghost Posted December 12, 2013 Author Report Share Posted December 12, 2013 I can confirm it works 100% were you in the gunner seat of the SUV and also in the suvpmc_init.sqf change this line } foreach (nearestObjects [[3000,3000,0], ["ArmoredSUV_PMC_DZ"], 50000]); //Get all Armored SUV vehicles in map for } foreach (nearestObjects [[3000,3000,0], ["ArmoredSUV_PMC_DZE"], 50000]); //Get all Armored SUV vehicles in map if you are using DZE Vehicles Link to comment Share on other sites More sharing options...
0 Three Plus Posted December 12, 2013 Report Share Posted December 12, 2013 I can confirm it works 100% were you in the gunner seat of the SUV and also in the suvpmc_init.sqf change this line } foreach (nearestObjects [[3000,3000,0], ["ArmoredSUV_PMC_DZ"], 50000]); //Get all Armored SUV vehicles in map for } foreach (nearestObjects [[3000,3000,0], ["ArmoredSUV_PMC_DZE"], 50000]); //Get all Armored SUV vehicles in map if you are using DZE Vehicles Works now thanks, But it looks rather funny because the player is still sticking out. Great Script! Link to comment Share on other sites More sharing options...
0 Ghost Posted December 12, 2013 Author Report Share Posted December 12, 2013 Yeah still working on the gunner getting moved out to the passenger seat to avoid him sticking out lol then we would probably have to make it so when a player enters the gunner seat the turret comes up Link to comment Share on other sites More sharing options...
0 Nemiuk Posted February 19, 2014 Report Share Posted February 19, 2014 Hi, did you get the switch seat working for the gunner?. Regards Link to comment Share on other sites More sharing options...
0 Ghost Posted February 25, 2014 Author Report Share Posted February 25, 2014 nope no luck Link to comment Share on other sites More sharing options...
0 Nemiuk Posted February 25, 2014 Report Share Posted February 25, 2014 I found this in another script it may help, i got the hatch to close and the person goes to the rear passenger seat. (gunner _vcl) action ["moveToCargo", _vcl,1]; Regards p.s I will post the full script when i have time later today. Link to comment Share on other sites More sharing options...
0 Nemiuk Posted February 26, 2014 Report Share Posted February 26, 2014 Hiya this is where i found that script, just looked through the files to find the part that puts you in the car then copy pasted into your script a few times until i worked out where it should be. Not got the reverse action working yet i.e car to turret. http://www.armaholic.com/page.php?id=18709 Regards Link to comment Share on other sites More sharing options...
0 Ghost Posted February 28, 2014 Author Report Share Posted February 28, 2014 Sweet, if possible could you show me where in the script did you place (gunner _vcl) action ["moveToCargo", _vcl,1]; ? Link to comment Share on other sites More sharing options...
0 Nemiuk Posted February 28, 2014 Report Share Posted February 28, 2014 Sure its on the first part of the suvpmc_functions.sqf, suvpmc_closecover = //function to close Cover { _vcl = vehicle player; //assign the vehicle the pilot is in to _vcl (gunner _vcl) action ["moveToCargo", _vcl,1]; <----------------------(Here) _vcl animate ["HideGun_01",1]; //fold gun down _vcl animate ["HideGun_02",1]; //fold gun down _vcl animate ["HideGun_03",1]; //fold gun down _vcl animate ["HideGun_04",1]; //fold gun down _vcl animate ["CloseCover1",1]; //close cover1 _vcl animate ["CloseCover2",1]; //close cover2 _vcl setVariable ["suvpmc_cover", 1, true]; //set it closed WaitUntil {!Alive _veh || format ["%1",_veh getVariable "suvpmc_cover"] != "1"}; //if suvpmc_cover is 0 or it is destroyed, continue with the script _veh setVariable ["suvpmc_cover", 0,true]; //set suvpmc_cover to 0, not needed, haven't tested if it's needed }; Regards p.s I think (gunner _vcl) action ["moveToCargo", _vcl,1]; was called (gunner_car) in the other script. Link to comment Share on other sites More sharing options...
0 Ghost Posted March 2, 2014 Author Report Share Posted March 2, 2014 Yeah thanks, it works. I've been messing with the open turret script moving you to the gunner seat without luck... Link to comment Share on other sites More sharing options...
0 LoadingSA Posted March 2, 2014 Report Share Posted March 2, 2014 Can you post a "How To" in the server mods forum for how to get all of this working? It looks like it's working now so might as well share the completed work. I'm not able to get the option to turn the gun down when I messed with this. Link to comment Share on other sites More sharing options...
0 Asian Kid Posted March 2, 2014 Report Share Posted March 2, 2014 Make the option for open for on back seat people Link to comment Share on other sites More sharing options...
0 Nemiuk Posted March 3, 2014 Report Share Posted March 3, 2014 I will have a look at my files but i think i just used Ghosts 2nd post to get it working, just need to add the bit I found to get into the back seat. And yeah I have not got the opposite way from back seat to gun working yet either. Link to comment Share on other sites More sharing options...
0 shaundibble69 Posted March 7, 2014 Report Share Posted March 7, 2014 I cant seem to get this working on 1.0.4.2 would it be possible to put a complete guide, I have got nearly all other scripts going, just cant get this one going. Thank you in advance for any assistance Link to comment Share on other sites More sharing options...
0 Ghost Posted March 7, 2014 Author Report Share Posted March 7, 2014 Nemiuk you got all my permission to post this script. I'm currently working on a Private Community Epoch Mod and have no time for other stuff. Link to comment Share on other sites More sharing options...
0 shaundibble69 Posted March 14, 2014 Report Share Posted March 14, 2014 :( Link to comment Share on other sites More sharing options...
0 ConArts Posted March 16, 2014 Report Share Posted March 16, 2014 Any progress on this script ?? Link to comment Share on other sites More sharing options...
0 chucky_xxl Posted March 16, 2014 Report Share Posted March 16, 2014 can anywhere upload this Armored SUV DZE Turret Script.zip thx alot Link to comment Share on other sites More sharing options...
0 haggis Posted March 27, 2014 Report Share Posted March 27, 2014 Anyone have this working with 1.0.4.2? Link to comment Share on other sites More sharing options...
0 Asian Kid Posted March 27, 2014 Report Share Posted March 27, 2014 Anyone have this working with 1.0.4.2? works fine Link to comment Share on other sites More sharing options...
0 haggis Posted March 27, 2014 Report Share Posted March 27, 2014 Thank for taking the time to reply Asian Kid. Cant seem to see why it will not work for me. Located in my "custom folder" https://www.dropbox.com/sh/es1rhjzqhryjj8r/9TbXUjZg2S dayz_epoch_13.Tavi\init.sqf //Run the player monitor _id = player addEventHandler ["Respawn", {_id = [] spawn player_death;}]; _playerMonitor = [] execVM "\z\addons\dayz_code\system\player_monitor.sqf"; _Armored_SUV_PMC_DZE_turret = [] execVM "custom\VehicleActions\suvpmc_init.sqf"; Am trying on the right type of DZE SUV Anyone mind taking a look to see if there is an issue? Link to comment Share on other sites More sharing options...
0 haggis Posted March 27, 2014 Report Share Posted March 27, 2014 OK seems all to work now very strange. Link to comment Share on other sites More sharing options...
0 Asian Kid Posted March 27, 2014 Report Share Posted March 27, 2014 OK seems all to work now very strange. If you spawn a SUV it will not work until you relog Link to comment Share on other sites More sharing options...
Question
Ghost
I managed to make the Armored SUV turret opens and closes, the only issue is the gunner sticks out of the SUV when the turret is closed.
I utilized this thread as a reference
http://opendayz.net/threads/armored-suv-gun-animations.14848/
along with this one
http://opendayz.net/threads/release-mv22-ramp-door-animations.12520/
and I'm currently trying to see if the lock turret portion of this script can be utilized to finish it or if the turret can be opened automatically when a player enters the gunner seat if closed
http://www.armaholic.com/page.php?id=18709
Anyone got any ideas?
Link to comment
Share on other sites
38 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now