diff --git a/.idea/libraries/org_junit_jupiter_junit_jupiter_5_5_2.xml b/.idea/libraries/org_junit_jupiter_junit_jupiter_5_5_2.xml
deleted file mode 100644
index 7204ced..0000000
--- a/.idea/libraries/org_junit_jupiter_junit_jupiter_5_5_2.xml
+++ /dev/null
@@ -1,17 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/Azaraka.iml b/Azaraka.iml
index 4d0925a..e8c39a6 100644
--- a/Azaraka.iml
+++ b/Azaraka.iml
@@ -17,6 +17,5 @@
-
\ No newline at end of file
diff --git a/res/scene.json b/res/scene.json
index 365cc48..549435b 100644
--- a/res/scene.json
+++ b/res/scene.json
@@ -149,7 +149,7 @@
]
},
{
- "type": "cl.cromer.azaraka.object.Player",
+ "type": "null",
"textures": [
0
]
diff --git a/src/cl/cromer/azaraka/Constantes.java b/src/cl/cromer/azaraka/Constantes.java
index 6a169dd..f3aa785 100644
--- a/src/cl/cromer/azaraka/Constantes.java
+++ b/src/cl/cromer/azaraka/Constantes.java
@@ -126,7 +126,7 @@ public interface Constantes {
/**
* The default volume
*/
- int DEFAULT_VOLUME = 0;
+ int DEFAULT_VOLUME = 100;
/**
* Generates the scene manually instead of from the JSON file if true
*/
diff --git a/src/cl/cromer/azaraka/Escenario.java b/src/cl/cromer/azaraka/Escenario.java
index 1996373..91d7989 100644
--- a/src/cl/cromer/azaraka/Escenario.java
+++ b/src/cl/cromer/azaraka/Escenario.java
@@ -31,6 +31,8 @@ import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.ArrayList;
+import java.util.concurrent.locks.Lock;
+import java.util.concurrent.locks.ReentrantLock;
import java.util.logging.Logger;
/**
@@ -53,26 +55,6 @@ public class Escenario extends JComponent implements Constantes {
* The cells of the game
*/
private Celda[][] celdas;
- /**
- * The cell that contains the player
- */
- private Celda player;
- /**
- * The magic portal
- */
- private Celda portal;
- /**
- * The enemies
- */
- private ArrayList enemies = new ArrayList<>();
- /**
- * The chests
- */
- private ArrayList chests = new ArrayList<>();
- /**
- * The keys
- */
- private ArrayList keys = new ArrayList<>();
/**
* A collection of tiles that can be used in the scene
*/
@@ -122,8 +104,6 @@ public class Escenario extends JComponent implements Constantes {
Json json = new Json();
json.exportScene(celdas);
}
-
- generateRandomObjects();
}
/**
@@ -142,7 +122,6 @@ public class Escenario extends JComponent implements Constantes {
if (cells[x][y].type.equals(Player.class.getName())) {
celdas[x][y].setObject(new Player(null, celdas[x][y]));
- player = celdas[x][y];
}
else if (cells[x][y].type.equals(Enemy.class.getName())) {
celdas[x][y].setObject(new Enemy(null, celdas[x][y], null));
@@ -177,91 +156,83 @@ public class Escenario extends JComponent implements Constantes {
/**
* Generate random objects in the scene
+ *
+ * @return Returns a list of objects that where generated
*/
- private void generateRandomObjects() {
+ public ArrayList