1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-06 09:09:40 +02:00

Merge pull request #3100 from IvanSavenko/split_net_packs

Split netpacks.h into multiple files
This commit is contained in:
Ivan Savenko
2023-10-29 13:46:40 +02:00
committed by GitHub
156 changed files with 3497 additions and 3221 deletions

View File

@@ -73,8 +73,6 @@
#include "../lib/CondSh.h"
#include "../lib/GameConstants.h"
#include "../lib/JsonNode.h"
#include "../lib/NetPacks.h" //todo: remove
#include "../lib/NetPacksBase.h"
#include "../lib/RoadHandler.h"
#include "../lib/StartInfo.h"
#include "../lib/TerrainHandler.h"
@@ -95,6 +93,10 @@
#include "../lib/mapping/CMapHeader.h"
#include "../lib/networkPacks/PacksForClient.h"
#include "../lib/networkPacks/PacksForClientBattle.h"
#include "../lib/networkPacks/PacksForServer.h"
#include "../lib/pathfinder/CGPathNode.h"
#include "../lib/serializer/BinaryDeserializer.h"

View File

@@ -38,7 +38,6 @@
#include "../lib/CConfigHandler.h"
#include "../lib/CGeneralTextHandler.h"
#include "../lib/CThreadHelper.h"
#include "../lib/NetPackVisitor.h"
#include "../lib/StartInfo.h"
#include "../lib/TurnTimerInfo.h"
#include "../lib/VCMIDirs.h"

View File

@@ -18,7 +18,6 @@
#include "gui/CGuiHandler.h"
#include "gui/WindowHandler.h"
#include "render/IRenderHandler.h"
#include "../lib/NetPacks.h"
#include "ClientNetPackVisitors.h"
#include "../lib/CConfigHandler.h"
#include "../lib/gameState/CGameState.h"
@@ -28,6 +27,7 @@
#include "../lib/mapping/CMapService.h"
#include "../lib/mapping/CMap.h"
#include "windows/CCastleInterface.h"
#include "../lib/mapObjects/CGHeroInstance.h"
#include "render/CAnimation.h"
#include "../CCallback.h"
#include "../lib/CGeneralTextHandler.h"

View File

@@ -9,7 +9,7 @@
*/
#pragma once
#include "../lib/NetPackVisitor.h"
#include "../lib/networkPacks/NetPackVisitor.h"
class CClient;

View File

