My first guitar program. YEAH!!!!!!!!!!

My first guitar program. YEAH!!!!!!!!!!

Anonymous
Not applicable
429 Views
2 Replies
Message 1 of 3

My first guitar program. YEAH!!!!!!!!!!

Anonymous
Not applicable

Guys, I want to express my gratitude for all those who helped me and answered my questions.

 

Here is my first program for dynamic distribution of frets on the guitar fretboard.

 

 

Before 

beforeCopy.jpg

 

after

 

afterCopy.jpg

 

 

+++++++++++++++++

 

How it works:

First we set UCS as it is shown on the below image.
Start script, select object and base point as it is shown on the below image.

settingTheUCS.jpg

 

 

+++++++++
Files are attached

 

 

 

Accepted solutions (1)
430 Views
2 Replies
Replies (2)
Message 2 of 3

ВeekeeCZ
Consultant
Consultant
Accepted solution

Congrats! Nice. 🙂


You have learn some commands... how about think about alogorithem?!

- do you really need two loops?

- do you need to use COPY command twice?

- why did you use while loop? why not repeat?

- why is this line (setq FretDistList ()) good for anything? (twice)

- why you use (princ) in the place where it is? (twice)


Some recommendations...

- (append FretDistList (list FretDistTemp )))
possible, but better is (cons FretDistTemp FretDistList) then (reverse FretDistList) if needed. Very common.

- turn off osnaps. In this line (command "_.COPY" MyFretObj "" BP DestPoint) are command still on! It cound goes wrong if it meet some (you never know).
you can use this approach (command "_.COPY" MyFretObj "" "_none" BP "_none" DestPoint)

- localize your variables and function

Message 3 of 3

Anonymous
Not applicable

Thanks for reply!

0 Likes