From 5a589c5acb6bc8bcd972a7dacac939e5573f9d3a Mon Sep 17 00:00:00 2001 From: Stiofan-K <108685389+Stiofan-K@users.noreply.github.com> Date: Thu, 14 May 2026 23:36:09 +0200 Subject: [PATCH] Locust jet clamping Locust jets overturn at full speed, making the jets point downward :O Showing the jets at full speed is nice visually, but it seems unintentional. --- scripts/gunshipraid.lua | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/scripts/gunshipraid.lua b/scripts/gunshipraid.lua index 91e306153d..585a7f4838 100644 --- a/scripts/gunshipraid.lua +++ b/scripts/gunshipraid.lua @@ -19,8 +19,12 @@ local function TiltWings() while true do local vx,_,vz = spGetUnitVelocity(unitID) local speed = vx*vx + vz*vz - Turn (rjet, x_axis, math.rad(2) * speed, math.rad(60)) - Turn (ljet, x_axis, math.rad(2) * speed, math.rad(60)) + local turnTarget = math.rad(2) * speed + if turnTarget > math.rad(90) then + turnTarget = math.rad(90) + end + Turn (rjet, x_axis, turnTarget, math.rad(60)) + Turn (ljet, x_axis, turnTarget, math.rad(60)) Sleep(100) end end