function debut_fondu(chemin_image)
nom = Image.load(chemin_image) 
fader = Image.load(chemin_image) 


alphaValue = 255 
faderColor = Color.new(0,0,0,alphaValue) 
fader:clear(faderColor) 


while true do 
pad = Controls.read()
screen:clear() 
screen:blit(0,0,nom) 
screen:blit(0,0,fader) 
if alphaValue > 0 then 
alphaValue = alphaValue - 10
else 
break 
end 
faderColor = Color.new(0,0,0,alphaValue) 
fader:clear(faderColor) 
screen.waitVblankStart() 
screen.flip() 
end 


nom=nil
fader=nil
end


---------------------------------------
function fin_fondu(chemin_image)


nom = Image.load(chemin_image) 
fader = Image.load(chemin_image) 


alphaValue = 0
faderColor = Color.new(0,0,0,alphaValue) 
fader:clear(faderColor) 


while true do 
screen:clear() 
screen:blit(0,0,nom) 
screen:blit(0,0,fader) 
if alphaValue < 255 then 
alphaValue = alphaValue + 10
else 
break 
end 
faderColor = Color.new(0,0,0,alphaValue) 
fader:clear(faderColor) 
screen.waitVblankStart() 
screen.flip() 
end 


nom=nil
fader=nil


end





debut_fondu("images/by.png")
logo = Image.load("images/by.png")
minuteur = Timer.new() 
minuteur:start()
while true do 
pad=Controls.read()
Temps = minuteur:time()
screen:clear() 
screen:blit(0,0,logo) 
if Temps > 3000 then 
minuteur:stop() 
minuteur:reset() 
fin_fondu("images/by.png")
break
end
screen.flip() 
screen.waitVblankStart() 
end


dofile("menu.lua")