mirror of
https://github.com/DarkflameUniverse/DarkflameServer.git
synced 2025-12-22 04:30:24 +00:00
Optimize scripts for faster compilation (#597)
* Implement Precompiled Headers * First volume of optimizations * Scripts A-B Gonna be doing this in alphabetical order now. * C Scripts and remove unneeded includes from base cppscripts header Remove the MissionComponent and Loot includes from all base scripts and place their needed includes in the respective scripts. * D scripts * F scripts * F scripts 2 Finish up removing extraneous includes from scripts that start with the letter F * G scripts Removing extraneous includes from scripts that start with the letter G * I scripts Removing extraneous includes from scripts that start with the letter I * M-Z scripts Removing extraneous includes from scripts that start with the letter M-Z * Revert "Implement Precompiled Headers" This reverts commitd79d8d4991. * Revert "Revert "Implement Precompiled Headers"" This reverts commit0597faf308. * Add back in PCH Add back in PCH * Fix CMake Whitespace Remove duplicate file glob Remove newline
This commit is contained in:
@@ -11,8 +11,6 @@ void FvHorsemenTrigger::OnStartup(Entity* self)
|
||||
|
||||
void FvHorsemenTrigger::OnProximityUpdate(Entity* self, Entity* entering, std::string name, std::string status)
|
||||
{
|
||||
Game::logger->Log("FvHorsemenTrigger", "Proximity update\n");
|
||||
|
||||
if (name != "horsemenTrigger" || !entering->IsPlayer())
|
||||
{
|
||||
return;
|
||||
@@ -24,12 +22,10 @@ void FvHorsemenTrigger::OnProximityUpdate(Entity* self, Entity* entering, std::s
|
||||
|
||||
if (status == "ENTER" && iter == players.end())
|
||||
{
|
||||
Game::logger->Log("FvHorsemenTrigger", "Proximity enter\n");
|
||||
players.push_back(entering->GetObjectID());
|
||||
}
|
||||
else if (status == "LEAVE" && iter != players.end())
|
||||
{
|
||||
Game::logger->Log("FvHorsemenTrigger", "Proximity leave\n");
|
||||
players.erase(iter);
|
||||
}
|
||||
|
||||
@@ -42,7 +38,6 @@ FvHorsemenTrigger::OnFireEventServerSide(Entity *self, Entity *sender, std::stri
|
||||
{
|
||||
auto players = self->GetVar<std::vector<LWOOBJID>>(u"players");
|
||||
|
||||
Game::logger->Log("FvHorsemenTrigger", "Got event %s with %i players\n", args.c_str(), players.size());
|
||||
if (args == "HorsemenDeath")
|
||||
{
|
||||
for (const auto& playerId : self->GetVar<std::vector<LWOOBJID>>(u"players"))
|
||||
|
||||
Reference in New Issue
Block a user