diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/GamesInProgress.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/GamesInProgress.java index be6e79ff7..d480f98b6 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/GamesInProgress.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/GamesInProgress.java @@ -103,8 +103,8 @@ public class GamesInProgress { info.slot = slot; Dungeon.preview(info, bundle); - //saves from before 0.5.0b are not supported - if (info.version < ShatteredPixelDungeon.v0_5_0b) { + //saves from before 0.6.0b are not supported + if (info.version < ShatteredPixelDungeon.v0_6_0b) { info = null; } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/ShatteredPixelDungeon.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/ShatteredPixelDungeon.java index 768f72f75..c3fdfe878 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/ShatteredPixelDungeon.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/ShatteredPixelDungeon.java @@ -40,44 +40,20 @@ import javax.microedition.khronos.opengles.GL10; public class ShatteredPixelDungeon extends Game { //variable constants for specific older versions of shattered, used for data conversion - //versions older than v0.5.0b are no longer supported, and data from them is ignored - public static final int v0_5_0b = 159; - + //versions older than v0.6.0b are no longer supported, and data from them is ignored public static final int v0_6_0b = 185; public static final int v0_6_1b = 209; public static final int v0_6_2e = 229; - public static final int v0_6_3c = 245; + public static final int v0_6_3b = 245; - public static final int v0_6_4 = 251; + public static final int v0_6_4a = 252; public ShatteredPixelDungeon() { super( WelcomeScene.class ); - //v0.6.0 - com.watabou.utils.Bundle.addAlias( - com.shatteredpixel.shatteredpixeldungeon.levels.rooms.special.MassGraveRoom.Bones.class, - "com.shatteredpixel.shatteredpixeldungeon.levels.painters.MassGravePainter$Bones" ); - com.watabou.utils.Bundle.addAlias( - com.shatteredpixel.shatteredpixeldungeon.levels.rooms.standard.RitualSiteRoom.RitualMarker.class, - "com.shatteredpixel.shatteredpixeldungeon.levels.painters.RitualSitePainter$RitualMarker" ); - com.watabou.utils.Bundle.addAlias( - com.shatteredpixel.shatteredpixeldungeon.levels.rooms.special.WeakFloorRoom.HiddenWell.class, - "com.shatteredpixel.shatteredpixeldungeon.levels.painters.WeakFloorPainter$HiddenWell" ); - com.watabou.utils.Bundle.addAlias( - com.shatteredpixel.shatteredpixeldungeon.levels.rooms.Room.class, - "com.shatteredpixel.shatteredpixeldungeon.levels.Room" ); - com.watabou.utils.Bundle.addAlias( - com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.Shortsword.class, - "com.shatteredpixel.shatteredpixeldungeon.items.weapon.melee.NewShortsword" ); - - //v0.6.0a - com.watabou.utils.Bundle.addAlias( - com.shatteredpixel.shatteredpixeldungeon.items.food.SmallRation.class, - "com.shatteredpixel.shatteredpixeldungeon.items.food.OverpricedRation" ); - //v0.6.2 com.watabou.utils.Bundle.addAlias( com.shatteredpixel.shatteredpixeldungeon.levels.rooms.secret.RatKingRoom.class, diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/Level.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/Level.java index cabe9bf57..80bfbfe07 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/Level.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/Level.java @@ -285,8 +285,8 @@ public abstract class Level implements Bundlable { version = bundle.getInt( VERSION ); - //saves from before 0.5.0b are not supported - if (version < ShatteredPixelDungeon.v0_5_0b){ + //saves from before 0.6.0b are not supported + if (version < ShatteredPixelDungeon.v0_6_0b){ throw new RuntimeException("old save"); } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/RegularLevel.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/RegularLevel.java index ed8f3d096..dceb7129c 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/RegularLevel.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/RegularLevel.java @@ -203,9 +203,6 @@ public abstract class RegularLevel extends Level { for (int i = 0; i < ((StandardRoom) room).sizeCat.roomValue; i++) { stdRooms.add(room); } - //pre-0.6.0 save compatibility - } else if (room.legacyType.equals("STANDARD")){ - stdRooms.add(room); } } Random.shuffle(stdRooms); @@ -391,9 +388,7 @@ public abstract class RegularLevel extends Level { protected Room randomRoom( Class type ) { Random.shuffle( rooms ); for (Room r : rooms) { - if (type.isInstance(r) - //compatibility with pre-0.6.0 saves - || (type == StandardRoom.class && r.legacyType.equals("STANDARD"))) { + if (type.isInstance(r)) { return r; } } diff --git a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/Room.java b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/Room.java index e8d6e2df4..a2f014962 100644 --- a/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/Room.java +++ b/core/src/main/java/com/shatteredpixel/shatteredpixeldungeon/levels/rooms/Room.java @@ -33,10 +33,7 @@ import java.util.ArrayList; import java.util.Collection; import java.util.LinkedHashMap; -//Note that this class should be treated as if it were abstract -// it is currently not abstract to maintain compatibility with pre-0.6.0 saves -// TODO make this class abstract after dropping support for pre-0.6.0 saves -public class Room extends Rect implements Graph.Node, Bundlable { +public abstract class Room extends Rect implements Graph.Node, Bundlable { public ArrayList neigbours = new ArrayList(); public LinkedHashMap connected = new LinkedHashMap();