;+++++++++++++++++++++++++++++
;+  板底筋-二级[mini_bdj2]   +
;+++++++++++++++++++++++++++++

(apply
	'(lambda( / x )
		(or mai_pile_text
			(not (setq x (mai_panel_search "谜你结构专业设置文件[mini_jiegou_config].lsp")))
			(load x)
		)
	)
	nil
)

(defun C:mini_bdj2 ( / old_pwidth ang ang1 old_cmd old_osmode p1 p2 p3 p4 p5 p6 scale)    ;板底筋(二级)cx
	(mini_start nil)
	(mai_last_com "mini_bdj2")
	(mai_get_scale)
	(setq old_osmode (getvar "osmode"))
	(setq old_pwidth (getvar "plinewid"))
	(or (setq p1 (getpoint "\n画板底筋<二级>,输入第一点:<退出>")) (exit))
	(setvar "osmode" 128)
	(or (setq p2 (getpoint p1 "\n画板底筋<二级>,输入第二点:<退出>")) (exit))
	(setq
		scale (/ 100. mai_scale2) 
		ang (angle p1 p2)
		ang1 (+ ang (* 0.5 pi))
		p4 (polar p2 ang (* scale -48))
		p3 (polar p1 ang (* scale 48))
		p5 (polar (polar p3 ang (* scale 20)) ang1 (* scale 12))
		p6 (polar (polar p4 ang (* scale -20)) ang1 (* scale 12))
	)
	(apply 'mai_create_layer mai_rein_l_layer)
	(setvar "plinewid" (* 0.35 mai_scale2))
	(mai_entmake "lwpolyline" (list p5 p3 p4 p6))
	(mai_end)
)
