diff --git a/[gameplay]/parachute2/client.lua b/[gameplay]/parachute2/client.lua index 556bc0f50..d8b598244 100644 --- a/[gameplay]/parachute2/client.lua +++ b/[gameplay]/parachute2/client.lua @@ -60,7 +60,8 @@ local function handleParachuteLogic() -- can we go to freefall/skydive if (strPlayerState == "GROUND" and bHasParachute) then - fRotationX, fRotationY, fRotationZ = getElementRotation(localPlayer); + local _, _, fRotationZ_ = getElementRotation(localPlayer); + fRotationZ = fRotationZ_ if (not isPedOnGround(localPlayer) and not getPedContactElement(localPlayer)) then if (fVZ < -0.1) then @@ -228,7 +229,7 @@ local function handleParachuteLogic() --]] -- player opening parachute - if (getControlState(localPlayer, "fire") and strParachuteState == "READY") then + if (getPedControlState(localPlayer, "fire") and strParachuteState == "READY") then strPlayerState = "ACTION"; setPedAnimation(localPlayer, "parachute", "para_open", -2, false, false, false, true); setPedAnimationSpeed(localPlayer, "para_open", 8); @@ -340,9 +341,8 @@ local function handleParachuteLogic() end -- player landed - if (strPlayerState == "LANDED") then - - end + -- if (strPlayerState == "LANDED") then + -- end end end addEventHandler("onClientRender", root, handleParachuteLogic); @@ -361,8 +361,8 @@ function cleanupParachute(bLandedGood) toggleControl("next_weapon", true); toggleControl("previous_weapon", true); - if (not bLandedGood) then + -- if (not bLandedGood) then -- todo: remove weapon from player via server -- takeWeapon(client, 46); - end -end \ No newline at end of file + -- end +end