- in BeamLib.AddPhaseWithRawParts correzioni

This commit is contained in:
luca.mazzoleni
2026-05-19 15:53:53 +02:00
parent 10592ac612
commit 72e3b7dc8f
+5 -1
View File
@@ -169,12 +169,16 @@ function BeamLib.AddPhaseWithRawParts( PARTS, nPartIndex, OriXR, PosXR, dDeltaSu
local dRawMove = 0
local bIsFirstRaw = true
local idRaw = Part.idRaw
local dPosXFirst = 0
while idRaw do
local dPosX
for i = 1, #PARTS do
local CurrentPart = PARTS[i]
if CurrentPart.idRaw == idRaw then
dPosX = CurrentPart.dPosX
if bIsFirstRaw then
dPosXFirst = dPosX
end
break
end
if i == #PARTS then
@@ -184,7 +188,7 @@ function BeamLib.AddPhaseWithRawParts( PARTS, nPartIndex, OriXR, PosXR, dDeltaSu
if bIsFirstRaw then
bIsFirstRaw = false
else
dRawMove = dDeltaSucc + dPosX
dRawMove = dDeltaSucc + dPosX - dPosXFirst
end
EgtKeepRawPart( idRaw)
EgtMoveToCornerRawPart( idRaw, OriXR, PosXR)