The Ur-Quan Masters Home Page Welcome, Guest. Please login or register.
Did you miss your activation email?
February 11, 2025, 07:15:24 pm
Home Help Search Login Register
News: Celebrating 30 years of Star Control 2 - The Ur-Quan Masters

+  The Ur-Quan Masters Discussion Forum
|-+  The Ur-Quan Masters Re-Release
| |-+  General UQM Discussion (Moderator: Death 999)
| | |-+  Where are the save files?
« previous next »
Pages: 1 [2] 3 Print
Author Topic: Where are the save files?  (Read 9778 times)
Culture20
Enlightened
*****
Offline Offline

Posts: 917


Thraddash Flower Child


View Profile
Re: Where are the save files?
« Reply #15 on: September 06, 2005, 05:23:00 am »

Generally saved games for new MS games go into the "My Documents" directory.  I've got a Thief 3 folder in mydocs.  Halo goes a step further and creates a "My Games" directory under "My Documents".   'Application Data" is often used for program settings (so if the eventual UQM settings menu stores changes, that's where they'd be looked for first [or second for any good ol' days hold outs like myself; *sigh* multiuser system security ruins everything]). 

Granted, it's messy to have things this split up, but all the settings and saves would be in the profile, which is backed up by even the weakest of GUI backup programs (most just a front-end for xcopy).  GIMP and a few other GNU programs have started following linux standards in the windows world, and are putting .gimp (or .whatever) directories in the root of the user's profile (not the best solution due to those aforementioned stupid GUI backup progs that sometimes just backup mydocs, favorites & appdata... sometimes not even appdata and favorites).
« Last Edit: September 06, 2005, 05:25:29 am by Culture20 » Logged
Arael
Zebranky food
*
Offline Offline

Posts: 39


Utwig wearing a mask of Spiky Featherness


View Profile
Re: Where are the save files?
« Reply #16 on: September 07, 2005, 10:53:51 am »

I found my saves. Instead of the default(?)

C:\Tools\!!Win\Dane aplikacji\    (as I expected from this thread)

the savegames and configs were found in

E:\userdata\
(the game installed at E:\The Ur-Quan Masters\)

I'm running UQM 0.4.0 at Win98 PL.
Logged

. . .
meep-eep
Forum Admin
Enlightened
*****
Offline Offline

Posts: 2847



View Profile
Re: Where are the save files?
« Reply #17 on: September 07, 2005, 02:37:26 pm »

Sounds like you have %APPDATA% set to E:\userdata\ for some reason.
Logged

“When Juffo-Wup is complete
when at last there is no Void, no Non
when the Creators return
then we can finally rest.”
Novus
Enlightened
*****
Offline Offline

Gender: Male
Posts: 1938


Fot or not?


View Profile
Re: Where are the save files?
« Reply #18 on: September 07, 2005, 03:03:51 pm »

Sounds like you have %APPDATA% set to E:\userdata\ for some reason.
Either that or neither %APPDATA% nor %USERPROFILE% is set. sc2code/libs/file/dirs.c clearly includes fallback code for this situation that uses ..\userdata as a fallback home directory.

I'm not entirely sure whether reading these environment variables is a recommended or reliable way to determine the application data and user profile directories. Reading $HOME on Unix is not a good idea, at least.
Logged

RTFM = Read the fine manual.
RTTFAQ = Read the Ur-Quan Masters Technical FAQ.
meep-eep
Forum Admin
Enlightened
*****
Offline Offline

Posts: 2847



View Profile
Re: Where are the save files?
« Reply #19 on: September 07, 2005, 04:45:30 pm »

