diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/Dungeon.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/Dungeon.java index b7f198fc9..186c67084 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/Dungeon.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/Dungeon.java @@ -559,6 +559,7 @@ public class Dungeon { seed = bundle.contains( SEED ) ? bundle.getLong( SEED ) : DungeonSeed.randomSeed(); + Actor.clear(); Actor.restoreNextID( bundle ); quickslot.reset(); diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/Actor.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/Actor.java index acd1fcfce..5047ddde8 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/Actor.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/actors/Actor.java @@ -111,7 +111,6 @@ public abstract class Actor implements Bundlable { } } - private static int nextID = 1; public int id() { if (id > 0) { return id; @@ -129,6 +128,7 @@ public abstract class Actor implements Bundlable { private static volatile Actor current; private static SparseArray ids = new SparseArray<>(); + private static int nextID = 1; private static float now = 0;