From db5050d5dbc0525d05837f728bea52f7954286cc Mon Sep 17 00:00:00 2001 From: fusion32 Date: Sat, 25 Jul 2026 09:18:09 -0300 Subject: adjustment to last commit Increasing the search radii for `CloseContainer` from (12, 10) to (14, 12) prevented players from exploiting the issue alone but it could still be leveraged when there was another player involved. In this case, you have another 2 SQM on both sides that need to be accounted for, so using (16, 14) should prevent it as well. And it may be a coincidence, but pretty much all other searches use these values, so I'm not sure what to make of it. They might be related? --- src/map.hh | 2 +- src/operate.cc | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/map.hh b/src/map.hh index bbd77fc..12a4143 100644 --- a/src/map.hh +++ b/src/map.hh @@ -13,7 +13,7 @@ enum : uint8 { STATUS_SWAPPED = 2, // TODO(fusion): It seems this is only used with the `NONE` entry in the - // hash table. I haven't seen it used **yet** but It may have a purpose + // hash table. I haven't seen it used **yet** but it may have a purpose // aside from preventing swap outs. STATUS_PERMANENT = 255, }; diff --git a/src/operate.cc b/src/operate.cc index 54bb4f2..5e2c964 100644 --- a/src/operate.cc +++ b/src/operate.cc @@ -998,7 +998,7 @@ void NotifyTrades(Object Obj){ return; } - TFindCreatures Search(14, 12, Obj, FIND_PLAYERS); + TFindCreatures Search(16, 14, Obj, FIND_PLAYERS); while(true){ uint32 CharacterID = Search.getNext(); if(CharacterID == 0){ @@ -1065,7 +1065,7 @@ void CloseContainer(Object Con, bool Force){ return; } - TFindCreatures Search(14, 12, Con, FIND_PLAYERS); + TFindCreatures Search(16, 14, Con, FIND_PLAYERS); while(true){ uint32 CharacterID = Search.getNext(); if(CharacterID == 0){ -- cgit v1.2.3