mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-19 22:48:18 +00:00
Merge branch 'master' of git://github.com/oy/teeworlds into DDRace
Conflicts: readme.txt
This commit is contained in:
commit
420447dc51
|
@ -1,4 +1,4 @@
|
||||||
Copyright (C) 2007-2011 Magnus Auvinen
|
Copyright (C) 2007-2012 Magnus Auvinen
|
||||||
|
|
||||||
This software is provided 'as-is', without any express or implied
|
This software is provided 'as-is', without any express or implied
|
||||||
warranty. In no event will the authors be held liable for any damages
|
warranty. In no event will the authors be held liable for any damages
|
||||||
|
@ -25,4 +25,4 @@ check the individual libraries.
|
||||||
------------------------------------------------------------------------
|
------------------------------------------------------------------------
|
||||||
|
|
||||||
With that being said, contact us if there is anything you want to do
|
With that being said, contact us if there is anything you want to do
|
||||||
that the license does not premit.
|
that the license does not permit.
|
||||||
|
|
|
@ -6,7 +6,7 @@ Please visit http://www.DDRace.info for up-to-date information about
|
||||||
DDRace, including new versions, custom maps and much more.
|
DDRace, including new versions, custom maps and much more.
|
||||||
|
|
||||||
Teeworlds README is as follows:
|
Teeworlds README is as follows:
|
||||||
Copyright (c) 2011 Magnus Auvinen
|
Copyright (c) 2012 Magnus Auvinen
|
||||||
|
|
||||||
|
|
||||||
This software is provided 'as-is', without any express or implied
|
This software is provided 'as-is', without any express or implied
|
||||||
|
|
|
@ -290,6 +290,9 @@ void CCommandProcessorFragment_SDL::Cmd_Shutdown(const SCommand_Shutdown *pComma
|
||||||
void CCommandProcessorFragment_SDL::Cmd_Swap(const CCommandBuffer::SCommand_Swap *pCommand)
|
void CCommandProcessorFragment_SDL::Cmd_Swap(const CCommandBuffer::SCommand_Swap *pCommand)
|
||||||
{
|
{
|
||||||
GL_SwapBuffers(m_GLContext);
|
GL_SwapBuffers(m_GLContext);
|
||||||
|
|
||||||
|
if(pCommand->m_Finish)
|
||||||
|
glFinish();
|
||||||
}
|
}
|
||||||
|
|
||||||
void CCommandProcessorFragment_SDL::Cmd_VideoModes(const CCommandBuffer::SCommand_VideoModes *pCommand)
|
void CCommandProcessorFragment_SDL::Cmd_VideoModes(const CCommandBuffer::SCommand_VideoModes *pCommand)
|
||||||
|
|
|
@ -1760,7 +1760,7 @@ void CClient::Run()
|
||||||
MasterServer()->RefreshAddresses(m_NetClient.NetType());
|
MasterServer()->RefreshAddresses(m_NetClient.NetType());
|
||||||
|
|
||||||
// init the editor
|
// init the editor
|
||||||
//m_pEditor->Init();
|
m_pEditor->Init();
|
||||||
|
|
||||||
|
|
||||||
// load data
|
// load data
|
||||||
|
@ -1862,22 +1862,16 @@ void CClient::Run()
|
||||||
*/
|
*/
|
||||||
|
|
||||||
// render
|
// render
|
||||||
if(g_Config.m_ClEditor)
|
|
||||||
{
|
{
|
||||||
if(!m_EditorActive)
|
if(g_Config.m_ClEditor)
|
||||||
{
|
{
|
||||||
GameClient()->OnActivateEditor();
|
if(!m_EditorActive)
|
||||||
m_EditorActive = true;
|
{
|
||||||
|
GameClient()->OnActivateEditor();
|
||||||
|
m_EditorActive = true;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
else if(m_EditorActive)
|
||||||
Update();
|
|
||||||
m_pEditor->UpdateAndRender();
|
|
||||||
DebugRender();
|
|
||||||
m_pGraphics->Swap();
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
if(m_EditorActive)
|
|
||||||
m_EditorActive = false;
|
m_EditorActive = false;
|
||||||
|
|
||||||
Update();
|
Update();
|
||||||
|
@ -1901,18 +1895,27 @@ void CClient::Run()
|
||||||
{
|
{
|
||||||
if((m_RenderFrames%10) == 0)
|
if((m_RenderFrames%10) == 0)
|
||||||
{
|
{
|
||||||
Render();
|
if(!m_EditorActive)
|
||||||
|
Render();
|
||||||
|
else
|
||||||
|
{
|
||||||
|
m_pEditor->UpdateAndRender();
|
||||||
|
DebugRender();
|
||||||
|
}
|
||||||
m_pGraphics->Swap();
|
m_pGraphics->Swap();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
Render();
|
if(!m_EditorActive)
|
||||||
|
Render();
|
||||||
|
else
|
||||||
|
{
|
||||||
|
m_pEditor->UpdateAndRender();
|
||||||
|
DebugRender();
|
||||||
|
}
|
||||||
m_pGraphics->Swap();
|
m_pGraphics->Swap();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -837,6 +837,7 @@ void CGraphics_Threaded::Swap()
|
||||||
|
|
||||||
// add swap command
|
// add swap command
|
||||||
CCommandBuffer::SCommand_Swap Cmd;
|
CCommandBuffer::SCommand_Swap Cmd;
|
||||||
|
Cmd.m_Finish = g_Config.m_GfxFinish;
|
||||||
m_pCommandBuffer->AddCommand(Cmd);
|
m_pCommandBuffer->AddCommand(Cmd);
|
||||||
|
|
||||||
// kick the command buffer
|
// kick the command buffer
|
||||||
|
|
|
@ -199,6 +199,8 @@ public:
|
||||||
struct SCommand_Swap : public SCommand
|
struct SCommand_Swap : public SCommand
|
||||||
{
|
{
|
||||||
SCommand_Swap() : SCommand(CMD_SWAP) {}
|
SCommand_Swap() : SCommand(CMD_SWAP) {}
|
||||||
|
|
||||||
|
int m_Finish;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct SCommand_Texture_Create : public SCommand
|
struct SCommand_Texture_Create : public SCommand
|
||||||
|
|
Loading…
Reference in a new issue