Map fix
This commit is contained in:
@@ -69,7 +69,6 @@ public class AndroidLauncher extends AndroidApplication{
|
|||||||
@Override
|
@Override
|
||||||
public void showFileChooser(boolean open, String extension, Consumer<FileHandle> cons){
|
public void showFileChooser(boolean open, String extension, Consumer<FileHandle> cons){
|
||||||
if(VERSION.SDK_INT >= 19){
|
if(VERSION.SDK_INT >= 19){
|
||||||
|
|
||||||
Intent intent = new Intent(open ? Intent.ACTION_OPEN_DOCUMENT : Intent.ACTION_CREATE_DOCUMENT);
|
Intent intent = new Intent(open ? Intent.ACTION_OPEN_DOCUMENT : Intent.ACTION_CREATE_DOCUMENT);
|
||||||
intent.addCategory(Intent.CATEGORY_OPENABLE);
|
intent.addCategory(Intent.CATEGORY_OPENABLE);
|
||||||
intent.setType("*/*");
|
intent.setType("*/*");
|
||||||
|
|||||||
@@ -189,6 +189,11 @@ public class Maps{
|
|||||||
|
|
||||||
createNewPreview(map, e -> {
|
createNewPreview(map, e -> {
|
||||||
maps.remove(map);
|
maps.remove(map);
|
||||||
|
try{
|
||||||
|
map.file.delete();
|
||||||
|
}catch(Throwable ignored){
|
||||||
|
|
||||||
|
}
|
||||||
error[0] = e;
|
error[0] = e;
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ public class Router extends Block{
|
|||||||
int counter = tile.rotation();
|
int counter = tile.rotation();
|
||||||
for(int i = 0; i < proximity.size; i++){
|
for(int i = 0; i < proximity.size; i++){
|
||||||
Tile other = proximity.get((i + counter) % proximity.size);
|
Tile other = proximity.get((i + counter) % proximity.size);
|
||||||
if(tile == from) continue;
|
if(other == from) continue;
|
||||||
if(set) tile.rotation((byte)((tile.rotation() + 1) % proximity.size));
|
if(set) tile.rotation((byte)((tile.rotation() + 1) % proximity.size));
|
||||||
if(other.block().acceptItem(item, other, Edges.getFacingEdge(tile, other))){
|
if(other.block().acceptItem(item, other, Edges.getFacingEdge(tile, other))){
|
||||||
return other;
|
return other;
|
||||||
|
|||||||
Reference in New Issue
Block a user