-
Notifications
You must be signed in to change notification settings - Fork 2
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improve Compatibility of Advanced Slingloading script with CUP Helicopters #5
Comments
String comparison ignores case unless using arrays with in / find alt syntax
|
I've created a issue for the Mi-6T and A on their github. http://dev.cup-arma3.org/T1399 |
I'v eupdated the Slingloading script to the newest version from upstream. Seems like a lot of things have been updated and changed. I'm currently taking a look at the script and look for potential places for improvement. So far, I've found the following code block(s), which I'd like to refactor: ASL_Add_Player_Actions = {
player addAction ["Extend Cargo Ropes", {
[] call ASL_Extend_Ropes_Action;
}, nil, 0, false, true, "", "call ASL_Extend_Ropes_Action_Check"];
player addAction ["Shorten Cargo Ropes", {
[] call ASL_Shorten_Ropes_Action;
}, nil, 0, false, true, "", "call ASL_Shorten_Ropes_Action_Check"];
player addAction ["Release Cargo", {
[] call ASL_Release_Cargo_Action;
}, nil, 0, false, true, "", "call ASL_Release_Cargo_Action_Check"];
player addAction ["Retract Cargo Ropes", {
[] call ASL_Retract_Ropes_Action;
}, nil, 0, false, true, "", "call ASL_Retract_Ropes_Action_Check"];
player addAction ["Deploy Cargo Ropes", {
[] call ASL_Deploy_Ropes_Action;
}, nil, 0, false, true, "", "call ASL_Deploy_Ropes_Action_Check"];
player addAction ["Put Away Cargo Ropes", {
[] call ASL_Put_Away_Ropes_Action;
}, nil, 0, false, true, "", "call ASL_Put_Away_Ropes_Action_Check"];
player addAction ["Attach To Cargo Ropes", {
[] call ASL_Attach_Ropes_Action;
}, nil, 0, false, true, "", "call ASL_Attach_Ropes_Action_Check"];
player addAction ["Drop Cargo Ropes", {
[] call ASL_Drop_Ropes_Action;
}, nil, 0, false, true, "", "call ASL_Drop_Ropes_Action_Check"];
player addAction ["Pickup Cargo Ropes", {
[] call ASL_Pickup_Ropes_Action;
}, nil, 0, false, true, "", "call ASL_Pickup_Ropes_Action_Check"];
player addEventHandler ["Respawn", {
player setVariable ["ASL_Actions_Loaded",false];
}];
};
if(!isDedicated) then {
[] spawn {
while {true} do {
if(!isNull player && isPlayer player) then {
if!( player getVariable ["ASL_Actions_Loaded",false] ) then {
[] call ASL_Add_Player_Actions;
player setVariable ["ASL_Actions_Loaded",true];
};
};
missionNamespace setVariable ["ASL_Nearby_Vehicles", (call ASL_Find_Nearby_Vehicles)];
sleep 2;
};
};
}; That while{true} loop needs to go. There's no reason to have this. I also want to replace the AddActions with ACE Actions. these are JIP Safe and also work when you are using Zeus to remote-control an AI. |
Uses ACE Interactions now, and removed that terrible while loop. ASL_Find_Nearby_Vehicles now only gets called when opening the ACE Menu, instead of every 2 seconds for the whole game. And the 9 Check functions now only get called once when opening the ACE Menu, as opposed to every frame. |
Affected Script: comfy-downtime/src/FP_ComfyDowntime.VR/scripts/fn_advancedSlingLoadingInit.sqf
The Advanced Slingloading Script offers slingloading for every helicopter to slingload and every vehicle to be slingloaded.
However it can benefit from a few things.
The Current solution is to wiggle the helicopter left and right so the ropes fall trough the floor thanks to Arma's realistic simulation of physics.
The text was updated successfully, but these errors were encountered: