correzione a lettura Delta X Y Z da btl

This commit is contained in:
luca.mazzoleni
2024-02-21 15:11:08 +01:00
parent aa94102b28
commit 172ac97f0d
+9 -3
View File
@@ -85,9 +85,15 @@ function WallExec.ProcessWalls( dRawL, dRawW, dRawH, vWall, bMachGroupOk, bNewPr
if WD.GetOrigCorner then
sOrigCorner = WD.GetOrigCorner( EgtGetInfo( BtlInfoId, 'REFPOS', 'i') or 0)
end
local DeltaX = EgtGetInfo( BtlInfoId, 'PANELDELTAY', 'd') or WD.DELTA_X or 0
local DeltaY = EgtGetInfo( BtlInfoId, 'PANELDELTAX', 'd') or WD.DELTA_Y or 0
local DeltaZ = EgtGetInfo( BtlInfoId, 'PANELDELTAZ', 'd') or WD.DELTA_Z or 0
-- offset da interfaccia
local dDeltaXFromBtl = EgtGetInfo( BtlInfoId, 'PANELDELTAY', 'd') or 0
local dDeltaYFromBtl = EgtGetInfo( BtlInfoId, 'PANELDELTAX', 'd') or 0
local dDeltaZFromBtl = EgtGetInfo( BtlInfoId, 'PANELDELTAZ', 'd') or 0
-- se da interfaccia arriva un valore > 0 si usa quello, altrimenti si legge da WallData (default 0)
local DeltaX = EgtIf( dDeltaXFromBtl > 0, dDeltaXFromBtl, WD.DELTA_X or 0)
local DeltaY = EgtIf( dDeltaYFromBtl > 0, dDeltaYFromBtl, WD.DELTA_Y or 0)
local DeltaZ = EgtIf( dDeltaZFromBtl > 0, dDeltaZFromBtl, WD.DELTA_Z or 0)
if sOrigCorner == 'TL' then
nCorner = MCH_CR.TL
OrigOnTab = Point3d( 0 + abs( DeltaX), b3Tab:getDimY() - abs( DeltaY), DeltaZ)