hg b2d9de8d96
[Quests] Avoid Player and Bot quests in unloaded zone (#4232)
If a mob has a target when a zone is shutdown it will crash while trying
to dispatch EVENT_TARGET_CHANGE when the Mob destructor cleans up hatelists
if a quest interface isn't loaded for the type (in this case no bot scripts):

 	zone.exe!fmt::v10::format<std::string const &,char const *>(fmt::v10::basic_format_string<char,std::string const &,char const *> fmt={...}, const std::string & <args_0>={...}, const char * && <args_1>=0x0000000000000000) Line 2835	C++
>	zone.exe!QuestParserCollection::GetQIByBotQuest(std::string & filename={...}) Line 1138	C++
 	zone.exe!QuestParserCollection::BotHasQuestSubLocal(QuestEventID event_id=EVENT_TARGET_CHANGE) Line 353	C++
 	zone.exe!QuestParserCollection::BotHasQuestSub(QuestEventID event_id=EVENT_TARGET_CHANGE) Line 389	C++
 	zone.exe!Mob::SetTarget(Mob * mob=0x0000000000000000) Line 5431	C++
 	zone.exe!NPC::SetTarget(Mob * mob=0x0000000000000000) Line 575	C++
 	zone.exe!Mob::RemoveFromHateList(Mob * mob=0x000001bfbdc66040) Line 4894	C++
 	zone.exe!EntityList::RemoveFromTargets(Mob * mob=0x000001bfbdc66040, bool RemoveFromXTargets=true) Line 1530	C++
 	zone.exe!Mob::~Mob() Line 547	C++
 	zone.exe!NPC::~NPC() Line 537	C++
 	zone.exe!NPC::`scalar deleting destructor'(unsigned int)	C++
 	zone.exe!EntityList::RemoveAllMobs() Line 2678	C++
 	zone.exe!EntityList::Clear() Line 3090	C++
 	zone.exe!Zone::~Zone() Line 1103	C++
 	zone.exe!Zone::`scalar deleting destructor'(unsigned int)	C++
 	zone.exe!Zone::Shutdown(bool quiet=false) Line 928	C++

This is caused by the Zone destructor deleting short_name before calling
entity_list.Clear(). With an unloaded quest interface BotHasQuestSubLocal
calls GetQIByBotQuest which gets a null zone->GetShortName() and crashes
while formatting strings.

The immediate regressing commit for this crash is because a check for
zone->IsLoaded() was removed in 74f1eac4 with others that were removed
to fix a regression by #4025. GetQIByBotQuest and GetQIByPlayerQuest
always had this check and should have remained for them.

This restores the zone->IsLoaded() checks for GetQIByBotQuest/PlayerQuest.
The other functions cannot have that check added until the other issues
mentioned in #4149 are addressed.
2024-03-31 22:49:13 -05:00
2019-10-13 18:49:16 -07:00
2018-08-04 15:26:21 -04:00
2013-02-16 15:00:23 -08:00
2019-05-17 00:18:32 -07:00
2024-03-23 00:24:01 -05:00
2021-09-09 09:52:26 -05:00
2024-03-23 00:24:01 -05:00
2019-08-15 20:21:09 -05:00

EQEmulator Core Server

Drone (Linux x64) Drone (Windows x64)
Build Status Build Status

EQEmulator is a custom completely from-scratch open source server implementation for EverQuest built mostly on C++

  • MySQL/MariaDB is used as the database engine (over 200+ tables)
  • Perl and LUA are both supported scripting languages for NPC/Player/Quest oriented events
  • Open source database (Project EQ) has content up to expansion OoW (included in server installs)
  • Game server environments and databases can be heavily customized to create all new experiences
  • Hundreds of Quests/events created and maintained by Project EQ

Server Installs

Windows Linux
Install Count Windows Install Count Linux Install Count

> Windows

> Debian/Ubuntu/CentOS/Fedora

  • Install Guide

  • You can use curl or wget to kick off the installer (whichever your OS has)

curl -O https://raw.githubusercontent.com/EQEmu/Server/master/utils/scripts/linux_installer/install.sh install.sh && chmod 755 install.sh && ./install.sh

wget --no-check-certificate https://raw.githubusercontent.com/EQEmu/Server/master/utils/scripts/linux_installer/install.sh -O install.sh && chmod 755 install.sh && ./install.sh

Supported Clients

Titanium Edition Secrets of Faydwer Seeds of Destruction Underfoot Rain of Fear

Bug Reports

  • Please use the issue tracker provided by GitHub to send us bug reports or feature requests.
  • The EQEmu Forums are also a place to submit and get help with bugs.

Contributions

  • The preferred way to contribute is to fork the repo and submit a pull request on GitHub. If you need help with your changes, you can always post on the forums or try Discord. You can also post unified diffs (git diff should do the trick) on the Server Code Submissions forum, although pull requests will be much quicker and easier on all parties.

Contact

Resources

Other License Info

  • The server code and utilities are released under GPLv3
  • We also include some small libraries for convienence that may be under different licensing
    • SocketLib - GPL LibXML
    • zlib - zlib license
    • MariaDB/MySQL - GPL
    • GPL Perl - GPL / ActiveState (under the assumption that this is a free project)
    • CPPUnit - GLP StringUtilities - Apache
    • LUA - MIT

Contributors

Description
Languages
C++ 89.6%
C 6.4%
C# 2%
CMake 0.6%
Python 0.5%
Other 0.8%