|
|
|
@ -6,10 +6,13 @@ pathDosbox = "/usr/bin/dosbox"
|
|
|
|
|
pathFDD = sysUser.."/.fdd"
|
|
|
|
|
urlGameList="http://fanta.56k.es/fdd/fdd_server/archive.lst"
|
|
|
|
|
urlGames="http://fanta.56k.es/fdd/fdd_server/archive/"
|
|
|
|
|
|
|
|
|
|
screenSizeW = love.graphics.getWidth()
|
|
|
|
|
screenSizeH = love.graphics.getHeight()
|
|
|
|
|
|
|
|
|
|
love.window.setTitle( "FDD GUI" )
|
|
|
|
|
font = love.graphics.newFont("res/fonts/old_computer_st.ttf", 12)
|
|
|
|
|
|
|
|
|
|
monitor = {}
|
|
|
|
|
monitor.img = love.graphics.newImage("res/imgs/disquete.png")
|
|
|
|
|
monitor.width = 200
|
|
|
|
@ -17,6 +20,13 @@ monitor.height = 200
|
|
|
|
|
monitor.x = (screenSizeW/2)-(monitor.width/2)
|
|
|
|
|
monitor.y = (screenSizeH/2)-(monitor.height/2)
|
|
|
|
|
|
|
|
|
|
rkey = {}
|
|
|
|
|
rkey.img = love.graphics.newImage("res/imgs/keyboard_key_r.png")
|
|
|
|
|
rkey.width = 64
|
|
|
|
|
rkey.height = 64
|
|
|
|
|
rkey.x = -100
|
|
|
|
|
rkey.y = -100
|
|
|
|
|
|
|
|
|
|
-- FUNCTIONS
|
|
|
|
|
|
|
|
|
|
function file_check(file_name)
|
|
|
|
@ -72,14 +82,24 @@ function download_listGames(file)
|
|
|
|
|
return arr
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
function check_numberGames()
|
|
|
|
|
os.execute("ls -1 /home/fanta/.fdd/ | wc -l")
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
-- FUNCIONES LOVE
|
|
|
|
|
|
|
|
|
|
function love.load()
|
|
|
|
|
check_dependencies()
|
|
|
|
|
download_gameList(urlGameList)
|
|
|
|
|
check_numberGames()
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
function love.update()
|
|
|
|
|
if love.keyboard.isDown( "r" ) then
|
|
|
|
|
rkey.x, rkey.y = 10,10
|
|
|
|
|
else
|
|
|
|
|
rkey.x, rkey.y = -100,-100
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
@ -87,6 +107,7 @@ function love.draw()
|
|
|
|
|
love.graphics.setBackgroundColor( (170/255), (100/255), (70/255) )
|
|
|
|
|
love.graphics.draw(monitor.img,monitor.x,monitor.y)
|
|
|
|
|
draw_floppyDiskName("Darkseed")
|
|
|
|
|
love.graphics.draw(rkey.img, rkey.x, rkey.y)
|
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
function love.keypressed(key)
|
|
|
|
|