1
0
mirror of https://github.com/nophead/NopSCADlib.git synced 2025-08-16 04:13:57 +02:00

Added assertion to check colour format in module thread.

This commit is contained in:
Martin Budden
2021-05-30 16:00:13 +01:00
parent 0dab0dca08
commit ec07d95657

View File

@@ -50,6 +50,7 @@ function thread_profile(h, crest, angle, overlap = 0.1) = //! Create thread prof
[[-base / 2, -overlap, 0], [-crest / 2, h, 0], [crest / 2, h, 0], [base / 2, -overlap, 0]];
module thread(dia, pitch, length, profile, center = true, top = -1, bot = -1, starts = 1, solid = true, female = false, colour = undef) { //! Create male or female thread, ends can be tapered, chamfered or square
assert(is_undef(colour) || is_list(colour), "Thread colour must be in [r, g, b] form");
//
// Apply colour if defined
//