computermancer Posted February 20, 2015 Report Share Posted February 20, 2015 I have a request. I have an animation script where my guy uses his walkie talkie. Is there a way for a player to have a chance of triggering a supply drop within a certain distance? Great script BTW :wub: Link to comment Share on other sites More sharing options...
tdavison Posted February 20, 2015 Author Report Share Posted February 20, 2015 I have a request. I have an animation script where my guy uses his walkie talkie. Is there a way for a player to have a chance of triggering a supply drop within a certain distance? Great script BTW :wub: I wouldn't know how to do this - haven't seen any animations for using radio... are you attempting to do this client-side or server-side? (the add-on was meant for server-side). If you have code that triggers the animation, I am sure you could find a way to make it work within that framework (like not call the script from initServer, rather call it from the radio animation). Link to comment Share on other sites More sharing options...
computermancer Posted February 20, 2015 Report Share Posted February 20, 2015 I wouldn't know how to do this - haven't seen any animations for using radio... are you attempting to do this client-side or server-side? (the add-on was meant for server-side). If you have code that triggers the animation, I am sure you could find a way to make it work within that framework (like not call the script from initServer, rather call it from the radio animation). If you go into editor, click preview, then press escape and click ANIMATIONS, you can see a wide variety of animations and loops. My questions is batter asked this way... Is there a function or execVM a player can call to trigger the helicopter script? Link to comment Share on other sites More sharing options...
tdavison Posted February 20, 2015 Author Report Share Posted February 20, 2015 If you go into editor, click preview, then press escape and click ANIMATIONS, you can see a wide variety of animations and loops. My questions is batter asked this way... Is there a function or execVM a player can call to trigger the helicopter script? I honestly don't know if a script can be triggered by a player using a radio - I'm pretty sure that animation is driven on the client-side of things. Very sorry. Link to comment Share on other sites More sharing options...
KiloSwiss Posted February 21, 2015 Report Share Posted February 21, 2015 Just a little heads up:Let BIS_fnc_findSafePos search in a 8000m radius by the server is insane and will produce a heavy delay on other scripts and probably many yellow chains on well populated servers!Keep a look into my fn_findMissionPos.sqf to see how I create a random position on the Map and then use BIS_fnc_findSafePos in a much lower radius, to search a valid position.You are free to adapt this script (or take parts out of it) and use it for your supply drop mission.But keep in mind that my fn_findMissionPos script is dependent on the results/calculations, made by the fn_getWorldData.sqf, which dynamically creates a center and a maximum search radius for every map.Greez KiloSwiss cyncrwler and KingRaymond795 2 Link to comment Share on other sites More sharing options...
Lost_Noob Posted February 21, 2015 Report Share Posted February 21, 2015 I can confirm Kilo's above comment. We have installed the Airdrops and noticed 20+ players on the serer you get the notification that a chopper has been seen. Then when it drops its load notification comes up server wide yellow chain and some FPS drop. Also noticed the following: Mohawk x 3 hover above 3 locations - West, South & East. Just sit there, shoot them down another appears - Player base freaks out and starts shooting or complain. After a few drops the notification happens as normal then no marker and no box. Check the logs to find that 4 x boxes are reported as being dropped, check admin markers and found 4 parachutes - no boxes. The missions then cease to work until server restart. Link to comment Share on other sites More sharing options...
tdavison Posted February 21, 2015 Author Report Share Posted February 21, 2015 Thanks KiloSwiss and Lost_Noob - I'll look into the code today and try to clean it up a bit. I test on a relatively low-pop server which is why I haven't encountered those issues. Link to comment Share on other sites More sharing options...
tdavison Posted February 21, 2015 Author Report Share Posted February 21, 2015 Just a little heads up: Let BIS_fnc_findSafePos search in a 8000m radius by the server is insane and will produce a heavy delay on other scripts and probably many yellow chains on well populated servers! Keep a look into my fn_findMissionPos.sqf to see how I create a random position on the Map and then use BIS_fnc_findSafePos in a much lower radius, to search a valid position. You are free to adapt this script (or take parts out of it) and use it for your supply drop mission. But keep in mind that my fn_findMissionPos script is dependent on the results/calculations, made by the fn_getWorldData.sqf, which dynamically creates a center and a maximum search radius for every map. Greez KiloSwiss KiloSwiss: Do you happen to have any references or pages that reference performance issues with BIS_fnc_findSafePos? From what I can tell, it simply returns a coordinate that meets the parameters set in the array. According to Lost_Noob - he gets the yellow link when the helicopter drops the crate, which makes no sense at all to me - because BIS_fnc_findSafePos was called way prior to that... the helicopter is simply dropping the crate and attaching to a parachute. I will add deleteVehicle _chute; after the crate has landed. Ahh - this is most likely the issue causing the yellow link: while {(getPosATL _crate) select 2 > _chuteMinDistanceToOpen} do { sleep 0.2; }; I'll have to find a better way to handle that one... but will most likely just remove the _chutMinDistanceToOpen variable. Which really means the parachute will most likely fall outside the LZ. computermancer 1 Link to comment Share on other sites More sharing options...
RNKot Posted February 21, 2015 Report Share Posted February 21, 2015 Sorry do not understand a thing for installation this. Installation: Extract it to your Desktop or somewhere where you won't lose it. Inside the Zip is this Readme.MD, and the folder "SupplyDrop-1.0". Inside you will find SDROP.pbo and the "SDrop" folder with mission and script files. 1. Edit your epoch.Altis initServer.sqf (or add one) Paste in the following line (or add to existing IF SERVER condition): if (isServer) then { [] ExecVM "\SDROP\init.sqf"; }; 2. Edit your epoch.Altis init.sqf (or add one) Paste in the following - this is used for sending messages to all players: //Supply Drop Alert Event "SDROP_Alert" addPublicVariableEventHandler { hint parseText format["%1", _this select 1]; }; Should I add this strings to init.sqf in epoch.Altis.pbo in \MPMissions on server or what? Link to comment Share on other sites More sharing options...
Moody Posted February 21, 2015 Report Share Posted February 21, 2015 Im experiencing that when the crate is looted, the marker doesnt dissapear and new mission arent spawning. Anyone experienced the same? What fixed the problem? Thank you! Link to comment Share on other sites More sharing options...
tdavison Posted February 21, 2015 Author Report Share Posted February 21, 2015 Sorry do not understand a thing for installation this. Installation: Extract it to your Desktop or somewhere where you won't lose it. Inside the Zip is this Readme.MD, and the folder "SupplyDrop-1.0". Inside you will find SDROP.pbo and the "SDrop" folder with mission and script files. 1. Edit your epoch.Altis initServer.sqf (or add one) Paste in the following line (or add to existing IF SERVER condition): if (isServer) then { [] ExecVM "\SDROP\init.sqf"; }; 2. Edit your epoch.Altis init.sqf (or add one) Paste in the following - this is used for sending messages to all players: //Supply Drop Alert Event "SDROP_Alert" addPublicVariableEventHandler { hint parseText format["%1", _this select 1]; }; Should I add this strings to init.sqf in epoch.Altis.pbo in \MPMissions on server or what? You should be able to put that in your epoch.Altis.pbo (unpacked) init.sqf Link to comment Share on other sites More sharing options...
RNKot Posted February 21, 2015 Report Share Posted February 21, 2015 You should be able to put that in your epoch.Altis.pbo (unpacked) init.sqf Is that really big (about 1000*1000m) purple radius on map is this mission? Link to comment Share on other sites More sharing options...
tdavison Posted February 21, 2015 Author Report Share Posted February 21, 2015 Is that really big (about 1000*1000m) purple radius on map is this mission? The marker is 500 meters x 500 meters - you can change it, but the crate might not be within a smaller radius. I'll be doing a hotfix for this in just a little while. The hotfix includes some performance issues as well as putting the marker where the crate is (with a slight offset). After the hotifx, you can change the radius to be smaller - but I'd suggest at least 300 meter radius, unless you want to use the exact position marker. computermancer 1 Link to comment Share on other sites More sharing options...
Metalfoundry Posted February 21, 2015 Report Share Posted February 21, 2015 how can I start this script only, if >10 Players are on the server? Link to comment Share on other sites More sharing options...
RNKot Posted February 21, 2015 Report Share Posted February 21, 2015 Than it's working. Thankls for the mission! Just started playing with Arma and still a bit confused with it's scripts. Link to comment Share on other sites More sharing options...
computermancer Posted February 21, 2015 Report Share Posted February 21, 2015 In your altitude check for the crate, instead of a sleep loop, maybe try a waitUntil loop with a setVariable on the crate and its target on the ground ? Link to comment Share on other sites More sharing options...
tdavison Posted February 21, 2015 Author Report Share Posted February 21, 2015 how can I start this script only, if >10 Players are on the server? I haven't tested this, but I think you can do something like: if (isServer) then { if (count playableUnits > 10) then { //call mission [] ExecVM "\SDROP\init.sqf"; }; }; Again, not tested. Sorry if any errors - you also want to make sure any other "isServer" calls are not in the IF condition to check players. computermancer 1 Link to comment Share on other sites More sharing options...
BetterDeadThanZed Posted February 21, 2015 Report Share Posted February 21, 2015 What makes you think you need 10 players for this to start? Link to comment Share on other sites More sharing options...
computermancer Posted February 21, 2015 Report Share Posted February 21, 2015 What makes you think you need 10 players for this to start? I believe he wants to make the script unable to run UNLESS there are 10 or more player? Link to comment Share on other sites More sharing options...
tdavison Posted February 22, 2015 Author Report Share Posted February 22, 2015 Version 1.0b has been released on my github page: https://github.com/tdavison70/Helicopter-Supply-Drop/releases This should fix helicopters that cannot find a safe position from hovering aimlessly. Some other performance-related fixes (using logic for drop height) were made, which should fix any yellow link icons from happening. Thanks again for all of your testing & suggestions. Hopefully this add-on will run better than before. Incsy, computermancer and unrealPANDA 3 Link to comment Share on other sites More sharing options...
Guest Posted February 22, 2015 Report Share Posted February 22, 2015 Version 1.0b has been released on my github page: https://github.com/tdavison70/Helicopter-Supply-Drop/releases This should fix helicopters that cannot find a safe position from hovering aimlessly. Some other performance-related fixes (using logic for drop height) were made, which should fix any yellow link icons from happening. Thanks again for all of your testing & suggestions. Hopefully this add-on will run better than before. Great work man! Link to comment Share on other sites More sharing options...
BetterDeadThanZed Posted February 22, 2015 Report Share Posted February 22, 2015 I honestly don't know if a script can be triggered by a player using a radio - I'm pretty sure that animation is driven on the client-side of things. Very sorry. Here's a script where the guy has player using a radio animation and he says in his video that he will soon have that cause an action: Maybe he can help you with that if it's something you want to use. computermancer and unrealPANDA 2 Link to comment Share on other sites More sharing options...
computermancer Posted February 22, 2015 Report Share Posted February 22, 2015 Here's a script where the guy has player using a radio animation and he says in his video that he will soon have that cause an action: Maybe he can help you with that if it's something you want to use. LMAO! That's a nice script :ph34r: (that's my script... i just need a good execVM to call with it) Link to comment Share on other sites More sharing options...
Salutesh Posted February 22, 2015 Report Share Posted February 22, 2015 OMG! After seeing this Post i feel like an idiot with my release... :ph34r: Will test this out! ;) Link to comment Share on other sites More sharing options...
BetterDeadThanZed Posted February 22, 2015 Report Share Posted February 22, 2015 I updated to the newest version and on my test server, I had vehicle markers enabled so I could see where the heli came from and TWO helicopters entered the map when the supply drop was triggered. computermancer 1 Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now