Do you have any portion of a pkt file that you have already created? Case 2 will be the hardest.
You would first create the road and the shoulders.
Then you would use an auxiliary point to slope to surface on left and another to slope to surface on right.
Then you define an auxiliary link to connect the two auxiliary points.
Then would set up a decision to test math.abs(AL1.slope)<=0.2.
On the true side of the decision you would make a surface link from AP1 to AP2, then another surface link from AP1 to AP2 with a depth=0.1. And you would connect the vertical sides to close the shape.
On the false side of the math.abs(AL1.slope)<=0.2 decision you would add another decision with math.abs(AL1.slope)<=0.5.
On the true side of the math.abs(AL1.slope)<=decision, are you are going to have to manually set up a lot of sequential decisions in another Flowchart in order to set it up to start at the lower AP1/AP2 and go over and down the bench dimension and then up to surface and then if the x distance between that P# and AP# is more than the bench width you will need to create another one (math.abs(P#.x-AP#.x)). And keep setting those up until you think you will have enough to meet the maximum width. [I don't think you can use loop geometry to do this.]
On the false side of the math.abs(AL1.slope)<=0.5 decision you would do a decision to see whether AP1 or AP2 is lower and then place the retaining wall geometry on that side and a standard slope to surface point/link on the other side.
Kati Mercier, P.E. | LinkedIn | AutoCAD Civil 3D Certified Professional
Pronouns: She/Her
Co-author of "Mastering AutoCAD Civil 3D 2013"
AU2019 Speaker::: CES321590: Analyze and Revise Existing Subassembly Composer PKT Files for AutoCAD Civil 3D
AU2017 Speaker::: CI125544: Analyze and Devise in Subassembly Composer
AU2012 Speaker::: CI3001: Reverse Engineering with Subassembly Composer for AutoCAD Civil 3D
AU2011 Speaker::: CI4252: Create Subassemblies That Think Outside the Box With Subassembly Composer for AutoCAD® Civil 3D®