|
to phight :n :hight :size
localmake "ppp posxyz
bk :size
localmake "xxx
posxyz
fd :size
localmake "angle 180/:n
localmake "radius
:size/(2*sin :angle)
localmake "xypos list :radius
:hight
make "xypos lput 0 :xypos
polystart
setposxyz :xxx
setposxyz :xypos
setposxyz :ppp
polyend
polyview
end
to poly :n :hight :size
repeat :n[fd :size
phight :n :hight :size rt 360/:n]
end
to pyramid :n :hight :width
down 90
poly :n :hight :width
end
|