This commit is contained in:
Akkadius
2015-11-30 00:09:03 -06:00
5 changed files with 30 additions and 9 deletions
+3
View File
@@ -1,5 +1,8 @@
EQEMu Changelog (Started on Sept 24, 2003 15:50)
-------------------------------------------------------
== 11/22/2015 ==
Uleat: Fix for loginserver project compile failure
== 11/7/2015 ==
Akkadius: Implemented #repopclose [distance in units] - Used for development purposes, defaults to 500 units
- Real case use: Large zones with 700 NPC's and you are making fast quick tweaks to nearby NPC's you can refresh just the NPC's around you instead of all in the zone
+1 -1
View File
@@ -43,7 +43,7 @@ ADD_EXECUTABLE(loginserver ${eqlogin_sources} ${eqlogin_headers})
INSTALL(TARGETS loginserver RUNTIME DESTINATION ${CMAKE_INSTALL_PREFIX})
TARGET_LINK_LIBRARIES(loginserver common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE})
TARGET_LINK_LIBRARIES(loginserver common debug ${MySQL_LIBRARY_DEBUG} optimized ${MySQL_LIBRARY_RELEASE} ${ZLIB_LIBRARY})
IF(MSVC)
SET_TARGET_PROPERTIES(loginserver PROPERTIES LINK_FLAGS_RELEASE "/OPT:REF /OPT:ICF")
-2
View File
@@ -26,8 +26,6 @@
extern ErrorLog *server_log;
extern LoginServer server;
#pragma comment(lib, "mysqlclient.lib")
DatabaseMySQL::DatabaseMySQL(string user, string pass, string host, string port, string name)
{
this->user = user;
+10
View File
@@ -2026,6 +2026,16 @@ void Bot::LoadPetBuffs(SpellBuff_Struct* petBuffs, uint32 botPetSaveId) {
petBuffs[buffIndex].spellid = atoi(row[0]);
petBuffs[buffIndex].level = atoi(row[1]);
petBuffs[buffIndex].duration = atoi(row[2]);
//Work around for loading the counters and setting them back to max. Need entry in DB for saved counters
if(CalculatePoisonCounters(petBuffs[buffIndex].spellid) > 0)
petBuffs[buffIndex].counters = CalculatePoisonCounters(petBuffs[buffIndex].spellid);
else if(CalculateDiseaseCounters(petBuffs[buffIndex].spellid) > 0)
petBuffs[buffIndex].counters = CalculateDiseaseCounters(petBuffs[buffIndex].spellid);
else if(CalculateCurseCounters(petBuffs[buffIndex].spellid) > 0)
petBuffs[buffIndex].counters = CalculateCurseCounters(petBuffs[buffIndex].spellid);
else if(CalculateCorruptionCounters(petBuffs[buffIndex].spellid) > 0)
petBuffs[buffIndex].counters = CalculateCorruptionCounters(petBuffs[buffIndex].spellid);
buffIndex++;
}
query = StringFormat("DELETE FROM `bot_pet_buffs` WHERE `pets_index` = %u;", botPetSaveId);
+16 -6
View File
@@ -468,17 +468,27 @@ void EntityList::CorpseProcess()
void EntityList::MobProcess()
{
#ifdef IDLE_WHEN_EMPTY
if (numclients < 1)
return;
#endif
bool mob_dead;
auto it = mob_list.begin();
while (it != mob_list.end()) {
uint16 id = it->first;
Mob *mob = it->second;
size_t sz = mob_list.size();
bool p_val = mob->Process();
#ifdef IDLE_WHEN_EMPTY
// spawn_events can cause spawns and deaths while zone empty.
// At the very least, process that.
if (numclients < 1) {
mob_dead = mob->CastToNPC()->GetDepop();
}
else {
mob_dead = !mob->Process();
}
#else
mob_dead = !mob->Process();
#endif
size_t a_sz = mob_list.size();
if(a_sz > sz) {
@@ -491,7 +501,7 @@ void EntityList::MobProcess()
++it;
}
if(!p_val) {
if(mob_dead) {
if(mob->IsNPC()) {
entity_list.RemoveNPC(id);
}