mirror of
https://github.com/Card-Forge/forge.git
synced 2025-11-16 02:38:02 +00:00
Fixed folder format loading to ensure core sets load first (otherwise android may not load standard correctly)
This commit is contained in:
@@ -166,12 +166,10 @@ public final class FModel {
|
|||||||
ForgePreferences.DEV_MODE = preferences.getPrefBoolean(FPref.DEV_MODE_ENABLED);
|
ForgePreferences.DEV_MODE = preferences.getPrefBoolean(FPref.DEV_MODE_ENABLED);
|
||||||
ForgePreferences.UPLOAD_DRAFT = ForgePreferences.NET_CONN;
|
ForgePreferences.UPLOAD_DRAFT = ForgePreferences.NET_CONN;
|
||||||
|
|
||||||
|
formats = new GameFormat.Collection(new GameFormat.Reader( new File(ForgeConstants.FORMATS_DATA_DIR + "coreformats.txt")));
|
||||||
final File[] files = new File(ForgeConstants.FORMATS_DATA_DIR).listFiles();
|
final File[] files = new File(ForgeConstants.FORMATS_DATA_DIR).listFiles();
|
||||||
for (final File file : files) {
|
for (final File file : files) {
|
||||||
if(formats == null){
|
if (!file.getName().equals("coreformats.txt")){
|
||||||
formats = new GameFormat.Collection(new GameFormat.Reader(file));
|
|
||||||
}else{
|
|
||||||
GameFormat.Collection additionalformats = new GameFormat.Collection(new GameFormat.Reader(file));
|
GameFormat.Collection additionalformats = new GameFormat.Collection(new GameFormat.Reader(file));
|
||||||
for (GameFormat format:additionalformats) {
|
for (GameFormat format:additionalformats) {
|
||||||
formats.add(format);
|
formats.add(format);
|
||||||
|
|||||||
Reference in New Issue
Block a user