Jump to content

MultiPLine (MPL) — polyline-based MLINE replacement with per-line layers, presets, and auto-sync [Free + Pro]


Recommended Posts

Posted

Hi all,

 

I've been a lurker on CADTutor for years and learned 

a lot from this community, so I wanted to share 

something I built and get feedback from people who 

actually know LISP.

 

Background: I'm a civil CAD drafter working on US 

land development projects — grading, drainage, 

easements, corridors. MLINE has always been the 

tool I wanted to use for drawing parallel offset 

lines but couldn't, mainly because the objects are 

locked, there's no lineweight control per component, 

and the .mln style management across a team is a 

nightmare. So I wrote a replacement.

 

──────────────────────────────────

WHAT IT DOES

──────────────────────────────────

 

Command MPL works like PLINE — you draw a centerline 

and it generates a set of configurable parallel 

LWPOLYLINEs around it. Every satellite line is a 

real polyline: fully grip-editable, trimmable, 

offsettable, joinable. No locked geometry, no 

exploding required.

 

Each satellite line carries its own:

- Offset distance (positive = left, negative = right)

- Layer (Pro version)

- Color, linetype, lineweight, linetype scale

 

Configuration is handled through a DCL dialog 

(MPLEDIT). Settings save as user defaults and, 

in the Pro version, as named presets stored in 

%APPDATA%\MplineAuto\presets.dat.

 

──────────────────────────────────

TWO VERSIONS

──────────────────────────────────

 

Lite (free .lsp):

- MPL, MPLEDIT, MPLSYNC

- Manual sync after edits — run MPLSYNC, 

  window-select the group, done

- Groups are tracked via XDATA (app tag: MPLINE_PIPE)

 

Pro (compiled .vlx, $29.49):

- Everything in Lite plus:

- Command reactor for auto-sync — watches masters 

  before/after every command, diffs vertex lists, 

  rebuilds only what changed

- Named preset library with Save/Update/Delete 

  from the dialog

- Per-satellite layer assignment

- MPLADD — promote existing LWPOLYLINEs or LINEs 

  into MPL groups

- MPLON / MPLOFF — toggle reactor at runtime

- XDATA app tag: MPLINE_AUTO

 

──────────────────────────────────

IMPLEMENTATION NOTES

──────────────────────────────────

 

The interesting part was the Pro reactor. I went 

through a few approaches before landing on a global 

command reactor that snapshots the master cache 

before a command fires and diffs it after. This 

avoids object reactors entirely (which caused IDispatch 

arity issues in testing) and means the reactor 

doesn't interfere with Express Tools or COPY/MIRROR 

operations on non-MPL geometry.

 

Groups copied with COPY or MIRROR produce new masters 

on the next MPLSYNC call — the reactor doesn't 

auto-register copies, which is intentional to avoid 

unexpected geometry multiplication.

 

Happy to discuss the approach if anyone has thoughts 

or has solved similar problems differently.

 

──────────────────────────────────

LINKS

──────────────────────────────────

 

Video walkthrough: https://youtu.be/DXpyy1JWtXs

 

Free Lite download: 

https://skillamplifier.gumroad.com/l/hgpujs

 

Pro listing: 

https://skillamplifier.gumroad.com/l/nsidsv

 

Blog post with full documentation and use cases:

https://skillamplifier.wordpress.com/2026/05/16/multipline/

 

Full disclosure: I'm the developer. Posting here 

because I'd genuinely value feedback from experienced 

LISP users, and the Lite version is free so there's 

no risk trying it.

 

Thanks for any thoughts.

 

Zlatislav

Posted (edited)

Just a couple of comments have this, type 2,4,-3,-4 and so on, draws multiple plines, as many as you type in one go.. Have a drag line over existing multi offsets and get all offsets and layers, so can make another pline without user input.

 

Also what about Bricscad users ? Plenty of us here as well as other software.

 

Oh yeah look at this image you draw a "WALL" that is multiple lines and on correct layers, predefined layers that are named in a txt file, so match what a user wants without editing code, won't go into how we made that work other than variable = layer name.

 

