I’m developing in this environment:
Product Version: jMonkeyEngine SDK v3.3.2-stable Updates: jMonkeyEngine SDK is updated to version NetBeans 8.2 Patch 2 Java: 11.0.6; OpenJDK 64-Bit Server VM 11.0.6+10 Runtime: OpenJDK Runtime Environment 11.0.6+10 System: Linux version 5.4.0-90-generic running on amd64; UTF-8; en_US (jmonkeyplatform)
And everything works fine.
When I try to run the project under Windows I got this exception:
Uncaught exception thrown in Thread[jME3 Main,5,main] AssetNotFoundException: Asset name doesn't match requirements. "Z:/home/phx/Documents/VMsShared/jMonkey_PrjFolder/Plane-Inferno_WinX64_20211113_2335/Models/persistentData.j3o" doesn't match "Models\persistentData.j3o"
Searching around I found old issues similar to this one but I have not been able to figure it out by myself
Seems the problem is related to:
DEFAULT_INT_PATH =System.getProperty("user.dir"); // Tested and fail Paths.get(".").toAbsolutePath().normalize().toString(); // Tested and fail new File(".").getCanonicalPath() am.registerLocator(DEFAULT_INT_PATH, FileLocator.class);
When I LOG on a file the path (before get the exception) are correct for the OS but in the exception seems the first one have unix slash and the second one have the Windows backslash…I don’t understand why.
What I’m doing wrong?
Thank you in advance for any clues you have for me!