Jump to content

Recommended Posts

Posted

I can do a simple code for the rectangle, for the line, but I don`t know, how to do the code for the arc, and how to ajust everything in one program!

Please advice!

Posted

I assume that this is for your assignment due on Monday.

 

I would advise you that CADTutor has a strict policy against helping with "assignments" in that we don't support it in this forum.

 

We can offer advice, but we are not here to do your work for you. So please bear that in mind before personal messaging me. :wink:

Posted

I did AutoLisp code for the house, and would like to code the door and the window, I was thinking of making them as a block, any idea please?

 

Please see the house code:

 

 

 
; House
; Date: 9/21/09
; Written by: F L
(defun c:House ()
;define the function
;********************************************************
  ;Get User Inputs

(setq pt1 (getpoint "\nfirst corner of rectangle: "))
  ;get the first corner of the rectangle
(setq pt2 (getcorner pt1 "\nsecond corner of rectangle: "))
  ;get the second corner of the rectangle
(setq pt3 (list (car pt2) (cadr pt1)))
  ;get the second point
(setq pt4 (list (car pt1) (cadr pt2)))
  ;get the fourth point
(command "line" pt1 pt3 pt2 pt4 "c")
(setq dist (distance pt4 pt2))
(setq dist (/ dist 2.0))
(setq midpt (polar pt4 0 dist))
(setq pt5 (getpoint midpt "\nEnter top of house: "))
(command "line" pt4 pt5)
(command "line"pt2 pt5)

(princ)
  ;finish cleanly
) ;end of defun



Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...