Start mobequip refactor

This commit is contained in:
2024-03-18 10:01:29 -04:00
parent 0590ae64e7
commit 61c4cb1361
56 changed files with 198 additions and 377 deletions
+2 -2
View File
@@ -26,7 +26,7 @@ import java.util.concurrent.atomic.AtomicInteger;
*/
public final class MobLoot extends Item {
private static final AtomicInteger LastUsedId = new AtomicInteger(0);
public static final AtomicInteger lastNegativeID = new AtomicInteger(0);
private boolean isDeleted = false;
private boolean noSteal;
@@ -77,7 +77,7 @@ public final class MobLoot extends Item {
* @return Id number
*/
private static int generateId() {
int id = LastUsedId.decrementAndGet();
int id = lastNegativeID.decrementAndGet();
//TODO Add a way to reclaim disposed IDs if this becomes a problem
if (id == (-10000))