I edited mnip's, giving a lot more 3dom.
use x to draw, use t to set type of material, use v to set distance between each estion of spira, and use c to set lenght of spiral.
SHD4 is the best element to use.
have fun!
:)
spiralx = 0
spiraly = 0
spiralv = 0
divfac = 15
splth = 100000
function tpt.drawspiral(maxspiral,spart)
spiralv = 0
for i = 0, maxspiral - 1, 1 do
if spiralv ~= 360 then
spiralv = spiralv + 0.1
elseif spiralv == 360 then
spiralv = 1
end
spiralx = tpt.mousex + spiralv * math.cos(math.rad(spiralv))/divfac
spiraly = tpt.mousey + spiralv * math.sin(math.rad(spiralv))/divfac
if spiralx > -1 and spiraly > -1 and spiralx < 612 and spiraly < 384 then tpt.create(spiralx,spiraly,spart) end
end
end
function spiralkeys(key,blank,blank,event)
if string.upper(key) == "X" and event == 1 then
tpt.drawspiral(splth,sl)
elseif string.upper(key) == "T" and event == 1 then
sl = tpt.input("Spiral Drawing", "Input an element name to proceed")
elseif string.upper(key) == "V" and event == 1 then
divfac = tpt.input("Spiral Drawing", "Input a number for sprial wideness")
elseif string.upper(key) == "C" and event == 1 then
splth = tpt.input("Spiral Drawing", "Input a number for spiral length") * 100000
end
end
tpt.register_keypress(spiralkeys)
i think it is cool lol