From 628d33984d9228f1781d13a65fbb80f35facc899 Mon Sep 17 00:00:00 2001 From: hybrid Date: Thu, 11 Jun 2026 19:55:24 +0300 Subject: init --- Client/Action/Action_Build.sqf | 1 + Client/Action/Action_BuildRepair.sqf | 1 + Client/Action/Action_EjectCargo.sqf | 23 +++++++++++++++++++++++ Client/Action/Action_HALO.sqf | 9 +++++++++ Client/Action/Action_Menu.sqf | 1 + Client/Action/Action_Push.sqf | 8 ++++++++ Client/Action/Action_RepairMHQ.sqf | 29 +++++++++++++++++++++++++++++ Client/Action/Action_TaxiReverse.sqf | 8 ++++++++ Client/Action/Action_ToggleLock.sqf | 7 +++++++ Client/Action/Action_ToggleMHQLock.sqf | 9 +++++++++ 10 files changed, 96 insertions(+) create mode 100644 Client/Action/Action_Build.sqf create mode 100644 Client/Action/Action_BuildRepair.sqf create mode 100644 Client/Action/Action_EjectCargo.sqf create mode 100644 Client/Action/Action_HALO.sqf create mode 100644 Client/Action/Action_Menu.sqf create mode 100644 Client/Action/Action_Push.sqf create mode 100644 Client/Action/Action_RepairMHQ.sqf create mode 100644 Client/Action/Action_TaxiReverse.sqf create mode 100644 Client/Action/Action_ToggleLock.sqf create mode 100644 Client/Action/Action_ToggleMHQLock.sqf (limited to 'Client/Action') diff --git a/Client/Action/Action_Build.sqf b/Client/Action/Action_Build.sqf new file mode 100644 index 0000000..e61bb1a --- /dev/null +++ b/Client/Action/Action_Build.sqf @@ -0,0 +1 @@ +[player,player,2,MCoin,getpos player,(sideJoined) Call GetSideHQ] ExecVM "Client\Module\CoIn\coin_interface.sqf"; \ No newline at end of file diff --git a/Client/Action/Action_BuildRepair.sqf b/Client/Action/Action_BuildRepair.sqf new file mode 100644 index 0000000..3437303 --- /dev/null +++ b/Client/Action/Action_BuildRepair.sqf @@ -0,0 +1 @@ +[player,player,2,RCoin,getpos player,_this select 0] ExecVM "Client\Module\CoIn\coin_interface.sqf"; \ No newline at end of file diff --git a/Client/Action/Action_EjectCargo.sqf b/Client/Action/Action_EjectCargo.sqf new file mode 100644 index 0000000..a10bfd1 --- /dev/null +++ b/Client/Action/Action_EjectCargo.sqf @@ -0,0 +1,23 @@ +Private ["_cargo","_vehicle"]; + +_vehicle = _this select 0; + +//--- Get the crew. +_cargo = (crew _vehicle) - [driver _vehicle, gunner _vehicle, commander _vehicle]; + +{ + if (alive _x && _vehicle == vehicle _x) then { + if (local _x) then { + //--- Dealing with a local unit, probably an AI. + unassignVehicle _x; + _x action ["EJECT", _vehicle]; + } else { + //--- Dealing with a player or a non local unit. + if (isPlayer(leader (group _x))) then { + WFBE_PerformAction = [vehicleVarName(leader(group _x)),'CLTFNCPERFORMACTION',[_x, "EJECT", _vehicle]]; + publicVariable 'WFBE_PerformAction'; + }; + }; + }; + sleep 1; +} forEach _cargo; \ No newline at end of file diff --git a/Client/Action/Action_HALO.sqf b/Client/Action/Action_HALO.sqf new file mode 100644 index 0000000..57aacf9 --- /dev/null +++ b/Client/Action/Action_HALO.sqf @@ -0,0 +1,9 @@ +Private ["_act","_caller","_vehicle"]; + +_vehicle = _this select 0; +_caller = _this select 1; +_act = _this select 2; + +_caller action ["EJECT",_vehicle]; +_caller setVelocity [0,0,0]; +[_caller] Exec "ca\air2\Halo\data\Scripts\HALO_getout.sqs"; \ No newline at end of file diff --git a/Client/Action/Action_Menu.sqf b/Client/Action/Action_Menu.sqf new file mode 100644 index 0000000..acb0e60 --- /dev/null +++ b/Client/Action/Action_Menu.sqf @@ -0,0 +1 @@ +createDialog "WF_Menu"; \ No newline at end of file diff --git a/Client/Action/Action_Push.sqf b/Client/Action/Action_Push.sqf new file mode 100644 index 0000000..8d2429c --- /dev/null +++ b/Client/Action/Action_Push.sqf @@ -0,0 +1,8 @@ +Private ["_dir","_speed","_vehicle","_vel"]; + +_vehicle = _this select 0; + +_vel = velocity _vehicle; +_dir = direction _vehicle; +_speed = 10; +_vehicle setVelocity [(_vel select 0)+((sin _dir)*_speed),(_vel select 1)+((cos _dir)*_speed),(_vel select 2)]; \ No newline at end of file diff --git a/Client/Action/Action_RepairMHQ.sqf b/Client/Action/Action_RepairMHQ.sqf new file mode 100644 index 0000000..4a7eddc --- /dev/null +++ b/Client/Action/Action_RepairMHQ.sqf @@ -0,0 +1,29 @@ +Private ["_currency","_currencySym","_hq","_isBeingFixed","_repairPrice","_vehicle"]; + +_vehicle = _this select 0; + +_hq = (sideJoinedText) Call GetSideHQ; +if (alive _hq || (_hq distance _vehicle > 30)) exitWith {hint (localize "STR_WF_INFO_Repair_MHQ_None")}; + +//--- Is HQ already being fixed? +_isBeingFixed = WF_Logic getVariable Format ["%1MHQRepair",sideJoinedText]; +if (_isBeingFixed) exitWith {hint (localize "STR_WF_INFO_Repair_MHQ_BeingRepaired")}; + +_repairPrice = 'WFBE_MHQREPAIRPRICE' Call GetNamespace; +_currency = if !(paramMoneyOnly) then {(sideJoined) Call GetSideSupply} else {Call GetPlayerFunds}; +_currencySym = if !(paramMoneyOnly) then {"S"} else {"$"}; +if (_currency < _repairPrice) exitWith {hint Format [localize "STR_WF_INFO_Repair_MHQ_Funds",_currencySym,_repairPrice - _currency]}; + +if !(paramMoneyOnly) then { + [sideJoined,-_repairPrice] Call ChangeSideSupply; +} else { + -(_repairPrice) Call ChangePlayerFunds; +}; + +WFBE_RequestMHQRepair = ['SRVFNCREQUESTMHQREPAIR',sideJoined]; +publicVariable 'WFBE_RequestMHQRepair'; +if (isHostedServer) then {['SRVFNCREQUESTMHQREPAIR',sideJoined] Spawn HandleSPVF}; + +WF_Logic setVariable [Format ["%1MHQRepair",sideJoinedText],true,true]; + +hint (localize "STR_WF_INFO_Repair_MHQ_Repair"); \ No newline at end of file diff --git a/Client/Action/Action_TaxiReverse.sqf b/Client/Action/Action_TaxiReverse.sqf new file mode 100644 index 0000000..6b1b8b5 --- /dev/null +++ b/Client/Action/Action_TaxiReverse.sqf @@ -0,0 +1,8 @@ +Private ["_dir","_speed","_vehicle","_vel"]; + +_vehicle = _this select 0; + +_vel = velocity _vehicle; +_dir = direction _vehicle; +_speed = -5; +_vehicle setVelocity [(_vel select 0)+((sin _dir)*_speed),(_vel select 1)+((cos _dir)*_speed),(_vel select 2)]; \ No newline at end of file diff --git a/Client/Action/Action_ToggleLock.sqf b/Client/Action/Action_ToggleLock.sqf new file mode 100644 index 0000000..e0a5add --- /dev/null +++ b/Client/Action/Action_ToggleLock.sqf @@ -0,0 +1,7 @@ +Private ["_lock","_vehicle"]; + +_vehicle = _this select 0; + +_lock = if (locked _vehicle) then {false} else {true}; + +[_vehicle,_lock] Call CLTFNCSetVehicleLock; \ No newline at end of file diff --git a/Client/Action/Action_ToggleMHQLock.sqf b/Client/Action/Action_ToggleMHQLock.sqf new file mode 100644 index 0000000..3edb19a --- /dev/null +++ b/Client/Action/Action_ToggleMHQLock.sqf @@ -0,0 +1,9 @@ +Private ["_lock","_MHQ"]; + +_MHQ = _this select 0; + +_lock = if (locked _MHQ) then {false} else {true}; + +WFBE_RequestVehicleLock = ['SRVFNCREQUESTVEHICLELOCK',[_MHQ,_lock]]; +publicVariable 'WFBE_RequestVehicleLock'; +if (isHostedServer) then {['SRVFNCREQUESTVEHICLELOCK',[_MHQ,_lock]] Spawn HandleSPVF}; -- cgit v1.3.1