Is this a good solution?
(defun Ale_Pline_LwVertices (EntObj FuzFac / LstVrt VrtIdx VrtInf OutLst) ; EntObj = VLA-OBJECT or ENAME
(setq
VrtIdx (vlax-curve-getEndParam EntObj)
LstVrt (vlax-curve-getPointAtParam EntObj VrtIdx)
)
(while (> VrtIdx 0)
(setq VrtInf (vlax-curve-getPointAtParam EntObj (setq VrtIdx (1- VrtIdx))))
(or (equal (car OutLst) VrtInf FuzFac) (setq OutLst (cons VrtInf OutLst)))
)
(if OutLst (if (equal LstVrt VrtInf FuzFac) OutLst (append OutLst (list LstVrt))))
)