I didn't put this on the bug reports subforum as I'm uncertain if it's a bug or something wrong with the compiled windows version of the G3D viewer, my setup, etc. If it is a bug, feel free to move it to the bug reports subforum.
I've been having difficulty getting the G3D viewer to display a particle effect XML. While I can display any model fine, the unit particle systems have been giving me strange issues, and I've been unable to figure out a reason why. I'm using the G3D viewer that came bundled with the windows installer for 3.6.0.3, which is G3D Viewer 1.3.6. I can load the unit particle effects from the MegaPack fine (the specific file I tested was the bigtent's smoke_particles.xml), but for whatever reason, copying the file (and the particle bitmap, inside the same folder; fixing the relative link in the XML) to a working directory suddenly made it stop working. Even closing and reopening the program has no effect. When I copied this modified file back to its original directory (along with the particle bitmap file), the G3D viewer properly displayed it. Copying back into the original directory still had no effect.
The directory path has no foreign characters, and there are no spaces (though there are even spaces in the MegaPack path). The files were identical, and I've triple (quadruple, whatever) checked the relative link, and tried a number of alternative folder structures, including placing the bitmap image in a folder titled "images", adding "../" and "./" in front of the path to the particle image, yet, still nothing. The G3D viewer returns no errors, and the command line, even with verbose turned on, doesn't change at all when opening the file, although the window title changes to the name of the XML file.
The bitmap file is an exact copy of the one from the Indian's bigtent unit, and I even tried resaving it at different bit rates and tried converting it to PNG. The particle XML was a modified copy of bigtent's smoke, with just the filepath for the particle image modified, and even an unmodified version (with the particle image being moved into an "images" folder) had no avail. Even a more heavily modified version (cleaning up the bad XML formatting, removing an unnecessary comment, etc) didn't work in either location, even though the content of the XML wasn't modified, and the XML was valid (none of my attempts threw any error messages, nor anything in the command line).
I don't know if it's of any use, but here's the contents of --verbose (noting that all the output is written when the program is launched, not when loading the file):
C:\Program Files (x86)\MegaGlest>megaglest_g3dviewer --verbose
In [..\..\source\shared_lib\sources\util\util.cpp::Shared::Util::SystemFlags::ge
tSystemSettingType Line: 213]
In [..\..\source\shared_lib\sources\util\util.cpp::Shared::Util::SystemFlags::in
it Line: 233]
In [..\..\source\shared_lib\sources\util\util.cpp::Shared::Util::SystemFlags::in
it Line: 255]
In [..\..\source\shared_lib\sources\platform\common\simple_threads.cpp::Shared::
PlatformCommon::LogFileThread::execute Line: 466]
In [..\..\source\shared_lib\sources\util\util.cpp::Shared::Util::SystemFlags::in
it Line: 264]
In [..\..\source\shared_lib\sources\platform\common\simple_threads.cpp::Shared::
PlatformCommon::LogFileThread::execute Line: 474]
-=-=-=-=-=-=-= looking for file in possible location [C:\Program Files (x86)\Me
gaGlest\]
-=-=-=-=-=-=-= looking for windows specific file in possible location [C:\Progr
am Files (x86)\MegaGlest\windows_glest.ini]
-=-=-=-=-=-=-= About to load fileName.first = [C:\Program Files (x86)\MegaGlest\
glest.ini]
Property key [DataPath] now has value [C:\Program Files (x86)\MegaGlest\\]
Property key [LogPath] now has value [C:\Users\Mike\AppData\Roaming\megaglest\]
Property key [UserData_Root] now has value [C:\Users\Mike\AppData\Roaming\megagl
est\]
-=-=-=-=-=-=-= About to load fileName.second = [C:\Users\Mike\AppData\Roaming\me
gaglest\glestuser.ini]
OpenGL Extension [GL_EXT_framebuffer_object] supported status = 1
In [main.cpp::Shared::G3dViewer::MainWindow::loadProjectileParticle Line: 1331]
about to load [] particleProjectilePathList.size() = 0
In [main.cpp::Shared::G3dViewer::MainWindow::loadProjectileParticle Line: 1445]
after load []
In [main.cpp::Shared::G3dViewer::MainWindow::loadSplashParticle Line: 1449] abou
t to load [] particleSplashPathList.size() = 0
In [main.cpp::Shared::G3dViewer::MainWindow::loadSplashParticle Line: 1552] afte
r load [] particleSplashPathList.size() = 0
OpenGL Extension [GL_EXT_texture_filter_anisotropic] supported status = 1
The particle XML I was using is this:
<?xml version="1.0" standalone="yes"?>
<unit-particle-system>
<texture value="true" path="images/particle.bmp" luminance="true"/>
<mode value="black"/>
<primitive value="quad"/>
<offset x="0" y="-1.2" z="0"/>
<direction x="0.3" y="1" z="0"/>
<color red="0.1" green="0.1" blue="0.1" alpha="0.33" />
<color-no-energy red="0.0" green="0.0" blue="0.0" alpha="0.0" />
<radius value="0.9" />
<size value="1" />
<size-no-energy value="0.7" />
<speed value="2.0" />
<gravity value="0.001"/>
<emission-rate value="3" />
<energy-max value="200" />
<energy-var value="0" />
<relative value="true" />
<relativeDirection value="false" />
<fixed value="false" />
<teamcolorNoEnergy value="false" />
<teamcolorEnergy value="false" />
<!--trajectory type="spiral">
<speed value="14.0"/>
<scale value="1"/>
<frequency value="0.5"/>
</trajectory-->
</unit-particle-system>
Even if I change the particle effect from a quad with an image to a line particle effect, nothing is displayed, but moving this exact file to C:\Program Files (x86)\MegaGlest\techs\megapack\factions\indian\units\bigtent, the particle works fine.
<?xml version="1.0" standalone="yes"?>
<unit-particle-system>
<texture value="false" />
<primitive value="line" />
<offset x="0" y="-1.2" z="0" />
<direction x="0.3" y="1" z="0" />
<color red="0.1" green="0.1" blue="0.1" alpha="0.33" />
<color-no-energy red="0.0" green="0.0" blue="0.0" alpha="0.0" />
<radius value="0.9" />
<size value="1" />
<size-no-energy value="0.7" />
<speed value="2.0" />
<gravity value="0.001" />
<emission-rate value="3" />
<energy-max value="200" />
<energy-var value="0" />
<relative value="true" />
<relativeDirection value="false" />
<fixed value="false" />
<teamcolorNoEnergy value="false" />
<teamcolorEnergy value="false" />
</unit-particle-system>
Too long; didn't read: For whatever reason, having the particle XML in my documents folder is stopping the G3D viewer from displaying any unit particle effect, without any error messages, even if the particle effect is an exact copy from a MegaPack unit, which the G3D viewer does display properly.
I'd really like to see whatever the underlying issue is here fixed, as this is preventing me from doing some necessary work with particles (it would be far, far too difficult to reload the game every time to position particles on a unit). I don't see any reason why my system configuration would make a difference in this case, but for the record, it's a 64-bit Windows 7 operating system with service pack 1, with a Core 2 duo CPU T6600 running at 2.2GHz, an ATI Mobility Radeon HD 4650 graphics card running a 1600x900 resolution, 4 GB of DDR3 RAM, and a 500 GB 7200 RPM 3Gb/s HDD with 266 GB free, the computer is fully up-to-date, and it's the latest stable released version of MegaGlest.
Also should be noted that I have loaded particle effects into the G3D viewer in the past, without this problem (though that was quite a while ago, admittedly, there may have been several changes since then).