- in NestProcess primo abbozzo della creazione MachGroup
This commit is contained in:
+17
-5
@@ -556,16 +556,28 @@ while true do
|
||||
end
|
||||
end
|
||||
|
||||
-- Spostamento travi verso la testa della barra
|
||||
-- TODO vedere se integrabile in creazione MachGroup
|
||||
-- creazione MachGroup e Duplo
|
||||
for i = 1, #RawInventory.ActiveBeams do
|
||||
local Beam = RawInventory.ActiveBeams[i]
|
||||
local dOffset = NEST.STARTOFFSET or 0
|
||||
local Beam = RawInventory.ActiveBeams[i]
|
||||
|
||||
for j = 1, #Beam.NestedParts do
|
||||
-- creazione MachGroup
|
||||
local sMachGroup = EgtGetMachGroupNewName( i)
|
||||
local idMachGroup = EgtAddMachGroup( sMachGroup)
|
||||
|
||||
-- assegnazione info
|
||||
EgtSetInfo( idMachGroup, "BARLEN", Beam.dTotalLength)
|
||||
EgtSetInfo( idMachGroup, "MATERIAL", NEST.MATERIAL)
|
||||
EgtSetInfo( idMachGroup, "AUTONEST", 1)
|
||||
EgtSetInfo( idMachGroup, "PRODID", NEST.PRODID)
|
||||
EgtSetInfo( idMachGroup, "PATTID", idMachGroup)
|
||||
|
||||
-- Spostamento pezzi verso la testa della barra e aggiunta duplo
|
||||
for j = 1, Beam.NestedParts do
|
||||
local Part = Beam.NestedParts[j]
|
||||
|
||||
Part.dPosX = Part.dPosX - Beam.dResidualLength + dOffset
|
||||
local idDuplo = EgtDuploNew( Part.id)
|
||||
EgtSetInfo( idMachGroup, "PART" .. j, idDuplo .. "," .. Part.dPosX)
|
||||
end
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user