Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Lotto 49

edited April 2018 Posts: 77
displayMode(FULLSCREEN)
-- Use this function to perform your initial setup
function setup()
randit()
fontSize(64)
textMode(CENTER)
x=1200
m=1
end

-- This function gets called once every frame
function draw()
-- This sets a dark background color
background(40, 40, 50)
-- Do your drawing here
fill(232, 220, 10, 255)
rect(30,400,1000,200)
fill(16, 239, 103, 255)
ellipse(x+10,505,100,100)
ellipse(x+130,505,100,100)
ellipse(x+250,505,100,100)
ellipse(x+370,505,100,100)
ellipse(x+490,505,100,100)
ellipse(x+610,505,100,100)
ellipse(x+810,505,100,100)

text("Ziehung bei Lotto 6 aus 49", 450,300)
text("Die Lottozahlen        Zusatzzahl",500,650)
text("Neue Ziehung mit Klick",450,200)

fill(255)
x=x-1
if x <= 130 then x=130 end
ellipse(x,500,100,100)
ellipse(x+120,500,100,100)
ellipse(x+240,500,100,100)
ellipse(x+360,500,100,100)
ellipse(x+480,500,100,100)
ellipse(x+600,500,100,100)
ellipse(x+800,500,100,100)
fill(27, 31, 26, 255)
text(n1,x,500)
text(n2,x+120,500)
text(n3,x+240,500)
text(n4,x+365,500)
text(n5,x+480,500)
text(n6,x+600,500)
text(p,x+800,500)
end
function randit()
local tab={}
while #tab<7 do
local r=math.random(49)
local found=false
for z=1,#tab do
if tab[z]==r then
found=true
end
end
table.insert(tab,r)
end
end
table.sort(tab)
n1=(tab)
n2=(tab)
n3=(tab)
n4=(tab)
n5=(tab)
n6=(tab)
p=math.random(49)
return(tab)
end
function touched(t)
if t.state == BEGAN then
setup()
end
end