From d0c11770a8a8c287d01de41102741c51a821370a Mon Sep 17 00:00:00 2001 From: Zach Toogood Date: Sat, 1 Feb 2025 14:18:07 +0000 Subject: [PATCH] Add note about Moghouse visit client limitation --- scripts/globals/moghouse.lua | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/scripts/globals/moghouse.lua b/scripts/globals/moghouse.lua index 677bd65c3bb..ee07a5de496 100644 --- a/scripts/globals/moghouse.lua +++ b/scripts/globals/moghouse.lua @@ -169,20 +169,27 @@ xi.moghouse.trySetMusic = function(player) end xi.moghouse.visitationNPCOnTrigger = function(player, npc, csid, ahtUrhganArg) + if player:getPartySize() > 1 then + for _, member in ipairs(player:getParty()) do + if member:getID() == 1 and member:isInMogHouse() then + player:printToPlayer(string.format("Client limitation: Players with ID 1 (%s) seemingly cannot be visited in their Mog House", member:getName()), xi.msg.channel.SYSTEM_3, '') + end + end + end + player:startEvent(csid, player:getNation(), ahtUrhganArg) end xi.moghouse.visitationNPCOnEventFinish = function(player, csid, option, visitationCSID) - if csid ~= visitationCSID then + if option == 0 or option == utils.EVENT_CANCELLED_OPTION then return end - if player:getPartySize() < 2 then + if csid ~= visitationCSID then return end - -- TODO: Does this support alliance? - if option < 1 or option > 6 then + if player:getPartySize() < 2 then return end