HelloAssets and town.zip

I’m trying to go through the beginner tutorials, but I’m having some problems in this exercise called “Excercise - How to Load Assets”, which is located here: https://wiki.jmonkeyengine.org/legacy/doku.php/jme3:beginner:hello_asset



More specifically, i’m getting an error message (located at the end of this message) when I’m trying to load the town.zip with the zip locator. The zip file is at the right place, and the code is the same one as the code in the “Code sample” section in the tutorial, but i’m importing com.jme3.asset.plugins.ZipLocator at the beginning and then adding the required code from the exercise. I’m using the latest version of nightly build of jMonkeyPlatform.



The error message is:



[java]SEVERE: Uncaught exception thrown in Thread[LWJGL Renderer Thread,5,main]

com.jme3.asset.AssetNotFoundException: Scene.material

at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:236)

at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:281)

at com.jme3.scene.plugins.ogre.SceneLoader.startElement(SceneLoader.java:209)

at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:501)

at com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:179)

at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(XMLNSDocumentScannerImpl.java:377)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2755)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:648)

at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(XMLNSDocumentScannerImpl.java:140)

at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:511)

at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:808)

at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:737)

at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:119)

at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1205)

at com.jme3.scene.plugins.ogre.SceneLoader.load(SceneLoader.java:340)

at com.jme3.asset.DesktopAssetManager.loadAsset(DesktopAssetManager.java:240)

at com.jme3.asset.DesktopAssetManager.loadModel(DesktopAssetManager.java:373)

at com.jme3.asset.DesktopAssetManager.loadModel(DesktopAssetManager.java:383)

at jme3test.helloworld.HelloAssets.simpleInitApp(HelloAssets.java:56)

at com.jme3.app.SimpleApplication.initialize(SimpleApplication.java:219)

at com.jme3.system.lwjgl.LwjglAbstractDisplay.initInThread(LwjglAbstractDisplay.java:117)

at com.jme3.system.lwjgl.LwjglAbstractDisplay.run(LwjglAbstractDisplay.java:188)

at java.lang.Thread.run(Thread.java:619)[/java]

I have a similar error. If I use the tutorial with the downloaded zip file, it works fine.

However, if I unzip the file, delete the original .zip, and then create a new zip file from the unzipped folder, then I get the AssetNotFoundException above. Is there a particular zip program I need to use? I tried with the built-in Windows 7 zip program and 7-zip, and both fail.

Edit: This was with the quake3level.zip example.

Just put your assets in the assets folder where they will be compressed in a jar file (which essentially is a ZIP).