REGoth-project / REGoth

OpenSource-Reimplementation of the zEngine, used by the game "Gothic"
GNU General Public License v3.0
631 stars 62 forks source link

.VDF-files are not loaded by timestamp. #192

Closed superdaveman closed 6 years ago

superdaveman commented 7 years ago

REGoth takes the first result it can find (by alphabet) and ignores the timestamp of the other .VDF-files. E.g. Textures.vdf is loaded before Textures_Addon.vdf. That causes REGoth to not load some textures from Gothic II NotR but from Gothic II classic.

ataulien commented 7 years ago

Loading by timestamp isn't implemented yet. Shouldn't be too hard though.

markusobi commented 7 years ago

Which timestamp is relevant for deciding which file to load? The timestamp of the whole .vdf archive? or The timestamp of each individual file inside the vdf-file?

nicodex commented 7 years ago

Only the timestamp in the header of the VDF archive matters (the file entries in the VDF volume do not have their own timestamps).

frabert commented 7 years ago

The timestamp on the VDF header is correctly read by the physfs branch and can be accessed by calls to PHYSFS_getLastModTime. It is not currently implemented in the FileIndex class, but can easily be added. Though the correct way to handle this situation, if I understand it correctly, is to mount the VDF files in order of ascending timestamp, and let PhysFS manage the resolution by itself.

tomedi commented 6 years ago

Solved with the merge of #325 . Issue can be closed.