From 04a2d6fb1ceb6be1fedd93e0121d9b55329371ba Mon Sep 17 00:00:00 2001
From: FatBoy-DOTC <justin.chucksinsulating@gmail.com>
Date: Mon, 17 Mar 2025 20:00:59 -0500
Subject: [PATCH] interest management

---
 src/engine/objects/PlayerCharacter.java | 10 ++++++++--
 1 file changed, 8 insertions(+), 2 deletions(-)

diff --git a/src/engine/objects/PlayerCharacter.java b/src/engine/objects/PlayerCharacter.java
index 14667dd3..d3f75d90 100644
--- a/src/engine/objects/PlayerCharacter.java
+++ b/src/engine/objects/PlayerCharacter.java
@@ -5234,11 +5234,13 @@ public class PlayerCharacter extends AbstractCharacter {
 
                     }
                     if(!this.timestamps.containsKey("nextReload")){
-                        this.timestamps.put("nextReload",System.currentTimeMillis() + 5000L);
+                        this.timestamps.put("nextReload",System.currentTimeMillis() + 5000);
                     }else{
-                        if(this.timestamps.get("nextReload") > System.currentTimeMillis()) {
+                        if(this.timestamps.get("nextReload") < System.currentTimeMillis()) {
                             this.setDirtyLoad(true);
+                            InterestManager.setObjectDirty(this);
                             InterestManager.INTERESTMANAGER.RefreshLoadedObjects(this);
+                            this.timestamps.put("nextReload",System.currentTimeMillis() + 5000);
                         }
                     }
 
@@ -5264,8 +5266,12 @@ public class PlayerCharacter extends AbstractCharacter {
             if(pc.equals(player))
                 continue;
             pc.isBoxed = true;
+            InterestManager.setObjectDirty(pc);
+            pc.setDirtyLoad(true);
         }
         player.isBoxed = false;
+        InterestManager.setObjectDirty(player);
+        player.setDirtyLoad(true);
     }
 
     public static boolean checkIfBoxed(PlayerCharacter player){