Some changes
This commit is contained in:
parent
10f571a7d8
commit
56d3c7d508
@ -24,7 +24,6 @@ import com.badlogic.gdx.Gdx;
|
|||||||
import com.badlogic.gdx.Input;
|
import com.badlogic.gdx.Input;
|
||||||
import com.badlogic.gdx.InputAdapter;
|
import com.badlogic.gdx.InputAdapter;
|
||||||
import com.badlogic.gdx.Preferences;
|
import com.badlogic.gdx.Preferences;
|
||||||
import com.badlogic.gdx.files.FileHandle;
|
|
||||||
import com.badlogic.gdx.graphics.Color;
|
import com.badlogic.gdx.graphics.Color;
|
||||||
import com.badlogic.gdx.graphics.g2d.BitmapFont;
|
import com.badlogic.gdx.graphics.g2d.BitmapFont;
|
||||||
import com.badlogic.gdx.graphics.glutils.ShapeRenderer;
|
import com.badlogic.gdx.graphics.glutils.ShapeRenderer;
|
||||||
@ -34,6 +33,7 @@ import com.openeggbert.core.main.OpenEggbertGame;
|
|||||||
import com.openeggbert.core.mod.Mod;
|
import com.openeggbert.core.mod.Mod;
|
||||||
import com.openeggbert.core.mod.ModType;
|
import com.openeggbert.core.mod.ModType;
|
||||||
import com.pixelgamelibrary.api.Pixel;
|
import com.pixelgamelibrary.api.Pixel;
|
||||||
|
import com.pixelgamelibrary.api.storage.Storage;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.stream.Collectors;
|
import java.util.stream.Collectors;
|
||||||
import lombok.AllArgsConstructor;
|
import lombok.AllArgsConstructor;
|
||||||
@ -74,9 +74,12 @@ public class GameSpaceListScreen extends AbstractOpenEggbertScreen {
|
|||||||
Preferences prefs = Gdx.app.getPreferences("My Preferences");
|
Preferences prefs = Gdx.app.getPreferences("My Preferences");
|
||||||
prefs.putString("test", "abc");
|
prefs.putString("test", "abc");
|
||||||
prefs.flush();
|
prefs.flush();
|
||||||
Pixel.storage().getStorage().createDirectory("modes");
|
final Storage storage = Pixel.storage().getStorage();
|
||||||
Pixel.storage().getStorage().createDirectory("gameSpaces");
|
storage.createDirectory("modes");
|
||||||
Pixel.storage().getStorage().flush();
|
storage.createDirectory("gameSpaces");
|
||||||
|
//storage.file("modes").child("text.txt").writeString("textabc");
|
||||||
|
|
||||||
|
storage.flush();
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
@ -29,6 +29,8 @@ import com.openeggbert.core.configuration.ConfigDef;
|
|||||||
import com.openeggbert.core.main.OpenEggbertGame;
|
import com.openeggbert.core.main.OpenEggbertGame;
|
||||||
import com.openeggbert.core.utils.EmbeddedFileHandleFactory;
|
import com.openeggbert.core.utils.EmbeddedFileHandleFactory;
|
||||||
import com.openeggbert.core.configuration.OpenEggbertDisplayMode;
|
import com.openeggbert.core.configuration.OpenEggbertDisplayMode;
|
||||||
|
import com.pixelgamelibrary.api.Pixel;
|
||||||
|
import java.util.Arrays;
|
||||||
import java.util.Optional;
|
import java.util.Optional;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -42,6 +44,9 @@ public class InitScreen extends AbstractOpenEggbertScreen {
|
|||||||
public InitScreen(OpenEggbertGame openEggbertGame) {
|
public InitScreen(OpenEggbertGame openEggbertGame) {
|
||||||
super(openEggbertGame);
|
super(openEggbertGame);
|
||||||
System.out.println("game.getGameSpace().getDataDirectory() != null" + (game.getGameSpace().getDataDirectory() != null));
|
System.out.println("game.getGameSpace().getDataDirectory() != null" + (game.getGameSpace().getDataDirectory() != null));
|
||||||
|
Pixel.app().log("###1");
|
||||||
|
Arrays.asList(Gdx.files.local(".").list()).forEach(e->Pixel.app().log(e.path()));
|
||||||
|
Pixel.app().log("###2");
|
||||||
if (game.getGameSpace().getDataDirectory() != null) {
|
if (game.getGameSpace().getDataDirectory() != null) {
|
||||||
FileHandle configDefFileHandle = null;
|
FileHandle configDefFileHandle = null;
|
||||||
String[] array = new String[]{"config.def", "Config.def", "CONFIG.DEF"};
|
String[] array = new String[]{"config.def", "Config.def", "CONFIG.DEF"};
|
||||||
|
Reference in New Issue
Block a user