UAC and multiple datadirs in Windows, pt 2 - Page 5

UAC and multiple datadirs in Windows, pt 2

Discuss the source code and development of Spring Engine in general from a technical point of view. Patches go here too.

Moderator: Moderators

Auswaschbar
Spring Developer
Posts: 1254
Joined: 24 Jun 2007, 08:34

Re: UAC and multiple datadirs in Windows, pt 2

Post by Auswaschbar »

I just commited the patch, the datadirs are checked in the following order:
  • config variable (registry)
  • binary directory
  • my documents
  • app data
  • environemnt variable
  • compiler flags
If a directory doesn't exists, spring will simply ignore it (and won't create it).
reivanen
Posts: 180
Joined: 12 Feb 2008, 15:52

Re: UAC and multiple datadirs in Windows, pt 2

Post by reivanen »

Why is it my documents and not where it is supposed to be: my documents/my games/ ?
imbaczek
Posts: 3629
Joined: 22 Aug 2006, 16:19

Re: UAC and multiple datadirs in Windows, pt 2

Post by imbaczek »

my games is not a standard place, therefore people not using english versions of windows won't have it (or will have it, but with a different name.)
reivanen
Posts: 180
Joined: 12 Feb 2008, 15:52

Re: UAC and multiple datadirs in Windows, pt 2

Post by reivanen »

i'm pretty sure my games has a %path% just like %documents%, no ?

A properly configured application uses my documents, a properly configured game uses my documents/my games/ as their home for user environment. /appdata is used for temp, working files and similar, and therefore i think its silly to include user files to be optionally over there.

change my documents to my games, and appdata to users/public, and it should be fine.
imbaczek
Posts: 3629
Joined: 22 Aug 2006, 16:19

Re: UAC and multiple datadirs in Windows, pt 2

Post by imbaczek »

reivanen wrote:change my documents to my games, and appdata to users/public, and it should be fine.
you're assuming vista, I guess. I don't have vista, but if those paths are accessible there through environment variables or other means, I'm for adding them if they exist.
Auswaschbar
Spring Developer
Posts: 1254
Joined: 24 Jun 2007, 08:34

Re: UAC and multiple datadirs in Windows, pt 2

Post by Auswaschbar »

I followed this guideline: http://msdn.microsoft.com/en-us/library ... S.85).aspx, and a "my games" is not mentioned anywhere. But if you know a variable for this, feel free to post it here.

Also, appdata is not used for temporary data, but
User Account Control for Game Developers wrote:Game files that can be created by a user and read by all users. Write access is granted only to the creator of the file
so in my opinion its a great place to put maps and mods in (unlike the base/springcontent etc., which should go in Program Files).
User avatar
AF
AI Developer
Posts: 20687
Joined: 14 Sep 2004, 11:32

Re: UAC and multiple datadirs in Windows, pt 2

Post by AF »

Are we also forgetting to append spring/ to the end? we dont want to have maps mods and other spring folders polluting the my games folder getting in the way of other games ^_^

btw

http://msdn.microsoft.com/en-us/library ... S.85).aspx

Image
User avatar
momfreeek
Posts: 625
Joined: 29 Apr 2008, 16:50

Re: UAC and multiple datadirs in Windows, pt 2

Post by momfreeek »

Auswaschbar wrote:I just commited the patch, the datadirs are checked in the following order:
  • config variable (registry)
  • binary directory
  • my documents
  • app data
  • environemnt variable
  • compiler flags
If a directory doesn't exists, spring will simply ignore it (and won't create it).
does this still work as explained here?
what is the registry key? environment variable?
Post Reply

Return to “Engine”