2
0
Эх сурвалжийг харах

Fixed tests that use wildHouse.zip so that the loading append in the simple init and not in the main, because it fails since the testChooser change
On a side note the wildhouse.zip in the download section is not the same as the one in the test package, and fails to load due to bad file naming (meshxml instead of mesh.xml)

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@7159 75d07b2b-3a1a-0410-a2c5-0572b91ccdca

rem..om 14 жил өмнө
parent
commit
6d27155e86

+ 5 - 4
engine/src/test/jme3test/scene/TestSceneLoading.java

@@ -56,10 +56,7 @@ public class TestSceneLoading extends SimpleApplication {
     private static boolean useHttp = false;
 
     public static void main(String[] args) {
-        File file = new File("wildhouse.zip");
-        if (!file.exists()) {
-            useHttp = true;
-        }
+     
         TestSceneLoading app = new TestSceneLoading();
         app.start();
     }
@@ -75,6 +72,10 @@ public class TestSceneLoading extends SimpleApplication {
         // load sky
         rootNode.attachChild(SkyFactory.createSky(assetManager, "Textures/Sky/Bright/BrightSky.dds", false));
 
+        File file = new File("wildhouse.zip");
+        if (!file.exists()) {
+            useHttp = true;
+        }
         // create the geometry and attach it
         // load the level from zip or http zip
         if (useHttp) {

+ 6 - 4
engine/src/test/jme3test/water/TestPostWaterLake.java

@@ -52,10 +52,7 @@ public class TestPostWaterLake extends SimpleApplication {
     private static boolean useHttp = true;
 
     public static void main(String[] args) {
-        File file = new File("wildhouse.zip");
-        if (file.exists()) {
-            useHttp = false;
-        }
+     
         TestPostWaterLake app = new TestPostWaterLake();
         app.start();
     }
@@ -68,6 +65,11 @@ public class TestPostWaterLake extends SimpleApplication {
         // load sky
         rootNode.attachChild(SkyFactory.createSky(assetManager, "Textures/Sky/Bright/BrightSky.dds", false));
 
+        File file = new File("wildhouse.zip");
+        
+        if (file.exists()) {
+            useHttp = false;
+        }
         // create the geometry and attach it
         // load the level from zip or http zip
         if (useHttp) {

+ 6 - 4
engine/src/test/jme3test/water/TestSceneWater.java

@@ -59,10 +59,7 @@ public class TestSceneWater extends SimpleApplication {
     private static boolean useHttp = true;
 
     public static void main(String[] args) {
-        File file = new File("wildhouse.zip");
-        if (file.exists()) {
-            useHttp = false;
-        }
+      
         TestSceneWater app = new TestSceneWater();
         app.start();
     }
@@ -76,6 +73,11 @@ public class TestSceneWater extends SimpleApplication {
         // load sky
         mainScene.attachChild(SkyFactory.createSky(assetManager, "Textures/Sky/Bright/BrightSky.dds", false));
 
+        
+        File file = new File("wildhouse.zip");
+        if (file.exists()) {
+            useHttp = false;
+        }
         // create the geometry and attach it
         // load the level from zip or http zip
         if (useHttp) {