You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
48 lines
1.4 KiB
Lua
48 lines
1.4 KiB
Lua
love.mouse.setVisible(false)
|
|
love.window.setFullscreen(true)
|
|
logo = {}
|
|
logo.img = love.graphics.newImage("logo.png")
|
|
logo.width = 300
|
|
logo.height = 300
|
|
logo.scale = 1
|
|
ScreenSizeW = love.graphics.getWidth()
|
|
ScreenSizeH = love.graphics.getHeight()
|
|
font = love.graphics.newFont("fonts/amiga4ever.ttf", 12)
|
|
songData = love.sound.newSoundData("mods/chiptune_no_150.mod")
|
|
song = love.audio.newSource(songData)
|
|
--love.timer.sleep( 1 )
|
|
song:play()
|
|
|
|
|
|
function love.load()
|
|
songPos = song:tell("samples")
|
|
songRate = songData:getSampleRate()
|
|
songSize = songData:getSampleCount()
|
|
end
|
|
|
|
function love.update(dt)
|
|
songPos = song:tell("samples")
|
|
songSam = songData:getSample(songPos)
|
|
love.draw()
|
|
|
|
end
|
|
|
|
function love.draw()
|
|
love.graphics.setColor(88,0,100)
|
|
love.graphics.circle("line", ScreenSizeW/2, ScreenSizeH/2, songSam * ScreenSizeW )
|
|
love.graphics.setColor(100,100,100)
|
|
love.graphics.circle("line", ScreenSizeW/2, ScreenSizeH/2, songSam * ScreenSizeW )
|
|
love.graphics.setColor(200,200,200)
|
|
love.graphics.circle("line", ScreenSizeW/2, ScreenSizeH/2, songSam * (ScreenSizeW/2) )
|
|
love.graphics.setColor(49,2,49)
|
|
love.graphics.circle("line", ScreenSizeW/2, ScreenSizeH/2, songSam * (ScreenSizeW/4) )
|
|
love.graphics.draw(logo.img, (ScreenSizeW/2)-(logo.width/2), (ScreenSizeH/2)-(logo.height/2), songSam, logo.scale, logo.scale)
|
|
love.graphics.setColor(255,255,255)
|
|
end
|
|
|
|
function love.keyreleased(key)
|
|
if key == "escape" then
|
|
love.event.quit()
|
|
end
|
|
end
|