diff --git a/LuaLibs/RunMachParamFromSWCalc.lua b/LuaLibs/RunMachParamFromSWCalc.lua index d281bd0..bb57aa2 100644 --- a/LuaLibs/RunMachParamFromSWCalc.lua +++ b/LuaLibs/RunMachParamFromSWCalc.lua @@ -62,7 +62,7 @@ function RunMachParamFromSWCalc.Exec() local nLayerQty = EgtGetInfo( nLastLayerId, KEY_SLICE_NBR, 'i') -- ciclo sui layer local nLayerIndex = 1 - local nLayerId = EgtGetFirstNameInGroup( nPartId, SLICE_LAYER .. nLayerIndex) + local nLayerId = EgtGetFirstNameInGroup( nPartId, SLICE_LAYER .. nLayerIndex) or EgtGetFirstNameInGroup( nPartId, "__" .. SLICE_LAYER .. nLayerIndex) while nLayerId do -- rimuovo eventuale info precedente del tempo di attesa EgtRemoveInfo( nLayerId, KEY_WAITING_TIME) @@ -172,7 +172,7 @@ function RunMachParamFromSWCalc.Exec() -- aggiorno interfaccia EgtProcessEvents( 400 + ( nLayerIndex / nLayerQty * 100), 0) nLayerIndex = nLayerIndex + 1 - nLayerId = EgtGetFirstNameInGroup( nPartId, SLICE_LAYER .. nLayerIndex) + nLayerId = EgtGetFirstNameInGroup( nPartId, SLICE_LAYER .. nLayerIndex) or EgtGetFirstNameInGroup( nPartId, "__" .. SLICE_LAYER .. nLayerIndex) end if nMaxIndex < nLayerIndex then nMaxIndex = nLayerIndex end nPartId = EgtGetNextPart( nPartId)