@@ -24,9 +24,9 @@
#include "../lib/pathfinder/CGPathNode.h"
#include "../lib/mapObjects/CGHeroInstance.h"
#include "../lib/networkPacks/PacksForClient.h"
#include "../lib/RoadHandler.h"
#include "../lib/TerrainHandler.h"
#include "../lib/NetPacks.h"
bool HeroMovementController::isHeroMovingThroughGarrison(const CGHeroInstance * hero, const CArmedInstance * garrison) const
{

View File

@@ -9,9 +9,11 @@
*/
#pragma once
#include "../lib/NetPackVisitor.h"
#include "../lib/networkPacks/NetPackVisitor.h"
#include "../lib/networkPacks/PacksForLobby.h"
class CClient;
class CLobbyScreen;
VCMI_LIB_NAMESPACE_BEGIN
class CGameState;
VCMI_LIB_NAMESPACE_END

View File

@@ -27,7 +27,6 @@
#include "../lib/CConfigHandler.h"
#include "../lib/CGeneralTextHandler.h"
#include "../lib/NetPacksLobby.h"
#include "../lib/serializer/Connection.h"
void ApplyOnLobbyHandlerNetPackVisitor::visitLobbyClientConnected(LobbyClientConnected & pack)

View File

@@ -12,6 +12,7 @@
#include "../gui/CIntObject.h"
#include "CConfigHandler.h"
#include "../../lib/filesystem/ResourcePath.h"
#include "../../lib/networkPacks/Component.h"
VCMI_LIB_NAMESPACE_BEGIN

View File

@@ -28,7 +28,7 @@
#include "../../CCallback.h"
#include "../../lib/battle/BattleAction.h"
#include "../../lib/filesystem/ResourcePath.h"
#include "../../lib/NetPacks.h"
#include "../../lib/networkPacks/PacksForClientBattle.h"
#include "../../lib/CStack.h"
#include "../../lib/IGameEventsReceiver.h"
#include "../../lib/CGeneralTextHandler.h"

View File

@@ -40,7 +40,7 @@
#include "../../lib/CondSh.h"
#include "../../lib/gameState/InfoAboutArmy.h"
#include "../../lib/mapObjects/CGTownInstance.h"
#include "../../lib/NetPacks.h"
#include "../../lib/networkPacks/PacksForClientBattle.h"
#include "../../lib/UnlockGuard.h"
#include "../../lib/TerrainHandler.h"
#include "../../lib/CThreadHelper.h"

View File

@@ -48,10 +48,10 @@
#include "../../lib/CGeneralTextHandler.h"
#include "../../lib/CTownHandler.h"
#include "../../lib/CHeroHandler.h"
#include "../../lib/NetPacks.h"
#include "../../lib/StartInfo.h"
#include "../../lib/CondSh.h"
#include "../../lib/mapObjects/CGTownInstance.h"
#include "../../lib/networkPacks/PacksForClientBattle.h"
#include "../../lib/TextOperations.h"
void BattleConsole::showAll(Canvas & to)

View File

@@ -26,9 +26,9 @@
#include "../render/IRenderHandler.h"
#include "../../CCallback.h"
#include "../../lib/NetPacks.h"
#include "../../lib/CStack.h"
#include "../../lib/mapObjects/CGTownInstance.h"
#include "../../lib/networkPacks/PacksForClientBattle.h"
ImagePath BattleSiegeController::getWallPieceImageName(EWallVisual::EWallVisual what, EWallState state) const
{

View File

@@ -25,7 +25,7 @@
#include "../../CCallback.h"
#include "../CGameInfo.h"
#include "../../lib/NetPacksLobby.h"
#include "../../lib/networkPacks/PacksForLobby.h"
#include "../../lib/CGeneralTextHandler.h"
#include "../../lib/campaign/CampaignHandler.h"
#include "../../lib/mapping/CMapInfo.h"

View File

@@ -41,7 +41,6 @@
#include "../render/IFont.h"
#include "../render/IRenderHandler.h"
#include "../../lib/NetPacksLobby.h"
#include "../../lib/CGeneralTextHandler.h"
#include "../../lib/CHeroHandler.h"
#include "../../lib/CThreadHelper.h"

View File

@@ -34,7 +34,7 @@
#include "../eventsSDL/InputHandler.h"
#include "../../lib/filesystem/Filesystem.h"
#include "../../lib/NetPacksLobby.h"
#include "../../lib/networkPacks/PacksForLobby.h"
#include "../../lib/CGeneralTextHandler.h"
#include "../../lib/CArtHandler.h"
#include "../../lib/CTownHandler.h"

View File

@@ -34,7 +34,6 @@
#include "../../CCallback.h"
#include "../../lib/NetPacksLobby.h"
#include "../../lib/CGeneralTextHandler.h"
#include "../../lib/CConfigHandler.h"
#include "../../lib/GameSettings.h"

View File

@@ -51,7 +51,6 @@
#include "../../lib/mapping/CMapInfo.h"
#include "../../lib/VCMIDirs.h"
#include "../../lib/CStopWatch.h"
#include "../../lib/NetPacksLobby.h"
#include "../../lib/CThreadHelper.h"
#include "../../lib/CConfigHandler.h"
#include "../../lib/GameConstants.h"

View File

@@ -26,6 +26,7 @@
#include "../../lib/CGeneralTextHandler.h"
#include "../../lib/ArtifactUtils.h"
#include "../../lib/mapObjects/CGHeroInstance.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
#include "../../lib/CConfigHandler.h"
void CArtPlace::setInternals(const CArtifactInstance * artInst)

View File

@@ -16,6 +16,7 @@
#include "../../lib/ArtifactUtils.h"
#include "../../lib/mapObjects/CGHeroInstance.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
CArtifactsOfHeroAltar::CArtifactsOfHeroAltar(const Point & position)
: visibleArtSet(ArtBearer::ArtBearer::HERO)
@@ -109,4 +110,4 @@ void CArtifactsOfHeroAltar::deleteFromVisible(const CArtifactInstance * artInst)
getArtPlace(part.slot)->setArtifact(nullptr);
}
}
}
}

