Skip to content
This repository has been archived by the owner on Jun 26, 2019. It is now read-only.

Commit

Permalink
Remove sound
Browse files Browse the repository at this point in the history
  • Loading branch information
ChillerDragon committed Dec 3, 2018
1 parent 520d300 commit 26c99b4
Show file tree
Hide file tree
Showing 12 changed files with 3 additions and 776 deletions.
12 changes: 0 additions & 12 deletions src/engine/client/client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include <engine/map.h>
#include <engine/masterserver.h>
#include <engine/serverbrowser.h>
#include <engine/sound.h>
#include <engine/storage.h>

#include <engine/shared/config.h>
Expand Down Expand Up @@ -187,7 +186,6 @@ CClient::CClient() : m_DemoPlayer(&m_SnapshotDelta), m_DemoRecorder(&m_SnapshotD
m_pEditor = 0;
m_pInput = 0;
m_pGraphics = 0;
m_pSound = 0;
m_pGameClient = 0;
m_pMap = 0;
m_pConsole = 0;
Expand Down Expand Up @@ -1566,8 +1564,6 @@ void CClient::InitInterfaces()
// fetch interfaces
m_pEngine = Kernel()->RequestInterface<IEngine>();
m_pEditor = Kernel()->RequestInterface<IEditor>();
//m_pGraphics = Kernel()->RequestInterface<IEngineGraphics>();
m_pSound = Kernel()->RequestInterface<IEngineSound>();
m_pGameClient = Kernel()->RequestInterface<IGameClient>();
m_pInput = Kernel()->RequestInterface<IEngineInput>();
m_pMap = Kernel()->RequestInterface<IEngineMap>();
Expand Down Expand Up @@ -1758,8 +1754,6 @@ void CClient::Run()
if(Input()->Update())
break; // SDL_QUIT

// update sound
Sound()->Update();

// release focus
if(!m_pGraphics->WindowActive())
Expand Down Expand Up @@ -1849,7 +1843,6 @@ void CClient::Run()
Disconnect();

m_pGraphics->Shutdown();
m_pSound->Shutdown();

m_ServerBrowser.SaveServerlist();

Expand Down Expand Up @@ -2260,7 +2253,6 @@ int main(int argc, const char **argv) // ignore_convention
IConsole *pConsole = CreateConsole(FlagMask);
IStorage *pStorage = CreateStorage("Teeworlds", IStorage::STORAGETYPE_CLIENT, argc, argv); // ignore_convention
IConfig *pConfig = CreateConfig();
IEngineSound *pEngineSound = CreateEngineSound();
IEngineInput *pEngineInput = CreateEngineInput();
IEngineMap *pEngineMap = CreateEngineMap();
IEngineMasterServer *pEngineMasterServer = CreateEngineMasterServer();
Expand All @@ -2272,9 +2264,6 @@ int main(int argc, const char **argv) // ignore_convention
RegisterFail = RegisterFail || !pKernel->RegisterInterface(pConsole);
RegisterFail = RegisterFail || !pKernel->RegisterInterface(pConfig);

RegisterFail = RegisterFail || !pKernel->RegisterInterface(static_cast<IEngineSound*>(pEngineSound)); // register as both
RegisterFail = RegisterFail || !pKernel->RegisterInterface(static_cast<ISound*>(pEngineSound));

RegisterFail = RegisterFail || !pKernel->RegisterInterface(static_cast<IEngineInput*>(pEngineInput)); // register as both
RegisterFail = RegisterFail || !pKernel->RegisterInterface(static_cast<IInput*>(pEngineInput));

Expand Down Expand Up @@ -2354,7 +2343,6 @@ int main(int argc, const char **argv) // ignore_convention
delete pConsole;
delete pStorage;
delete pConfig;
delete pEngineSound;
delete pEngineInput;
delete pEngineMap;
delete pEngineMasterServer;
Expand Down
2 changes: 0 additions & 2 deletions src/engine/client/client.h
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,6 @@ class CClient : public IClient, public CDemoPlayer::IListner
IEditor *m_pEditor;
IEngineInput *m_pInput;
IEngineGraphics *m_pGraphics;
IEngineSound *m_pSound;
IGameClient *m_pGameClient;
IEngineMap *m_pMap;
IConsole *m_pConsole;
Expand Down Expand Up @@ -186,7 +185,6 @@ class CClient : public IClient, public CDemoPlayer::IListner
IEngine *Engine() { return m_pEngine; }
IEngineGraphics *Graphics() { return m_pGraphics; }
IEngineInput *Input() { return m_pInput; }
IEngineSound *Sound() { return m_pSound; }
IGameClient *GameClient() { return m_pGameClient; }
IEngineMasterServer *MasterServer() { return m_pMasterServer; }
IStorage *Storage() { return m_pStorage; }
Expand Down
Loading

0 comments on commit 26c99b4

Please sign in to comment.