Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bug with autosaves #305

Closed
rakantoh opened this issue Jul 29, 2020 · 15 comments
Closed

Bug with autosaves #305

rakantoh opened this issue Jul 29, 2020 · 15 comments

Comments

@rakantoh
Copy link

I already played until alpha labs sector 4, in each stage the game creates an autosave in the beginning of the stage, but the alpha labs have a problem, in sector 1, it creates the autosave of alpha labs sector 1, when i pass the alpha labs sector 1 and i go to the alpha labs sector 2, the game creates the autosave of the alpha labs sector 2, but the autosave of sector 1 dissapears, the autosave of sector 2 rewrite the autosave of sector 1, and the autosave of sector 3 do the same with the autosave of sector 2, and the autosave of sector 4 do the same with the autosave of sector 3.
This is a bug of dhewn3.

@DanielGibson
Copy link
Member

DanielGibson commented Jul 29, 2020

So this behaves differently with original Doom3 1.3.1?
Or is it maybe normal that the game only keeps the last/latest autosave?

I need to to further testing, but for me it (seems to?) look different:
dhewm3-save

What operating system are you on? Which version of dhewm3 are you using?

@rakantoh
Copy link
Author

rakantoh commented Jul 29, 2020

I use windows 10 pro x64 v2004, doom 3 v1.3.1 steam version, i renamed doom3.exe to doom3.bak.exe and renamed dhewm3.exe to doom3.exe, and language in spanish. I use dhewm3 v1.5.1 rc2, the latest. Do you need my hardware specs?

@DanielGibson
Copy link
Member

Thanks!
I hope the hardware doesn't play a role; I'll try to reproduce this when I have some time, hopefully this weekend.

@rakantoh
Copy link
Author

ok. thanks, the project is awesome!

@DanielGibson
Copy link
Member

I just remembered one more thing: Can you tell me the whole path of the savegame directory and also its contents?
Should be something like C:\Users\rakantoh\Documents\My Games\dhewm3\base\savegames\

@rakantoh
Copy link
Author

yes, that is the path.

@DanielGibson
Copy link
Member

So the username is exactly "rakantoh", no special characters or anything?

Can you tell me all the Alpha-Labs related file names in it (as far as I understand even with the bug there should be at least one savegame)?

@rakantoh
Copy link
Author

yes, the username is "rakantoh", i attached the screenshot of the savegames folder.
dhewm saves

@DanielGibson
Copy link
Member

DanielGibson commented Jul 30, 2020

Thanks!

Damn, it looks like it uses the localized level names (so in your case spanish ones) for the autosaves.. that probably causes the problem.
I have

.../dhewm3/base/savegames/AutoSave__Alpha_Labs_Sector_1.save
.../dhewm3/base/savegames/AutoSave__Alpha_Labs_Sector_1.txt
.../dhewm3/base/savegames/AutoSave__Alpha_Labs_Sector_2.save
.../dhewm3/base/savegames/AutoSave__Alpha_Labs_Sector_2.txt
.../dhewm3/base/savegames/AutoSave__Enpro_Plant.save
.../dhewm3/base/savegames/AutoSave__Enpro_Plant.txt
.../dhewm3/base/savegames/AutoSave__Mars_City.save
.../dhewm3/base/savegames/AutoSave__MARS_CITY_SOUS_SOL.save
.../dhewm3/base/savegames/AutoSave__MARS_CITY_SOUS_SOL.txt
.../dhewm3/base/savegames/AutoSave__Mars_City.txt
.../dhewm3/base/savegames/AutoSave__Mars_City_Underground.save
.../dhewm3/base/savegames/AutoSave__Mars_City_Underground.txt
.../dhewm3/base/savegames/AutoSave__Subterr_neo_Mars_City.save
.../dhewm3/base/savegames/AutoSave__Subterr_neo_Mars_City.txt
.../dhewm3/base/savegames/AutoSave__UAC_Administration.save
.../dhewm3/base/savegames/AutoSave__UAC_Administration.txt

I'll try to fix this when I have some time, that probably won't be straightforward..
Until then, as a workaround, you could either save manually (not rely on autosaves) or remove zpak00*.pk4 from the gamedata so the game is back to English.

@rakantoh
Copy link
Author

yeah, i use manual saves, however i want to say you the bug for you knowledge and further fixes.

@DanielGibson
Copy link
Member

I think I have a fix for that problem, can you test it?
dhewm3-autosavefix.zip
Thanks! :)

@rakantoh
Copy link
Author

rakantoh commented Aug 2, 2020

ok, i will test now.

@rakantoh
Copy link
Author

rakantoh commented Aug 2, 2020

Ok, i played the alpha labs again and the fix works! now the game created the alpha labs autosaves correctly, without replacing each them. Thanks! great job!

@DanielGibson
Copy link
Member

Awesome, thanks a lot for testing!

@rakantoh
Copy link
Author

rakantoh commented Aug 3, 2020

Oh man you are awesome, it's true that you fixed bugs of the original game! The problem of autosaves is present in the original doom 3 without any mod, i apologize for give you additional work for this. Great job!
Apart, i comment here because i dont want to open other issue, in the delta labs 2b (the first time when the player use the teleporter), when the player walks accross of ductes, the player falls in a room where a scientific is doing an autopsy to a imp, the scientific begins to talk with the player and to the end the scientific gives to the player the code for two lockers in the same room, in english, the scientific say the code normally, but in spanish, and in others languages, the code (or the sound of the scientific saying the code) is missing, isn't hear. Can you fix this issue/bug?
Again, i apologize for give you additional work, but this enhance this very useful mod.
Many thanks.
deltalabs2

rorgoroth pushed a commit to rorgoroth/dhewm3 that referenced this issue Apr 8, 2023
idSessionLocal::SaveGame() uses saveName for both the description in
savegames/bla.txt and the filename itself ("bla" in this case), which
is a "scrubbed" version of that string ("file extension" removed,
problematic chars replaced with '_').
In case of Autosaves, MoveToNewMap() passes a translated name of the
map as saveName, which makes sense for the description, but not so much
for the filename.
In Spanish the Alpha Labs names are like "LAB. ALFA 1", "LAB. ALFA 2" ..
and everything after "LAB" is cut off as a file extension - so every
autosave of an Alpha Labs part overwrites the last one, as they all get
the same name...

The solution is to pass an additional (optional) argument saveFileName
to idSessionLocal::SaveGame(), and for autosaves pass the mapname
(which is the filename without .map; yes, it might contain slashes,
but the scrubber will turn them into _) instead of the translated name
as saveFileName.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

No branches or pull requests

2 participants