mirror of
https://github.com/Bjanski/ExAd.git
synced 2024-08-30 16:52:14 +00:00
added new features
safe mode and detach parachute
This commit is contained in:
parent
a882a05a37
commit
bc793e7854
@ -20,7 +20,9 @@
|
||||
class HaloParachute
|
||||
{
|
||||
file = "ExAdClient\HaloParachute\Functions";
|
||||
class detachParachute {};
|
||||
class ejectPlayer {};
|
||||
class parachutesafemode {};
|
||||
class pullParachute {};
|
||||
class showEject {};
|
||||
class showParachute {};
|
||||
|
@ -0,0 +1,21 @@
|
||||
/*
|
||||
fn_detachParachute.sqf
|
||||
|
||||
Copyright 2016 Jan Babor
|
||||
|
||||
Licensed under the Apache License, Version 2.0 (the "License");
|
||||
you may not use this file except in compliance with the License.
|
||||
You may obtain a copy of the License at
|
||||
|
||||
http://www.apache.org/licenses/LICENSE-2.0
|
||||
|
||||
Unless required by applicable law or agreed to in writing, software
|
||||
distributed under the License is distributed on an "AS IS" BASIS,
|
||||
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||
See the License for the specific language governing permissions and
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
hint "Detach parachute";
|
||||
|
||||
true
|
@ -16,6 +16,6 @@
|
||||
limitations under the License.
|
||||
*/
|
||||
|
||||
if(getPosATL player <= ExAd_ACTION_PARACHUTE_HEIGHT)then{
|
||||
if((getPosATL player) select 2 <= ExAd_ACTION_PARACHUTE_HEIGHT)then{
|
||||
call ExAd_fnc_pullParachute;
|
||||
};
|
@ -17,6 +17,7 @@
|
||||
*/
|
||||
|
||||
ExAd_HALOPARACHUTE_SAFE_MODE = false; //BOOLEAN - Force pull parachute when player reaches ExAd_ACTION_PARACHUTE_HEIGHT if they ejected from vehicle
|
||||
ExAd_HALOPARACHUTE_DETACH_PARACHUTE_MODE = false; //BOOLEAN - Allows player to detach himself from parachute
|
||||
|
||||
ExAd_ACTION_PARACHUTE_HEIGHT = 10; //SCALAR - What is the minimum altitude a player can pull a parachute.
|
||||
ExAd_ACTION_PARACHUTE_HEIGHT = 10; //SCALAR - What is the minimum altitude a player can pull a parachute. |RECOMMENDED 30 meters when safe_mode activated
|
||||
ExAd_ACTION_EJECT_HEIGHT = 100; //SCALAR - What is the minimum altitude a player can Halo/Eject from a vehicle.
|
@ -27,11 +27,19 @@ execVM "ExAdClient\HaloParachute\customize.sqf";
|
||||
UISleep 0.1;
|
||||
waitUntil{alive player};
|
||||
|
||||
ExAd_ACTION_PARACHUTE = player addaction ["<t color='#E48A36'><img image='\a3\ui_f\data\gui\cfg\CommunicationMenu\supplydrop_ca.paa' /> Open Parachute!</t>", "call ExAd_fnc_pullParachute", [], 6, true, true, "", "call ExAd_fnc_showParachute"];
|
||||
ExAd_ACTION_EJECT = player addaction ["<t color='#E48A36'><img image='\a3\ui_f\data\gui\cfg\CommunicationMenu\supplydrop_ca.paa' /> Halo Jump</t>", "call ExAd_fnc_ejectPlayer", [], 6, false, true, "", "call ExAd_fnc_showEject;"];
|
||||
ExAd_ACTION_PARACHUTE = player addaction [format["<t color='#E48A36'><img image='\a3\ui_f\data\gui\cfg\CommunicationMenu\supplydrop_ca.paa' />%1</t>", localize "STR_ExAd_HALOPARACHUTE_ACTIONS_PARACHUTE"], {call ExAd_fnc_pullParachute}, [], 6, true, true, "", "call ExAd_fnc_showParachute"];
|
||||
ExAd_ACTION_EJECT = player addaction [format["<t color='#E48A36'><img image='\a3\ui_f\data\gui\cfg\CommunicationMenu\supplydrop_ca.paa' />%1</t>", localize "STR_ExAd_HALOPARACHUTE_ACTIONS_HALO"], {call ExAd_fnc_ejectPlayer}, [], 6, false, true, "", "call ExAd_fnc_showEject;"];
|
||||
|
||||
if(ExAd_HALOPARACHUTE_DETACH_PARACHUTE_MODE)then{
|
||||
ExAd_ACTION_PARACHUTE_DETACH = player addaction [format["<t color='#E48A36'><img image='\a3\ui_f\data\gui\cfg\CommunicationMenu\supplydrop_ca.paa' />%1</t>", localize "STR_ExAd_HALOPARACHUTE_ACTIONS_DETACH"], {call ExAd_fnc_detachParachute}, [], 6, true, true, "", "call ExAd_fnc_showParachute"];
|
||||
};
|
||||
|
||||
waitUntil{!alive player};
|
||||
player removeAction ExAd_ACTION_PARACHUTE;
|
||||
player removeAction ExAd_ACTION_EJECT;
|
||||
}
|
||||
|
||||
if(ExAd_HALOPARACHUTE_DETACH_PARACHUTE_MODE)then{
|
||||
player removeAction ExAd_ACTION_PARACHUTE_DETACH;
|
||||
};
|
||||
};
|
||||
};
|
@ -8,6 +8,9 @@
|
||||
<Key ID="STR_ExAd_HALOPARACHUTE_ACTIONS_PARACHUTE">
|
||||
<Original>Open Parachute</Original>
|
||||
</Key>
|
||||
<Key ID="STR_ExAd_HALOPARACHUTE_ACTIONS_DETACH">
|
||||
<Original>Open Parachute</Original>
|
||||
</Key>
|
||||
</Container>
|
||||
</Package>
|
||||
</Project>
|
||||
|
Loading…
Reference in New Issue
Block a user