Wincent's attempt at making LU into something it isn't supposed to be, an ARPG.
This commit is contained in:
wincent
2023-07-15 10:54:41 +02:00
parent 0d6bd33f9e
commit 5973430720
54 changed files with 2634 additions and 76 deletions

View File

@@ -7,5 +7,5 @@ add_library(dWorldServer ${DWORLDSERVER_SOURCES})
add_executable(WorldServer "WorldServer.cpp")
target_link_libraries(dWorldServer ${COMMON_LIBRARIES})
target_link_libraries(WorldServer ${COMMON_LIBRARIES} dChatFilter dGame dZoneManager dPhysics Detour Recast tinyxml2 dWorldServer dNavigation)
target_link_libraries(WorldServer ${COMMON_LIBRARIES} dChatFilter dGame dPhysics Detour Recast tinyxml2 dWorldServer dNavigation)

View File

@@ -71,6 +71,11 @@
#include "eMasterMessageType.h"
#include "eGameMessageType.h"
#include "ZCompression.h"
#include "InventoryComponent.h"
#include "DamageProfile.h"
#include "ResistanceProfile.h"
#include "SpawnPatterns.h"
#include "EntityProfile.h"
namespace Game {
dLogger* logger = nullptr;
@@ -147,6 +152,12 @@ int main(int argc, char** argv) {
Game::logger->Log("WorldServer", "Version: %i.%i", PROJECT_VERSION_MAJOR, PROJECT_VERSION_MINOR);
Game::logger->Log("WorldServer", "Compiled on: %s", __TIMESTAMP__);
ItemModifierTemplate::LoadItemModifierTemplates((BinaryPathFinder::GetBinaryDir() / "ItemModifierTemplates.xml").string());
DamageProfile::LoadDamageProfiles((BinaryPathFinder::GetBinaryDir() / "DamageProfiles.xml").string());
ResistanceProfile::LoadResistanceProfiles((BinaryPathFinder::GetBinaryDir() / "ResistanceProfiles.xml").string());
SpawnPatterns::LoadSpawnPatterns((BinaryPathFinder::GetBinaryDir() / "SpawnPatterns.xml").string());
EntityProfile::LoadEntityProfiles((BinaryPathFinder::GetBinaryDir() / "EntityProfiles.xml").string());
if (Game::config->GetValue("disable_chat") == "1") chatDisabled = true;
try {
@@ -489,6 +500,8 @@ int main(int argc, char** argv) {
framesSinceLastSQLPing = 0;
} else framesSinceLastSQLPing++;
Spawner::UpdateRatings(deltaTime);
Metrics::EndMeasurement(MetricVariable::GameLoop);
Metrics::StartMeasurement(MetricVariable::Sleep);
@@ -512,6 +525,12 @@ int main(int argc, char** argv) {
}
}
auto* controller = dZoneManager::Instance()->GetZoneControlObject();
if (controller != nullptr && controller->HasVar(u"shutdown") && controller->GetVar<bool>(u"shutdown")) {
Game::shouldShutdown = true;
}
if (Game::shouldShutdown && !worldShutdownSequenceComplete) {
WorldShutdownProcess(zoneID);
break;