← Inbox

C3D-TRACTB · Tract B partial (2 sides) done

West line + road frontage, anchored at IPFs #506/#478

Script file
C3D-TRACTB.cs
Target
active document · model space
Author
claude
Approved
yes · claude (session)
Timeout
60s

C# payload

// Draw the two Tract B sides I can read: west line (N02-06-04E 700.98) anchored at IPF #506,
// and road frontage (N13-41-11E 734.86) anchored at IPF #478. Floating until the connectors are known.
var bt = (BlockTable)Tx.GetObject(Db.BlockTableId, OpenMode.ForRead);
var ms = (BlockTableRecord)Tx.GetObject(bt[BlockTableRecord.ModelSpace], OpenMode.ForWrite);
EnsureLayer("C-PROP-LINE");

Point2d Go(Point2d s, double degFromNorth, char ew, double dist) {
    double a = degFromNorth * System.Math.PI / 180.0;
    double de = dist * System.Math.Sin(a) * (ew == 'W' ? -1 : 1);
    double dn = dist * System.Math.Cos(a); // all calls here are Northerly
    return new Point2d(s.X + de, s.Y + dn);
}
void Line(Point2d a, Point2d b, string label) {
    var ln = new Line(new Point3d(a.X, a.Y, 0), new Point3d(b.X, b.Y, 0)); ln.Layer = "C-PROP-LINE";
    ms.AppendEntity(ln); Tx.AddNewlyCreatedDBObject(ln, true);
    Log($"{label}: ({a.X:F2},{a.Y:F2})->({b.X:F2},{b.Y:F2}) len={a.GetDistanceTo(b):F2}");
}

var w0 = new Point2d(2166529.849, 1330757.405); // IPF #506
Line(w0, Go(w0, 2.101111, 'E', 700.98), "Tract B WEST N02-06-04E 700.98");

var e0 = new Point2d(2166609.127, 1330752.555); // IPF #478
Line(e0, Go(e0, 13.686389, 'E', 734.86), "Tract B ROAD FRONTAGE N13-41-11E 734.86");

Log("Tract B partial (2 sides) drawn.");

Result

Status
success
Drawing file
C:\Users\sanja\OneDrive\_SurveyDisco\260619 - 3625 Stonewall Tell Rd, Atlanta, GA 30349, USA\260619 - 3625 Stonewall Tell Rd.dwg
Message
Executed C3D-TRACTB (0 entities touched).
Entities
Duration
429 ms
Civil 3D
25.0.0.0

Log

Tract B WEST N02-06-04E 700.98: (2166529.85,1330757.41)->(2166555.55,1331457.91) len=700.98
Tract B ROAD FRONTAGE N13-41-11E 734.86: (2166609.13,1330752.55)->(2166783.00,1331466.55) len=734.86
Tract B partial (2 sides) drawn.

Notes

What worked, what didn't, job-specific gotchas — flagged notes feed the recipes.

No notes yet.