Not sure that the task really warrants a VLX and a cost when there is software out there for the task and its free. I know from experience trying to sell software is extremely hard, as per draw house program some 130 lisps.

 

Do you have something similar to the attached DOCX, showing what you have as say a package, most programs are free and open source some have a cost as need to be customised for clients. There is more scope for users to buy a package rather than just one program.

 

3dhouse.thumb.png.956c430c8bae97125ce124cb8c0c41d0.png

Cadarc1.png.5d4c8036a81fe09d84d2f1b69fe03a45.png

Lisp files DEC 2025.docx

Edited by BIGAL
Posted

Thanks both for the honest feedback — exactly what I was hoping for.

@pkenewell — appreciate the link, I'm aware of Lee Mac's MPLine and have a lot of respect for his work. His implementation is elegant and handles the core offset drawing well. MultiPLine goes in a different direction: DCL-based configuration dialog, per-line layer assignment, named presets that persist across drawings, and the Pro version adds a command reactor for auto-sync. Different scope rather than a direct replacement for what he built. Worth knowing about either way so thanks for flagging it.

@BIGAL — fair points across the board. BricsCAD: honestly didn't design for it and can't make promises there. The reactor implementation in Pro leans on AutoCAD-specific VLR functions. Lite might load fine in BricsCAD but I haven't tested it — if any BricsCAD users try it I'd be curious to hear the result. On the "why pay" question: fair challenge. The free Lite version covers the core workflow for most users. The Pro is aimed at teams and daily-driver users who want auto-sync and a preset library they can share across a team. Whether that's worth $29 is genuinely up to the buyer — I'm not trying to oversell it. The package suggestion is actually something I've been thinking about. MultiPLine is my first commercial release but I have other tools in progress. A bundle makes more sense as a value proposition and I'll keep that in mind for when there's more to package together.
One more thing — I've added the full .lsp source to the Lite download on Gumroad. Free to inspect, modify for personal use, and learn from.

Thanks again for taking the time — this kind of feedback from experienced users is more useful than any marketing.

Zlatislav

  • Like 1
Posted

Taking your example video this is convert a p/line to a drainage pipe written for civil road works, with most common AUS sizes. Needs linetype Equal the length of dashed is set to 2.4 which is a length of a concrete pipe. Handy for civil works. It is not dynamic.

 

*EQUAL,_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
A,1.0,-1.0

 

image.thumb.png.736811eac9a932ab6ee4b1fc6f11afad.png

Pipe offsets.lsp

 

If you post here a VLR function can test.

Fillet offset circle.lsp

Have a look at "Fillet offset circle" uses reactors.

 

 

Posted

@BIGAL — the Pipe offsets approach is practical — hardcoded OD values per size as named commands (P300, P450 etc) is exactly the kind of thing that saves time on repetitive civil work. Applies the offset and switches to Divide linetype in one shot. Clean for a site-specific workflow.

The Fillet offset circle reactor is a nice trick — using :vlr-unknowncommand to intercept custom prefixed strings like F100 or O234 is a different approach than what I went with. Avoids the willstart/ended pair entirely by hooking into unrecognised input instead.

 

Here's the core VLR setup from the Pro version 
for comparison:

(vlr-command-reactor
  nil
  '((:vlr-commandWillStart . mpla-on-cmd-willstart)
    (:vlr-commandEnded     . mpla-on-cmd-ended)
    (:vlr-commandCancelled . mpla-on-cmd-cancel)
    (:vlr-commandFailed    . mpla-on-cmd-cancel))
)

The willstart handler snapshots vertex lists and widths of all MPL masters into a global cache (*mpla-master-cache*). The ended handler diffs and rebuilds only the groups that changed. Went this route to watch standard commands passively without requiring any special input syntax.

Happy to share more if useful.

Posted
12 hours ago, BIGAL said:

Pipe offsets.lsp


What should be the type of line to make a line like in the picture? 
If you use the EQUAL line type, you get just two dashed lines.

The line type "Divide" is set in the code?
(setq lt "Divide") 

Divide.png

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...