In the first half of this video, lines were drawn using new Line(BufferGeometry, lineBasicMaterials).In the second half of this video, lines were drawn using new Line2(LineGeometry, LineMaterials).
The logic of this code is to create two overlapping points when you start drawing a line, and update the position of the last point as you move the mouse. After the left mouse button, insert a dot before the last dot, move the mouse to update the position of the last dot, and so on.
I don’t understand why all the other lines have no color except the first one is good.