Hmm... the "..\userdata\" fallback was set that way because the game would chdir() to the content directory when I created the expandPath() function originally. I've removed that chdir() since, but didn't remember this fallback.
It should go to "userdata" in the current working dir now. (I'll fix this in CVS).
A lot of thought and discussion has gone into the decision to use %APPDATA% and %USERPROFILE% as fallbacks. It's the best we can do as it is the most portable way (within Windows versions) to get to these locations.
On *nix systems, it's much easier. Reading $HOME to determine the home dir definately the right way to go. It's guaranteed by POSIX to be set on login, while it can be overridden by users who know what they're doing (think live cds, usb sticks, etc). The only reason there is a fallback for getpwuid() at all is for some support of buggy programs (such as the MacOS launcher apparently, though I think that may be fixed by now).
Why did you say it is not a good idea in the first place? It may help if you argument claims in the future so your readers don't have to explicitely ask for them btw.
Logged

“When Juffo-Wup is complete
when at last there is no Void, no Non
when the Creators return
then we can finally rest.”
Novus
Enlightened
*****
Offline Offline

Gender: Male
Posts: 1938


Fot or not?


View Profile
Re: Where are the save files?
« Reply #20 on: September 07, 2005, 06:34:42 pm »

A lot of thought and discussion has gone into the decision to use %APPDATA% and %USERPROFILE% as fallbacks. It's the best we can do as it is the most portable way (within Windows versions) to get to these locations.
SHGetFolderPath is in a redistributable DLL, according to this and is compatible with any Windows 95 compatible system and recommended according to this. I'm not quite sure why you find it problematic, and using it ought to have prevented Arael's problem.

Quote
On *nix systems, it's much easier. Reading $HOME to determine the home dir definately the right way to go. It's guaranteed by POSIX to be set on login, while it can be overridden by users who know what they're doing (think live cds, usb sticks, etc). The only reason there is a fallback for getpwuid() at all is for some support of buggy programs (such as the MacOS launcher apparently, though I think that may be fixed by now).
Why did you say it is not a good idea in the first place? It may help if you argument claims in the future so your readers don't have to explicitely ask for them btw.
Sorry for not providing references to peer-reviewed journals! Wink At the time of posting, I couldn't remember where I'd read that, but I figured it was common knowledge (big mistake). Two reasons: some old Unix systems apparently don't have $HOME set properly by default, so some people still seem to believe it is unreliable. And in some contexts (e.g. suid binaries), allowing the user to change his home directory is a security risk, not a feature. Although this doesn't seem to apply to UQM at first glance, some SDL drivers (e.g. svgalib, DGA) require root privileges and are often run as root. In UQM you could easily exploit this to, for example, read and write other users' save games and configuration (although --configdir already allows this).

However, you still seem to be using getpwuid wrong; getHomeDir in dirs.c is returning the user name, not the home directory, as far as I can tell. Of course, since SDL seems to break when I unset $HOME, I'm not sure it matters.
« Last Edit: September 07, 2005, 07:20:11 pm by Novus » Logged

RTFM = Read the fine manual.
RTTFAQ = Read the Ur-Quan Masters Technical FAQ.
meep-eep
Forum Admin
Enlightened
*****
Offline Offline

Posts: 2847



View Profile
Re: Where are the save files?
« Reply #21 on: September 07, 2005, 07:27:54 pm »

A lot of thought and discussion has gone into the decision to use %APPDATA% and %USERPROFILE% as fallbacks. It's the best we can do as it is the most portable way (within Windows versions) to get to these locations.
SHGetFolderPath is in a redistributable DLL, according to this and is compatible with any Windows 95 compatible system and recommended according to this. I'm not quite sure why you find it problematic, and using it ought to have prevented Arael's problem.
It's been a long while since I looked at this, so I don't remember all the details. However, the #sc2 channel logs provided this bit:
Quote
03:06 < fOSSiL> hmm, why was the SHGetFolderPath call removed?
03:07 <@Meep-Eep> VC6 users couldn't compile it.
03:08 < fOSSiL> bah, they prolly need platform sdk ;P
03:08 <@Meep-Eep> Some .lib file that they didn't have. It was more trouble then it was worth. It should work pretty well without it now though
There's been a lot more discussion before and after this, but this fragment pretty much summarises it.
The idea was that for those systems that don't have %APPDATA% or %USERPROFILE% it was acceptable to store the user data in the UQM program directory.

Quote
Quote
On *nix systems, it's much easier. Reading $HOME to determine the home dir definately the right way to go. It's guaranteed by POSIX to be set on login, while it can be overridden by users who know what they're doing (think live cds, usb sticks, etc). The only reason there is a fallback for getpwuid() at all is for some support of buggy programs (such as the MacOS launcher apparently, though I think that may be fixed by now).
Why did you say it is not a good idea in the first place? It may help if you argument claims in the future so your readers don't have to explicitely ask for them btw.
Sorry for not providing references to peer-reviewed journals! Wink I wasn't aware that POSIX mandated this; some old Unix systems apparently don't have $HOME set properly by default. I just remembered reading somewhere a few weeks ago about that, but I don't remember where. I should have checked this before posting.
Well, after saying that <something> is a bad idea, the response 'why?' should be expected. Without an argumentation, the statement is worthless. I don't see any reason why a writer shouldn't add that argumentation in the first place, unless there's a reason to stall.

Quote
However, you still seem to be using getpwuid wrong; getHomeDir in dirs.c is returning the user name, not the home directory, as far as I can tell.
Indeed, thanks. It's fixed in CVS now. I'm not surprised noone ever run into this though.
Logged

“When Juffo-Wup is complete
when at last there is no Void, no Non
when the Creators return
then we can finally rest.”
Novus
Enlightened
*****
Offline Offline

Gender: Male
Posts: 1938


Fot or not?


View Profile
Re: Where are the save files?
« Reply #22 on: September 07, 2005, 07:50:05 pm »

Well, after saying that <something> is a bad idea, the response 'why?' should be expected. Without an argumentation, the statement is worthless. I don't see any reason why a writer shouldn't add that argumentation in the first place, unless there's a reason to stall.
For crying out loud, Meepy, I'm just trying to help! Sad I'm aware that criticising someone's work without an explanation is unhelpful (and likely to be incorrect, too). I just don't always have time to write out well-thought-out essays and justifications for every single point I make, you know. I admit an explanation would have been justified here. To avoid any further unproductive discussion on this subject, I'll just state that you're right about this, my mistake, sorry.

It's been a long while since I looked at this, so I don't remember all the details. However, the #sc2 channel logs provided this bit:
Quote
03:06 < fOSSiL> hmm, why was the SHGetFolderPath call removed?
03:07 <@Meep-Eep> VC6 users couldn't compile it.
03:08 < fOSSiL> bah, they prolly need platform sdk ;P
03:08 <@Meep-Eep> Some .lib file that they didn't have. It was more trouble then it was worth. It should work pretty well without it now though
There's been a lot more discussion before and after this, but this fragment pretty much summarises it.
The idea was that for those systems that don't have %APPDATA% or %USERPROFILE% it was acceptable to store the user data in the UQM program directory.
OK, so the only real problem here was that the fallback to the UQM program directory was writing to "..\userdata" instead of "userdata", and the reason for using the environment variables is that it removes a non-standard library dependency. I read the explanation in dirs.c to mean that SHGetFolderPath doesn't work on some Windows versions.
Logged

RTFM = Read the fine manual.
RTTFAQ = Read the Ur-Quan Masters Technical FAQ.
meep-eep
Forum Admin
Enlightened
*****
Offline Offline

Posts: 2847



View Profile
Re: Where are the save files?
« Reply #23 on: September 07, 2005, 08:23:51 pm »

Well, after saying that <something> is a bad idea, the response 'why?' should be expected. Without an argumentation, the statement is worthless. I don't see any reason why a writer shouldn't add that argumentation in the first place, unless there's a reason to stall.
For crying out loud, Meepy, I'm just trying to help! Sad I'm aware that criticising someone's work without an explanation is unhelpful (and likely to be incorrect, too). I just don't always have time to write out well-thought-out essays and justifications for every single point I make, you know. I admit an explanation would have been justified here. To avoid any further unproductive discussion on this subject, I'll just state that you're right about this, my mistake, sorry.
It's OK. Just let me explain my response. I don't mind being told I'm wrong. In fact I encourage criticism. But when you tell me I am wrong without telling me why, not only are you suggesting that it it obvious that I am wrong, but you also put me in the position of having to ask why it is obvious that I am wrong. And if I have to that deep in the defensive, I'd rather do it in such a way in which I end up on top. Hence my sharp response, for which I apologise.
Logged

“When Juffo-Wup is complete
when at last there is no Void, no Non
when the Creators return
then we can finally rest.”
Novus
Enlightened
*****
Offline Offline

Gender: Male
Posts: 1938


Fot or not?


View Profile
Re: Where are the save files?
« Reply #24 on: September 07, 2005, 08:40:35 pm »

Right... Trying to get this discussion back on track, may I suggest that the installation program would allow the user to choose where the configuration files are saved. The default could be ~/.uqm or %APPDATA%/uqm as before, but the user could easily override this while installing and get shortcuts that override the default without manually setting UQM command line arguments. I think that would make the "put everything in my UQM directory" brigade happy without even adding anything to UQM itself.
Logged

RTFM = Read the fine manual.
RTTFAQ = Read the Ur-Quan Masters Technical FAQ.
meep-eep
Forum Admin
Enlightened
*****
Offline Offline

Posts: 2847



View Profile
Re: Where are the save files?
« Reply #25 on: September 07, 2005, 10:43:46 pm »

Brigade? I actually suspect this will help a handful of people, while making live more difficult for those of us who answer questions like "Where are my saved games". And the people who won't be able to find out about the command line switch (which could be in the setup menu in the future) are exactly the people whom you shouldn't ask during install where they want to have their config data put.
Logged

“When Juffo-Wup is complete
when at last there is no Void, no Non
when the Creators return
then we can finally rest.”
Novus
Enlightened
*****
Offline Offline

Gender: Male
Posts: 1938


Fot or not?


View Profile
Re: Where are the save files?
« Reply #26 on: September 08, 2005, 09:58:37 am »

Brigade? I actually suspect this will help a handful of people, while making live more difficult for those of us who answer questions like "Where are my saved games". And the people who won't be able to find out about the command line switch (which could be in the setup menu in the future) are exactly the people whom you shouldn't ask during install where they want to have their config data put.
OK, more like a squad, then. Smiley Maybe changing the default directory to one that is easier to find (e.g. "My Documents\uqm") would be the best solution, then. Of course, that would mean that "Where are my saved games?" would invariably lead to the counter-question "Which version of UQM do you have?".

Another option is to have the installer put a shortcut to the UQM configuration directory somewhere easy to find (if we have a Start menu subfolder, I'd put it there), and leave the configuration where it is.
Logged

RTFM = Read the fine manual.
RTTFAQ = Read the Ur-Quan Masters Technical FAQ.
pcalvin76
Guest


Email
Re: Where are the save files?
« Reply #27 on: September 12, 2005, 05:04:36 pm »

I read through the thread and no files were found on the C drive, even with hidden folders included. keys.cfg, application datd with any Rockstar files/folders...etc.
Any other place the saved games could be?

Paul


Logged
meep-eep
Forum Admin
Enlightened
*****
Offline Offline

Posts: 2847



View Profile
Re: Where are the save files?
« Reply #28 on: September 12, 2005, 05:09:06 pm »

What version of Windows do you run?

(And UQM has nothing to do with Rockstar)
Logged

“When Juffo-Wup is complete
when at last there is no Void, no Non
when the Creators return
then we can finally rest.”
Novus
Enlightened
*****
Offline Offline

Gender: Male
Posts: 1938


Fot or not?


View Profile
Re: Where are the save files?
« Reply #29 on: September 12, 2005, 06:23:03 pm »

(And UQM has nothing to do with Rockstar)
Grand Theft Starship! A group of inmates locked up for life on Vela Penitentiary, led by a man known only as Zelnick, bust out and grab a Precursor service vessel. Warping back to his 'hood, Zelnick finds the Ur-Quan gang has trashed the place and locked up all but a few of his homies. This is the start of a tale of crime of intergalactic proportions as Zelnick has to steal, murder and intimidate for his gang to regain its freedom and respect.
Logged

RTFM = Read the fine manual.
RTTFAQ = Read the Ur-Quan Masters Technical FAQ.
Pages: 1 [2] 3 Print 
« previous next »
Jump to:  


Login with username, password and session length

Powered by MySQL Powered by PHP Powered by SMF 1.1.21 | SMF © 2015, Simple Machines Valid XHTML 1.0! Valid CSS!