From 5986d314c740b60987053c11ddd5a42f3a807c11 Mon Sep 17 00:00:00 2001 From: James Huston Date: Sun, 12 Jan 2025 18:22:35 -0500 Subject: [PATCH] Updates to work with latest acore source --- src/MpDataStore.cpp | 5 +++-- src/PlayerScript.cpp | 2 +- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/src/MpDataStore.cpp b/src/MpDataStore.cpp index 5ebbfec..10437c7 100644 --- a/src/MpDataStore.cpp +++ b/src/MpDataStore.cpp @@ -2,6 +2,7 @@ #include "MpDataStore.h" #include "Group.h" #include "MpLogger.h" +#include "Chat.h" // Adds an entry for the group difficult to memory and updats database void MpDataStore::AddGroupData(Group *group, MpGroupData groupData) { @@ -55,7 +56,7 @@ void MpDataStore::AddGroupData(Group *group, MpGroupData groupData) { MpLogger::error("AddGroupData called with null player in instance"); } - player->GetSession()->SendNotification("The group leader has changed the difficulty setting. You have been removed from the instance."); + ChatHandler(player->GetSession()).SendNotification("The group leader has changed the difficulty setting. You have been removed from the instance."); } } @@ -77,7 +78,7 @@ void MpDataStore::AddGroupData(Group *group, MpGroupData groupData) { MpLogger::error("AddGroupData called with null player in instance"); } - player->GetSession()->SendNotification("The group leader has changed the difficulty setting. You have been removed from the instance."); + ChatHandler(player->GetSession()).SendNotification("The group leader has changed the difficulty setting. You have been removed from the instance."); } } diff --git a/src/PlayerScript.cpp b/src/PlayerScript.cpp index 6fb5a12..cd38b3b 100644 --- a/src/PlayerScript.cpp +++ b/src/PlayerScript.cpp @@ -65,7 +65,7 @@ public: for(auto it = players.begin(); it != players.end(); ++it) { Player* player = it->GetSource(); - player->GetSession()->SendNotification("Your group has died too many time to continue. %u", totalDeaths); + ChatHandler(player->GetSession()).PSendSysMessage("Your group has died too many time to continue. %u", totalDeaths); } map->RemoveAllPlayers(); map->ToInstanceMap()->Reset(0);