diff options
author | jaybinks <jaybinks@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2007-12-20 22:53:06 +0000 |
---|---|---|
committer | jaybinks <jaybinks@b956fd51-792f-4845-bead-9b4dfca2ff2c> | 2007-12-20 22:53:06 +0000 |
commit | d808dde8310ecfd659d36bfe1ba77e76ea43b6c0 (patch) | |
tree | f543ce5b19adeb686d309f60117bdb550fc3a0e8 /Game/Code/Classes/UPlatformLinux.pas | |
parent | 8d367ca3e9d49fbac6798f5aad0be03f8e5cfeec (diff) | |
download | usdx-d808dde8310ecfd659d36bfe1ba77e76ea43b6c0.tar.gz usdx-d808dde8310ecfd659d36bfe1ba77e76ea43b6c0.tar.xz usdx-d808dde8310ecfd659d36bfe1ba77e76ea43b6c0.zip |
added -localpaths command line switch
so we dont always have to use the packaged locations.
( profox )
git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@737 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to 'Game/Code/Classes/UPlatformLinux.pas')
-rw-r--r-- | Game/Code/Classes/UPlatformLinux.pas | 16 |
1 files changed, 13 insertions, 3 deletions
diff --git a/Game/Code/Classes/UPlatformLinux.pas b/Game/Code/Classes/UPlatformLinux.pas index 03e04560..0098baee 100644 --- a/Game/Code/Classes/UPlatformLinux.pas +++ b/Game/Code/Classes/UPlatformLinux.pas @@ -27,6 +27,7 @@ implementation uses libc, + uCommandLine, {$IFNDEF FPC_V220} oldlinux, {$ELSE} @@ -123,17 +124,26 @@ end; function TPlatformLinux.GetLogPath : WideString; begin - result := '/var/log/UltraStarDeluxe/'; + if FindCmdLineSwitch( cUseLocalPaths ) then + result := inherited + else + result := '/var/log/UltraStarDeluxe/'; end; function TPlatformLinux.GetGameSharedPath : WideString; begin - result := '/usr/share/UltraStarDeluxe/'; + if FindCmdLineSwitch( cUseLocalPaths ) then + result := inherited + else + result := '/usr/share/UltraStarDeluxe/'; end; function TPlatformLinux.GetGameUserPath : WideString; begin - result := get_homedir()+'/.UltraStarDeluxe/'; + if FindCmdLineSwitch( cUseLocalPaths ) then + result := inherited + else + result := get_homedir()+'/.UltraStarDeluxe/'; end; function TPlatformLinux.get_homedir(): string; |