See the top rated post in this thread. Click here

Results 1 to 4 of 4

Thread: Tutorial help

  1. #1
    100 Club
    Join Date
    2007-10
    Location
    God's Own Country
    Posts
    183
    Login to Give a bone
    0

    Question Tutorial help

    Hi all,
    Im very new to lisp. recently i got a tutorial to do in lisp.
    see attached png file, how can i create the star with 5 ponts?
    any help ?
    Attached Images Attached Images
    Last edited by sandeepk; 2009-05-14 at 05:34 AM. Reason: forgot attachment

  2. #2
    The Silent Type RobertB's Avatar
    Join Date
    2000-01
    Location
    Seattle WA USA
    Posts
    5,859
    Login to Give a bone
    0

    Default Re: Tutorial help

    Quote Originally Posted by sandeepk View Post
    Hi all,
    Im very new to lisp. recently i got a tutorial to do in lisp.
    see attached png file, how can i create the star with 5 ponts?
    any help ?
    So what code have you written so far? If you are going to learn, you need to try, and not just copy.
    R. Robert Bell
    Design Technology Manager
    Stantec
    Opinions expressed are mine alone and do not reflect the views of Stantec.

  3. #3
    AUGI Addict
    Join Date
    2006-04
    Location
    (getpoint "Anywhere on the Enter Key =>")
    Posts
    1,160
    Login to Give a bone
    1

    Default Re: Tutorial help

    Quote Originally Posted by sandeepk View Post
    Hi all,
    Im very new to lisp. recently i got a tutorial to do in lisp.
    see attached png file, how can i create the star with 5 ponts?
    any help ?
    The following is a sample:
    Code:
    (defun C:Star ;start your code's function & name your own command as STAR
    (/ DTR InsertPoint Point1 ...) ;define points' name and other functions in your code as the local variables
    (defun DTR (A) (* pi (/ A 180.0))) ;sub-function that convents input angle value from degree to radian.
    (setq InsertPoint (getpoint "\nSelect Insert Point: ")) ;insert point definition
    (setq Point1 (polar InsertPoint (DTR degrees) Distance_From_InsertPoint_to_Point1)
    ;the above line defines Point1 referenced to InsetPoint.
    ;you need to fill in a angle in degree & a distance in this sample
    (setq Point2 similar_definition_to_Point1_above)
    ;and so on...
    (command "line" Point1 Point2 ...) ;draw a star with lines along your defined points.
    (princ) ;prevent lisp from returning any unwanted text to the command prompt.
    ) ;end of your code
    Hope it helps.

  4. #4
    100 Club
    Join Date
    2007-10
    Location
    God's Own Country
    Posts
    183
    Login to Give a bone
    0

    Default Re: Tutorial help

    Whoo hooo, I did it with my style, but its too long code. no prob, I am trying.
    Thank you boKirra, your code is nice to learn.
    keep in touch
    Thank you

    Quote Originally Posted by RobertB View Post
    So what code have you written so far? If you are going to learn, you need to try, and not just copy.
    Last edited by sandeepk; 2009-05-18 at 04:49 AM.

Similar Threads

  1. Tutorial
    By minhtct in forum Revit - Student Support
    Replies: 0
    Last Post: 2011-04-22, 11:28 PM
  2. MEP tutorial
    By mj_lampad@yahoo.com in forum Revit MEP - General
    Replies: 2
    Last Post: 2010-02-16, 05:46 PM
  3. Any tutorial for new CUI?
    By thomaswaynemorris in forum AutoCAD CUI Menus
    Replies: 2
    Last Post: 2005-12-17, 04:07 PM
  4. Tutorial Always on Top?
    By doug.61606 in forum Revit - Tutorials
    Replies: 7
    Last Post: 2005-04-28, 12:58 PM
  5. Looking for tutorial
    By jerry.runnels in forum AutoCAD Mechanical - General
    Replies: 0
    Last Post: 2004-08-10, 01:47 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •