mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 01:58:19 +00:00
Merge branch 'master' of http://github.com/oy/teeworlds
This commit is contained in:
commit
b6a4b2b7ba
|
@ -55,8 +55,13 @@ DuplicateDirectoryStructure("src", "src", "objs")
|
|||
|
||||
function ResCompile(scriptfile)
|
||||
scriptfile = Path(scriptfile)
|
||||
output = PathBase(scriptfile) .. ".res"
|
||||
AddJob(output, "rc " .. scriptfile, "rc /fo " .. output .. " " .. scriptfile)
|
||||
if config.compiler.driver == "cl" then
|
||||
output = PathBase(scriptfile) .. ".res"
|
||||
AddJob(output, "rc " .. scriptfile, "rc /fo " .. output .. " " .. scriptfile)
|
||||
elseif config.compiler.driver == "gcc" then
|
||||
output = PathBase(scriptfile) .. ".coff"
|
||||
AddJob(output, "windres " .. scriptfile, "windres -i " .. scriptfile .. " -o " .. output)
|
||||
end
|
||||
AddDependency(output, scriptfile)
|
||||
return output
|
||||
end
|
||||
|
@ -68,7 +73,7 @@ function Dat2c(datafile, sourcefile, arrayname)
|
|||
AddJob(
|
||||
sourcefile,
|
||||
"dat2c " .. PathFilename(sourcefile) .. " = " .. PathFilename(datafile),
|
||||
Script("scripts/safewrapper.py") .. " \"" .. Script("scripts/dat2c.py").. "\" " .. sourcefile .. " " .. datafile .. " " .. arrayname
|
||||
Script("scripts/dat2c.py").. "\" " .. sourcefile .. " " .. datafile .. " " .. arrayname
|
||||
)
|
||||
AddDependency(sourcefile, datafile)
|
||||
return sourcefile
|
||||
|
@ -79,7 +84,7 @@ function ContentCompile(action, output)
|
|||
AddJob(
|
||||
output,
|
||||
action .. " > " .. output,
|
||||
--Script("scripts/safewrapper.py") .. " \"" .. Script("datasrc/compile.py") .. "\" ".. Path(output) .. " " .. action
|
||||
--Script("datasrc/compile.py") .. "\" ".. Path(output) .. " " .. action
|
||||
Script("datasrc/compile.py") .. " " .. action .. " > " .. Path(output)
|
||||
)
|
||||
AddDependency(output, Path("datasrc/content.py")) -- do this more proper
|
||||
|
@ -111,8 +116,11 @@ if family == "windows" then
|
|||
end
|
||||
|
||||
|
||||
if config.compiler.driver == "cl" then
|
||||
client_link_other = {ResCompile("other/icons/teeworlds.rc")}
|
||||
if config.compiler.driver == "cl" then
|
||||
client_link_other = {ResCompile("other/icons/teeworlds_cl.rc")}
|
||||
elseif config.compiler.driver == "gcc" then
|
||||
client_link_other = {ResCompile("other/icons/teeworlds_gcc.rc")}
|
||||
end
|
||||
end
|
||||
|
||||
function Intermediate_Output(settings, input)
|
||||
|
|
20
bam.lua
20
bam.lua
|
@ -55,8 +55,13 @@ DuplicateDirectoryStructure("src", "src", "objs")
|
|||
|
||||
function ResCompile(scriptfile)
|
||||
scriptfile = Path(scriptfile)
|
||||
output = PathBase(scriptfile) .. ".res"
|
||||
AddJob(output, "rc " .. scriptfile, "rc /fo " .. output .. " " .. scriptfile)
|
||||
if config.compiler.driver == "cl" then
|
||||
output = PathBase(scriptfile) .. ".res"
|
||||
AddJob(output, "rc " .. scriptfile, "rc /fo " .. output .. " " .. scriptfile)
|
||||
elseif config.compiler.driver == "gcc" then
|
||||
output = PathBase(scriptfile) .. ".coff"
|
||||
AddJob(output, "windres " .. scriptfile, "windres -i " .. scriptfile .. " -o " .. output)
|
||||
end
|
||||
AddDependency(output, scriptfile)
|
||||
return output
|
||||
end
|
||||
|
@ -68,7 +73,7 @@ function Dat2c(datafile, sourcefile, arrayname)
|
|||
AddJob(
|
||||
sourcefile,
|
||||
"dat2c " .. PathFilename(sourcefile) .. " = " .. PathFilename(datafile),
|
||||
Script("scripts/safewrapper.py") .. " \"" .. Script("scripts/dat2c.py").. "\" " .. sourcefile .. " " .. datafile .. " " .. arrayname
|
||||
Script("scripts/dat2c.py").. "\" " .. sourcefile .. " " .. datafile .. " " .. arrayname
|
||||
)
|
||||
AddDependency(sourcefile, datafile)
|
||||
return sourcefile
|
||||
|
@ -79,7 +84,7 @@ function ContentCompile(action, output)
|
|||
AddJob(
|
||||
output,
|
||||
action .. " > " .. output,
|
||||
--Script("scripts/safewrapper.py") .. " \"" .. Script("datasrc/compile.py") .. "\" ".. Path(output) .. " " .. action
|
||||
--Script("datasrc/compile.py") .. "\" ".. Path(output) .. " " .. action
|
||||
Script("datasrc/compile.py") .. " " .. action .. " > " .. Path(output)
|
||||
)
|
||||
AddDependency(output, Path("datasrc/content.py")) -- do this more proper
|
||||
|
@ -114,8 +119,11 @@ if family == "windows" then
|
|||
end
|
||||
|
||||
|
||||
if config.compiler.driver == "cl" then
|
||||
client_link_other = {ResCompile("other/icons/teeworlds.rc")}
|
||||
if config.compiler.driver == "cl" then
|
||||
client_link_other = {ResCompile("other/icons/teeworlds_cl.rc")}
|
||||
elseif config.compiler.driver == "gcc" then
|
||||
client_link_other = {ResCompile("other/icons/teeworlds_gcc.rc")}
|
||||
end
|
||||
end
|
||||
|
||||
function Intermediate_Output(settings, input)
|
||||
|
|
1
other/icons/teeworlds_gcc.rc
Normal file
1
other/icons/teeworlds_gcc.rc
Normal file
|
@ -0,0 +1 @@
|
|||
ID ICON "teeworlds.ico"
|
|
@ -37,7 +37,6 @@
|
|||
#include <windows.h>
|
||||
#include <winsock2.h>
|
||||
#include <ws2tcpip.h>
|
||||
#include <wspiapi.h>
|
||||
#include <fcntl.h>
|
||||
#include <direct.h>
|
||||
#include <errno.h>
|
||||
|
|
|
@ -660,7 +660,7 @@ void IGameController::Tick()
|
|||
{
|
||||
for(int i = 0; i < MAX_CLIENTS; ++i)
|
||||
{
|
||||
if(GameServer()->m_apPlayers[i] && GameServer()->m_apPlayers[i]->GetTeam() != -1)
|
||||
if(GameServer()->m_apPlayers[i] && GameServer()->m_apPlayers[i]->GetTeam() != -1 && !Server()->IsAuthed(i))
|
||||
{
|
||||
if(Server()->Tick() > GameServer()->m_apPlayers[i]->m_LastActionTick+g_Config.m_SvInactiveKickTime*Server()->TickSpeed()*60)
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue