mirror of
https://github.com/EQEmu/Server.git
synced 2026-05-28 13:55:46 +00:00
Compare commits
8 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 3e4767269e | |||
| e0eb145081 | |||
| a6dd65435f | |||
| 26dc05c0dc | |||
| da20a6ab67 | |||
| 3949a31246 | |||
| e898be1ce9 | |||
| 2962575dda |
@@ -1,3 +1,24 @@
|
||||
## [22.4.1] - 02/17/2023
|
||||
|
||||
### Bots
|
||||
|
||||
* Set Taunt to enabled for SK/Paladin Bots by Default. ([#2941](https://github.com/EQEmu/Server/pull/2941)) ([Aeadoin](https://github.com/Aeadoin)) 2023-02-17
|
||||
|
||||
### DevTools
|
||||
|
||||
* Fix NPC targetting dev tools display window ([#2943](https://github.com/EQEmu/Server/pull/2943)) ([Akkadius](https://github.com/Akkadius)) 2023-02-17
|
||||
|
||||
### Fixes
|
||||
|
||||
* Issue with AssignRaidToInstance that was using the groups repository instead of raid ([#2947](https://github.com/EQEmu/Server/pull/2947)) ([Akkadius](https://github.com/Akkadius)) 2023-02-17
|
||||
* Missing comma in schema list breaking dumps ([Akkadius](https://github.com/Akkadius)) 2023-02-17
|
||||
|
||||
### Player Events
|
||||
|
||||
* Fix issue with item instances not being validated properly before accessing causing crashes on handin ([#2945](https://github.com/EQEmu/Server/pull/2945)) ([Akkadius](https://github.com/Akkadius)) 2023-02-17
|
||||
* Fix rare out of bound issue when loading event types ([#2946](https://github.com/EQEmu/Server/pull/2946)) ([Akkadius](https://github.com/Akkadius)) 2023-02-17
|
||||
* Turn off KILLED_NPC (trash) off by default ([#2948](https://github.com/EQEmu/Server/pull/2948)) ([Akkadius](https://github.com/Akkadius)) 2023-02-17
|
||||
|
||||
## [22.4.0] - 02/17/2023
|
||||
|
||||
### Bots
|
||||
|
||||
@@ -409,7 +409,7 @@ void Database::AssignRaidToInstance(uint32 raid_id, uint32 instance_id)
|
||||
auto zone_id = GetInstanceZoneID(instance_id);
|
||||
auto version = GetInstanceVersion(instance_id);
|
||||
|
||||
auto l = GroupIdRepository::GetWhere(
|
||||
auto l = RaidMembersRepository::GetWhere(
|
||||
*this,
|
||||
fmt::format(
|
||||
"raidid = {}",
|
||||
|
||||
@@ -342,7 +342,7 @@ namespace DatabaseSchema {
|
||||
"saylink",
|
||||
"server_scheduled_events",
|
||||
"player_event_log_settings",
|
||||
"player_event_logs"
|
||||
"player_event_logs",
|
||||
"shared_task_activity_state",
|
||||
"shared_task_dynamic_zones",
|
||||
"shared_task_members",
|
||||
|
||||
@@ -30,6 +30,9 @@ void PlayerEventLogs::Init()
|
||||
std::vector<int> db{};
|
||||
db.reserve(s.size());
|
||||
for (auto &e: s) {
|
||||
if (e.id >= PlayerEvent::MAX) {
|
||||
continue;
|
||||
}
|
||||
m_settings[e.id] = e;
|
||||
db.emplace_back(e.id);
|
||||
}
|
||||
@@ -693,7 +696,7 @@ void PlayerEventLogs::SetSettingsDefaults()
|
||||
m_settings[PlayerEvent::BANDOLIER_SWAP].event_enabled = 0;
|
||||
m_settings[PlayerEvent::DISCOVER_ITEM].event_enabled = 1;
|
||||
m_settings[PlayerEvent::POSSIBLE_HACK].event_enabled = 1;
|
||||
m_settings[PlayerEvent::KILLED_NPC].event_enabled = 1;
|
||||
m_settings[PlayerEvent::KILLED_NPC].event_enabled = 0;
|
||||
m_settings[PlayerEvent::KILLED_NAMED_NPC].event_enabled = 1;
|
||||
m_settings[PlayerEvent::KILLED_RAID_NPC].event_enabled = 1;
|
||||
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
{
|
||||
"name": "eqemu-server",
|
||||
"version": "22.4.0",
|
||||
"version": "22.4.1",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/EQEmu/Server.git"
|
||||
|
||||
+1
-1
@@ -77,7 +77,7 @@ Bot::Bot(NPCType *npcTypeData, Client* botOwner) : NPC(npcTypeData, nullptr, glm
|
||||
SetBotCharmer(false);
|
||||
SetPetChooser(false);
|
||||
SetRangerAutoWeaponSelect(false);
|
||||
SetTaunting(GetClass() == WARRIOR);
|
||||
SetTaunting(GetClass() == WARRIOR || GetClass() == PALADIN || GetClass() == SHADOWKNIGHT);
|
||||
SetDefaultBotStance();
|
||||
|
||||
SetAltOutOfCombatBehavior(GetClass() == BARD); // will need to be updated if more classes make use of this flag
|
||||
|
||||
+4
-4
@@ -4261,6 +4261,10 @@ void Mob::SetTarget(Mob *mob)
|
||||
parse->BotHasQuestSub(EVENT_TARGET_CHANGE)
|
||||
);
|
||||
|
||||
if (IsClient() && CastToClient()->admin > AccountStatus::GMMgmt) {
|
||||
DisplayInfo(mob);
|
||||
}
|
||||
|
||||
if (has_target_change_event) {
|
||||
std::vector<std::any> args;
|
||||
|
||||
@@ -4275,10 +4279,6 @@ void Mob::SetTarget(Mob *mob)
|
||||
parse->EventPlayer(EVENT_TARGET_CHANGE, CastToClient(), "", 0, &args);
|
||||
}
|
||||
|
||||
if (CastToClient()->admin > AccountStatus::GMMgmt) {
|
||||
DisplayInfo(mob);
|
||||
}
|
||||
|
||||
CastToClient()->SetBotPrecombat(false); // Any change in target will nullify this flag (target == mob checked above)
|
||||
} else if (IsBot()) {
|
||||
if (parse->BotHasQuestSub(EVENT_TARGET_CHANGE)) {
|
||||
|
||||
+48
-42
@@ -4024,10 +4024,8 @@ void QuestManager::SendPlayerHandinEvent() {
|
||||
if (!handin_items.empty()) {
|
||||
if (Strings::Contains(handin_items, ",")) {
|
||||
const auto handin_data = Strings::Split(handin_items, ",");
|
||||
|
||||
for (const auto &h: handin_data) {
|
||||
const auto item_data = Strings::Split(h, "-");
|
||||
|
||||
const auto item_data = Strings::Split(h, "|");
|
||||
if (
|
||||
item_data.size() == 3 &&
|
||||
Strings::IsNumber(item_data[0]) &&
|
||||
@@ -4037,22 +4035,22 @@ void QuestManager::SendPlayerHandinEvent() {
|
||||
const auto item_id = static_cast<uint32>(std::stoul(item_data[0]));
|
||||
if (item_id != 0) {
|
||||
const auto *item = database.GetItem(item_id);
|
||||
|
||||
hi.emplace_back(
|
||||
PlayerEvent::HandinEntry{
|
||||
.item_id = item_id,
|
||||
.item_name = item->Name,
|
||||
.charges = static_cast<uint16>(std::stoul(item_data[1])),
|
||||
.attuned = std::stoi(item_data[2]) ? true : false
|
||||
}
|
||||
);
|
||||
if (item) {
|
||||
hi.emplace_back(
|
||||
PlayerEvent::HandinEntry{
|
||||
.item_id = item_id,
|
||||
.item_name = item->Name,
|
||||
.charges = static_cast<uint16>(std::stoul(item_data[1])),
|
||||
.attuned = std::stoi(item_data[2]) ? true : false
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (Strings::Contains(handin_items, "|")) {
|
||||
const auto item_data = Strings::Split(handin_items, "|");
|
||||
|
||||
if (
|
||||
item_data.size() == 3 &&
|
||||
Strings::IsNumber(item_data[0]) &&
|
||||
@@ -4061,15 +4059,16 @@ void QuestManager::SendPlayerHandinEvent() {
|
||||
) {
|
||||
const auto item_id = static_cast<uint32>(std::stoul(item_data[0]));
|
||||
const auto *item = database.GetItem(item_id);
|
||||
|
||||
hi.emplace_back(
|
||||
PlayerEvent::HandinEntry{
|
||||
.item_id = item_id,
|
||||
.item_name = item->Name,
|
||||
.charges = static_cast<uint16>(std::stoul(item_data[1])),
|
||||
.attuned = std::stoi(item_data[2]) ? true : false
|
||||
}
|
||||
);
|
||||
if (item) {
|
||||
hi.emplace_back(
|
||||
PlayerEvent::HandinEntry{
|
||||
.item_id = item_id,
|
||||
.item_name = item->Name,
|
||||
.charges = static_cast<uint16>(std::stoul(item_data[1])),
|
||||
.attuned = std::stoi(item_data[2]) ? true : false
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -4087,10 +4086,8 @@ void QuestManager::SendPlayerHandinEvent() {
|
||||
if (!return_items.empty()) {
|
||||
if (Strings::Contains(return_items, ",")) {
|
||||
const auto return_data = Strings::Split(return_items, ",");
|
||||
|
||||
for (const auto &r: return_data) {
|
||||
const auto item_data = Strings::Split(r, "|");
|
||||
|
||||
if (
|
||||
item_data.size() == 3 &&
|
||||
Strings::IsNumber(item_data[0]) &&
|
||||
@@ -4100,20 +4097,21 @@ void QuestManager::SendPlayerHandinEvent() {
|
||||
const auto item_id = static_cast<uint32>(std::stoul(item_data[0]));
|
||||
const auto *item = database.GetItem(item_id);
|
||||
|
||||
ri.emplace_back(
|
||||
PlayerEvent::HandinEntry{
|
||||
.item_id = item_id,
|
||||
.item_name = item->Name,
|
||||
.charges = static_cast<uint16>(std::stoul(item_data[1])),
|
||||
.attuned = std::stoi(item_data[2]) ? true : false
|
||||
}
|
||||
);
|
||||
if (item) {
|
||||
ri.emplace_back(
|
||||
PlayerEvent::HandinEntry{
|
||||
.item_id = item_id,
|
||||
.item_name = item->Name,
|
||||
.charges = static_cast<uint16>(std::stoul(item_data[1])),
|
||||
.attuned = std::stoi(item_data[2]) ? true : false
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (Strings::Contains(return_items, "|")) {
|
||||
const auto item_data = Strings::Split(return_items, "|");
|
||||
|
||||
if (
|
||||
item_data.size() == 3 &&
|
||||
Strings::IsNumber(item_data[0]) &&
|
||||
@@ -4123,14 +4121,16 @@ void QuestManager::SendPlayerHandinEvent() {
|
||||
const auto item_id = static_cast<uint32>(std::stoul(item_data[0]));
|
||||
const auto *item = database.GetItem(item_id);
|
||||
|
||||
ri.emplace_back(
|
||||
PlayerEvent::HandinEntry{
|
||||
.item_id = item_id,
|
||||
.item_name = item->Name,
|
||||
.charges = static_cast<uint16>(std::stoul(item_data[1])),
|
||||
.attuned = std::stoi(item_data[2]) ? true : false
|
||||
}
|
||||
);
|
||||
if (item) {
|
||||
ri.emplace_back(
|
||||
PlayerEvent::HandinEntry{
|
||||
.item_id = item_id,
|
||||
.item_name = item->Name,
|
||||
.charges = static_cast<uint16>(std::stoul(item_data[1])),
|
||||
.attuned = std::stoi(item_data[2]) ? true : false
|
||||
}
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -4149,7 +4149,13 @@ void QuestManager::SendPlayerHandinEvent() {
|
||||
initiator->DeleteEntityVariable("RETURN_ITEMS");
|
||||
initiator->DeleteEntityVariable("RETURN_MONEY");
|
||||
|
||||
if (player_event_logs.IsEventEnabled(PlayerEvent::NPC_HANDIN)) {
|
||||
bool handed_in_money = hm.platinum > 0 || hm.gold > 0 || hm.silver > 0 || hm.copper > 0;
|
||||
|
||||
bool event_has_data_to_record = (
|
||||
!hi.empty() || handed_in_money
|
||||
);
|
||||
|
||||
if (player_event_logs.IsEventEnabled(PlayerEvent::NPC_HANDIN) && event_has_data_to_record) {
|
||||
auto e = PlayerEvent::HandinEvent{
|
||||
.npc_id = owner->CastToNPC()->GetNPCTypeID(),
|
||||
.npc_name = owner->GetCleanName(),
|
||||
|
||||
Reference in New Issue
Block a user