clear submodules
This commit is contained in:
parent
7308086139
commit
6d623dec28
|
@ -1,9 +0,0 @@
|
||||||
[submodule "lib/love-gltf"]
|
|
||||||
path = lib/love-gltf
|
|
||||||
url = https://gitlab.com/Alloyed/love-gltf.git
|
|
||||||
[submodule "lib/luasocket"]
|
|
||||||
path = lib/luasocket
|
|
||||||
url = https://github.com/lunarmodules/luasocket
|
|
||||||
[submodule "lib/lua54"]
|
|
||||||
path = lib/lua54
|
|
||||||
url = https://github.com/walterschell/Lua.git
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
D:/dev/love/love.exe "./client/"
|
||||||
|
pause
|
|
@ -0,0 +1,2 @@
|
||||||
|
D:/dev/love/love.exe "./metaserver/"
|
||||||
|
pause
|
|
@ -1,3 +1 @@
|
||||||
local http = assert( require 'socket.http' )
|
assert( assert( require 'socket.http' ).request 'https://api.ipify.org' ) == '142.162.167.92'
|
||||||
print( "Retrieving IP: " )
|
|
||||||
return assert( http.request 'https://api.ipify.org' )
|
|
|
@ -6,7 +6,7 @@ local socket = assert( require 'socket' )
|
||||||
local packet = assert( shared.packet )
|
local packet = assert( shared.packet )
|
||||||
local udp = assert( socket.udp() )
|
local udp = assert( socket.udp() )
|
||||||
udp:settimeout(0)
|
udp:settimeout(0)
|
||||||
assert( udp:setsockname( shared.metaserver.ip, shared.metaserver.port ) )
|
assert( udp:setsockname( socket.dns.toip(socket.dns.gethostname()), shared.metaserver.port ))
|
||||||
|
|
||||||
--Servers broadcast their information here.
|
--Servers broadcast their information here.
|
||||||
--The metaserver builds a list of available servers. ( available meaning, "broadcasted in last ten heartbeats" )
|
--The metaserver builds a list of available servers. ( available meaning, "broadcasted in last ten heartbeats" )
|
||||||
|
@ -83,7 +83,7 @@ local function prune( t )
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
||||||
print( "Starting Metaserver", socket.gettime() )
|
print( "Starting Metaserver", os.time(), udp:getsockname() )
|
||||||
function love.update()
|
function love.update()
|
||||||
read( udp:receivefrom() )
|
read( udp:receivefrom() )
|
||||||
prune( socket.gettime() )
|
prune( socket.gettime() )
|
||||||
|
|
|
@ -0,0 +1,2 @@
|
||||||
|
D:/dev/love/love.exe "./server/"
|
||||||
|
pause
|
|
@ -1,2 +1 @@
|
||||||
local socket = assert( require 'socket' )
|
return { ip = '142.162.167.92', port = 42069 }
|
||||||
return { ip = socket.dns.toip(socket.dns.gethostname()), port = 42069 }
|
|
Loading…
Reference in New Issue