3. Formatting Individual Steps
Most of the individual items on a page can be tailored by selecting the object and moving it and / or resizing it, or by right-clicking the object to get the pop-up menu of options. This section covers some of the commonly used edits.
3.1 Moving the Assembly Image
You can move the assembly image by clicking on it, holding down the mouse button and dragging it to another location on the page. This is useful if you have a large parts list that cuts across the assembly model and for making room for a callout on a page.
3.2 Changing the Shape of the Parts List
You can change the shape of the parts list as follows:
1. Click on the box to bring up the outline with the little black square.
2. Click and hold the black square and move it up or down to achieve the desired shape.
3.3 Changing the Size of the Assembly Image
You can change the size of the assembly image as follows:
1. Right-click the assembly to bring up the pop-up menu.
2. Choose "Change Scale".
3. Enter the required scale and click "OK".
Note: If you are asked whether to apply this to only this step, click "Yes", else the change in scale will apply to all steps.
3.4 Excluding Specific Parts from the Parts List
Large parts, such as baseplates, can make the parts list look rather messy and also reduces the space available for the full Bill of Materials. You can reduce the scale of the parts, but this affects all parts and you can only reduce the scale so far before the smaller parts become difficult to recognise.
You can hide a specific part from the parts list for the step and the Bill of Materials by:
1. Locating the part you want to hide (Hint: look for the part number).
2. Adding the following LPub code before and after the code for the part you want to hide:
0 !LPUB PLI BEGIN IGN
1 10 0 8 160 0 0 1 0 1 0 -1 0 0 3857.dat
0 !LPUB PLI END
3. Clicking the "Redraw" icon to refresh the image.
for the before and after screenshot.
3.5 Substituting single parts for one part
Sometimes it is necessary to convert two or more parts into a single part. For example, leg assemblies used in MLCad's minifigure generator show up in LPub as the individual parts that make up the legs (i.e. left leg, right leg and hips), as shown in the image below. PLI SUB commands within LPub can be used to show the complete leg assembly in the parts list.
The first step to convert the three parts into a single part is to find the part number. In this particular example, part number 82059 was used to create the legs in the MLCad minifgure generator was 82059, which means the file for that part will be called "82059.dat".
The next step is to add the following code in LPub:
0 !LPUB PLI BEGIN SUB 82059.dat
0 !LPUB PART BEGIN IGN
1 [... parts that are being substituted out]
0 !LPUB PART END
0 !LPUB PLI END
The first command tells LPub what part to substitute in and the second command line tells LPub to start the substitution. These two lines are added before the code for the parts that are being substituted out. The last two commands are added to tell LPub to stop the substitution process.
The final step is to press the "Redraw" icon at the top of the Lpub control file. As shown below, the three leg elements have now been replaced with the single part.
Note: Credit to Alasdair Ryan for providing the content for this section.
3.6 Incorporating LSynth parts
LSynth allows you to incorporate and render flexible elements, such as hoses, pneumatic tubing and power function cables, into your model and instructions.
The code for LSynth parts is mainly added in MLCad and is therefore not covered in this guide. However, Alasdair Ryan has written a comprehensive tutorial on incorporating LSynth parts. His tutorial can be found here
3.7 Rotating the assembly image
Sometimes it makes sense to rotate the assembly image to give the reader a better view of where the parts are added. This can be done using the ROTSTEP command, which takes the following basic form:
0 LPUB ROTSTEP X Y Z REL
The X, Y & Z are the dimensional axes of the 3D assembly image. You can change the rotation of the assembly image by specifiying the values for how far (in degrees) the assembly should rotate around each axis.
In the following example, the two white plates have just been added to create a window sill, and some flowers will be added to the window sill in a subsequent step.
Rotating this view by 90 degrees on the Y-axis will allow us to view the window from the outside. This can be done as follows:
1. Add the ROTSTEP command shown below.
2. Click the "Redraw" button to refresh the page.
0 LPUB ROTSTEP 0 90 0 REL
1 ... (parts for the step)
for the result.
Once a rotation has been set, it will apply to all subsequent steps. You can set the view back to the original orientation by adding the following code to the step where you need the original orientation to be shown:
0 LPUB ROTSTEP 0 0 0 REL
In the above example, the view is returned back to the original orientation once the window is completed, and all subsequent steps will now be in that original orientation. This is shown here
Flipping an image so that the underside is shown can be done by setting the X or Z value to 180 degrees, as follows:
0 LPUB ROTSTEP 180 0 0 REL
0 LPUB ROTSTEP 0 0 180 REL
In this example, the last image in the sub model has been rotated by 180 degrees around the X-axis to show where the feet (i.e. 1x1 round plates) of the lounge chair should go.
There is no need to reset the view back to the original orientation in this instance as this is the last step in the submodel. The next step will be in the same orientation that was applied before the submodel was started.
- The X, Y and Z values can be positive or negative. For example, a value of +90 degrees will give a quarter turn in one direction, while a value of -90 degrees will give a quarter turn in the opposite direction.
- Visualising the axes around the model helps to determine which axis (or axes) you should target to get the right orientation, as illustrated here. (Although I tend to use trial and error!)