diff --git a/Projects/Server/Mobiles/Mobile.cs b/Projects/Server/Mobiles/Mobile.cs index 0a98f00b4..588ce0cc9 100644 --- a/Projects/Server/Mobiles/Mobile.cs +++ b/Projects/Server/Mobiles/Mobile.cs @@ -8139,18 +8139,20 @@ public partial class Mobile : IHued, IComparable, ISpawnable, IObjectPro m_NetState.SendCloseGump(gump.TypeID, 0); m_NetState.RemoveGump(gump); gump.OnServerClose(m_NetState); + + return true; } - return true; + return false; } - public bool CloseAllGumps() + public void CloseAllGumps() { var ns = m_NetState; if (ns.CannotSendPackets()) { - return false; + return; } var gumps = new List(ns.Gumps); @@ -8164,10 +8166,10 @@ public partial class Mobile : IHued, IComparable, ISpawnable, IObjectPro gump.OnServerClose(ns); } - return true; + return; } - public bool HasGump() where T : BaseGump => FindGump() != null; + public bool HasGump() where T : BaseGump => m_NetState?.Gumps.Exists(g => g is T) ?? false; public bool SendGump(BaseGump g) {