diff --git a/assets/icons/ray.svg b/assets/icons/ray.svg new file mode 100644 index 000000000..9a560c793 --- /dev/null +++ b/assets/icons/ray.svg @@ -0,0 +1,3 @@ + + + diff --git a/src/modules/draw/draw/ray.rs b/src/modules/draw/draw/ray.rs index 4d976acd9..30d7b3f6b 100644 --- a/src/modules/draw/draw/ray.rs +++ b/src/modules/draw/draw/ray.rs @@ -61,9 +61,7 @@ impl CadCommand for RayCommand { Vector3::new(base.x, base.y, base.z), Vector3::new(dir_n.x, dir_n.y, dir_n.z), ); - // Stay active: new base = same base (can keep clicking through points) - // Actually AutoCAD prompts for new start after each ray — reset base. - self.base = None; + // Repeated through points share the original start point. CmdResult::CommitEntity(EntityType::Ray(ray)) } else { self.base = Some(pt); diff --git a/src/ui/ribbon/draw_tools/04_ray.rs b/src/ui/ribbon/draw_tools/04_ray.rs new file mode 100644 index 000000000..3fc739731 --- /dev/null +++ b/src/ui/ribbon/draw_tools/04_ray.rs @@ -0,0 +1,6 @@ +Tool { + command: "RAY", + label: "Ray", + icon: include_bytes!(concat!(env!("CARGO_MANIFEST_DIR"), "/assets/icons/ray.svg")), + options: &[], +}