| Wiki Markup |
|---|
h1. Exit Channel Drawing Script |
...
*layer2* \- [Layer{~}new~|AutoCAD Basics Layer] creates a new light grey layer, "echannel." |
...
layer2 <\- layer |
...
{~}new~("echannel",ltgrey) |
...
channel1 - Calls the Channel Program to draw to tank channel based on given inputs.
channel1 <- ChannelDrawing(echannelorigin,p1,TChannelWall)
Note: echannelorigin is calculated through a for loop.
echannelorigin =
- if layout1:
- x: 0
- y: 0
- z: 0
- if layout2:
- x: tankorigin0
- y: tankorigin1 - TPlantWall
- z: tankorigin2 + HSed - HEChannel
- if layout3:
- x: tankorigin0 - LSed + WChannel + TChannelWall + WEChannel
- y: tankorigin1 - TPlantWall
- z: tankorigin2 + HSed - HEChannel
- if layout4:
- x: tankorigin0 - LSed + WChannelInlet + TChannelWall + WEChannel
- y: tankorigin1 - TPlantWall
- z: tankorigin2 + HSed - HEChannel
p1 =
- x: WSed + 2TPlantWall
- y: WExitChannel
- z: HExitChannel
TChannelWall = 0.15m
rotate1 - Rotate turns the object based on a given point and rotation angle.
rotate1 <- rotate(echannelorigin,90)
Note: echannelorigin is calculated through a for loop.
echannelorigin =
- if layout1:
- x: 0
- y: 0
- z: 0
- if layout2:
- x: tankorigin0
- y: tankorigin1 - TPlantWall
- z: tankorigin2 + HSed - HEChannel
- if layout3:
- x: tankorigin0 - LSed + WChannel + TChannelWall + WEChannel
- y: tankorigin1 - TPlantWall
- z: tankorigin2 + HSed - HEChannel
- if layout4:
- x: tankorigin0 - LSed + WChannelInlet + TChannelWall + WEChannel
- y: tankorigin1 - TPlantWall
- z: tankorigin2 + HSed - HEChannel
bigunion - UnionallA selects all the objects currently in the workspace and joins them into one single object.
bigunion <- unionallA
layerset - Layerset selects the layer "0".
layerset <- layerset("0")
layerfreeze2 - Layerfreeze locks the layer "echannel" so that it cannot be edited.
...
{float:left|border=2px solid black} [!channel1.bmp|width=450px!|AutoCAD Channel Program] Northeast Isometric View {float} *channel1* \- Calls the [Channel Program|AutoCAD Channel Program] to draw to tank channel based on given inputs. channel1 <\- ChannelDrawing(echannel{~}origin~,p1,T{~}ChannelWall~) *Note*: echannel{~}origin~ is calculated through a for loop. echannel{~}origin~ = * if layout1: ** x: 0 ** y: 0 ** z: 0 * if layout2: ** x: tank{~}origin0~ ** y: tank{~}origin1~ \- T{~}PlantWall~ ** z: tank{~}origin2~ + H{~}Sed~ \- H{~}EChannel~ * if layout3: ** x: tank{~}origin0~ \- L{~}Sed~ + W{~}Channel~ + T{~}ChannelWall~ + W{~}EChannel~ ** y: tank{~}origin1~ \- T{~}PlantWall~ ** z: tank{~}origin2~ + H{~}Sed~ \- H{~}EChannel~ * if layout4: ** x: tank{~}origin0~ \- L{~}Sed~ + W{~}ChannelInlet~ + T{~}ChannelWall~ + W{~}EChannel~ ** y: tank{~}origin1~ \- T{~}PlantWall~ ** z: tank{~}origin2~ + H{~}Sed~ \- H{~}EChannel~ p1 = * x: W{~}Sed~ + 2T{~}PlantWall~ * y: W{~}ExitChannel~ * z: H{~}ExitChannel~ T{~}ChannelWall~ = 0.15m \\ \\ {float:left|border=2px solid black} [!rotate1.bmp|width=250px!|AutoCAD Channel Program] Top View {float} *rotate1* \- [Rotate|AutoCAD Basics Rotate] turns the object based on a given point and rotation angle. rotate1 <\- rotate(echannel{~}origin~,90) *Note*: echannel{~}origin~ is calculated through a for loop. echannel{~}origin~ = * if layout1: ** x: 0 ** y: 0 ** z: 0 * if layout2: ** x: tank{~}origin0~ ** y: tank{~}origin1~ \- T{~}PlantWall~ ** z: tank{~}origin2~ + H{~}Sed~ \- H{~}EChannel~ * if layout3: ** x: tank{~}origin0~ \- L{~}Sed~ + W{~}Channel~ + T{~}ChannelWall~ + W{~}EChannel~ ** y: tank{~}origin1~ \- T{~}PlantWall~ ** z: tank{~}origin2~ + H{~}Sed~ \- H{~}EChannel~ * if layout4: ** x: tank{~}origin0~ \- L{~}Sed~ + W{~}ChannelInlet~ + T{~}ChannelWall~ + W{~}EChannel~ ** y: tank{~}origin1~ \- T{~}PlantWall~ ** z: tank{~}origin2~ + H{~}Sed~ \- H{~}EChannel~ \\ \\ *bigunion* \- [Union{~}allA~|AutoCAD Basics Unions] selects all the objects currently in the workspace and joins them into one single object. bigunion <\- union{~}allA~ *layerset* \- [Layer{~}set~|AutoCAD Basics Layer] selects the layer "0". layerset <\- layer{~}set~("0") *layerfreeze2* \- [Layer{~}freeze~|AutoCAD Basics Layer] locks the layer "echannel" so that it cannot be edited. layerfreeze2 <\- layer{~}freeze~("echannel") |