View File

@@ -18,6 +18,7 @@
#include "../CPlayerInterface.h"
#include "../../lib/mapObjects/CGHeroInstance.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
#include "../../CCallback.h"

View File

@@ -22,6 +22,7 @@
#include "../../lib/ArtifactUtils.h"
#include "../../lib/mapObjects/CGHeroInstance.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
CArtifactsOfHeroBase::CArtifactsOfHeroBase()
: backpackPos(0),

View File

@@ -15,6 +15,7 @@
#include "../CPlayerInterface.h"
#include "../../CCallback.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
CArtifactsOfHeroKingdom::CArtifactsOfHeroKingdom(ArtPlaceMap ArtWorn, std::vector<ArtPlacePtr> Backpack,
std::shared_ptr<CButton> leftScroll, std::shared_ptr<CButton> rightScroll)

View File

@@ -13,6 +13,7 @@
#include "../CPlayerInterface.h"
#include "../../CCallback.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
CArtifactsOfHeroMain::CArtifactsOfHeroMain(const Point & position)
{
@@ -37,4 +38,4 @@ void CArtifactsOfHeroMain::pickUpArtifact(CHeroArtPlace & artPlace)
{
LOCPLINT->cb->swapArtifacts(ArtifactLocation(curHero, artPlace.slot),
ArtifactLocation(curHero, ArtifactPosition::TRANSITION_POS));
}
}

View File

@@ -31,11 +31,11 @@
#include "../../lib/ArtifactUtils.h"
#include "../../lib/CTownHandler.h"
#include "../../lib/CHeroHandler.h"
#include "../../lib/networkPacks/Component.h"
#include "../../lib/spells/CSpellHandler.h"
#include "../../lib/CCreatureHandler.h"
#include "../../lib/CSkillHandler.h"
#include "../../lib/CGeneralTextHandler.h"
#include "../../lib/NetPacksBase.h"
#include "../../lib/CArtHandler.h"
#include "../../lib/CArtifactInstance.h"

View File

@@ -30,6 +30,7 @@
#include "../../lib/CCreatureHandler.h"
#include "../../lib/CConfigHandler.h"
#include "../../lib/mapObjects/CGHeroInstance.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
#include "../../lib/TextOperations.h"
#include "../../lib/gameState/CGameState.h"

View File

@@ -29,6 +29,7 @@
#include "../../lib/ArtifactUtils.h"
#include "../../lib/CGeneralTextHandler.h"
#include "../../lib/mapObjects/CGHeroInstance.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
#include "../../lib/CConfigHandler.h"
void CWindowWithArtifacts::addSet(CArtifactsOfHeroPtr artSet)

View File

@@ -33,6 +33,7 @@
#include "../../lib/GameSettings.h"
#include "../../lib/CHeroHandler.h"
#include "../../lib/gameState/CGameState.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
#include "../../lib/TextOperations.h"
class CCreatureArtifactInstance;

View File

@@ -39,7 +39,7 @@
#include "../lib/CHeroHandler.h"
#include "../lib/CSkillHandler.h"
#include "../lib/mapObjects/CGHeroInstance.h"
#include "../lib/NetPacksBase.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
void CHeroSwitcher::clickPressed(const Point & cursorPosition)
{

View File

@@ -35,6 +35,7 @@
#include "../../lib/mapObjects/CGHeroInstance.h"
#include "../../lib/mapObjects/CGTownInstance.h"
#include "../../lib/mapObjects/CGMarket.h"
#include "../../lib/networkPacks/ArtifactLocation.h"
CTradeWindow::CTradeableItem::CTradeableItem(Point pos, EType Type, int ID, bool Left, int Serial)
: CIntObject(LCLICK | HOVER | SHOW_POPUP, pos),