.com.unity Forums
  The Official e-Store of Shrapnel Games

This Month's Specials

Raging Tiger- Save $9.00
winSPMBT: Main Battle Tank- Save $5.00

   







Go Back   .com.unity Forums > Illwinter Game Design > Dominions 3: The Awakening

Reply
 
Thread Tools Display Modes
  #1  
Old January 14th, 2007, 02:09 PM
Psientist's Avatar

Psientist Psientist is offline
Sergeant
 
Join Date: Apr 2004
Location: Tampa Bay, Florida, USA
Posts: 327
Thanks: 5
Thanked 33 Times in 11 Posts
Psientist is on a distinguished road
Default Command Line Switches - revisited

It's been posted that to get a list of command line switches, one needs only to run (from the command line):
Quote:
> dom3 -h
However, I'm having trouble generating command line options in the Mac OSX.

To run an application from the command line in OSX (Terminal), one types (for example):
Quote:
> open /Applications/Games/Dominions3/Dominions3.app
However, the following throws an error:
Quote:
> open /Applications/Games/Dominions3/Dominions3.app -h
Any suggestions on how to do this on the Mac? And if it works, how to set it as a permenant command-line setting whenever the game is run?
Reply With Quote
  #2  
Old January 14th, 2007, 03:35 PM
Olive's Avatar

Olive Olive is offline
Sergeant
 
Join Date: Nov 2004
Location: Montpellier, France
Posts: 208
Thanks: 3
Thanked 2 Times in 2 Posts
Olive is on a distinguished road
Default Re: Command Line Switches - revisited

Doesn't seem to work on windows too.
Reply With Quote
  #3  
Old January 14th, 2007, 04:33 PM
Gandalf Parker's Avatar

Gandalf Parker Gandalf Parker is offline
Shrapnel Fanatic
 
Join Date: Oct 2003
Location: Vacaville, CA, USA
Posts: 13,736
Thanks: 341
Thanked 479 Times in 326 Posts
Gandalf Parker is on a distinguished road
Default Re: Command Line Switches - revisited

Short answer: You should find a stdout.txt in your dominions3 directory that has the -h output

Long answer: It does work but windows doesnt handle putting it to the screen the same way Linux does. Or actually I should say that WinNT or WinXP dont (Im guessing thats what you have since nothing showed up). The networking aspect of those two versions of windows, and no dos beneath them, sends the results to stndout.txt and stnderr.txt
__________________
-- DISCLAIMER:
This game is NOT suitable for students, interns, apprentices, or anyone else who is expected to pass tests on a regular basis. Do not think about strategies while operating heavy machinery. Before beginning this game make arrangements for someone to check on you daily. If you find that your game has continued for more than 36 hours straight then you should consult a physician immediately (Do NOT show him the game!)
Reply With Quote
  #4  
Old January 14th, 2007, 04:54 PM
Psientist's Avatar

Psientist Psientist is offline
Sergeant
 
Join Date: Apr 2004
Location: Tampa Bay, Florida, USA
Posts: 327
Thanks: 5
Thanked 33 Times in 11 Posts
Psientist is on a distinguished road
Default Re: Command Line Switches - revisited

I understand that theory, but it doesn't appear to work. Here is the full contents of the Dominions3 directory, including hidden files:

Quote:

/Applications/Games/Dominions 3$ ls -al
total 24
drwxr-xr-x 7 psientist admin 238 Jan 9 16:37 .
drwxr-xr-x 7 psientist admin 238 Jan 1 19:18 ..
-rw-r--r-- 1 psientist admin 6148 Jan 9 16:37 .DS_Store
drwxr-xr-x 3 psientist admin 102 Aug 29 14:46 Dominions3.app
dr-xr-xr-x 5 psientist admin 170 Aug 29 14:46 doc
The problem is that OSX is also throwing an error; the application never runs the command switch at all:

Quote:

/Applications/Games/Dominions 3$ open Dominions3.app -h
2007-01-14 14:51:33.735 open[4128] No such file: /Applications/Games/Dominions 3/-h

Now, we can try to be more savvy, and open up the OSX Dominion3.app executable (which is actually a directory bundle), and navigate to the application's core MacOS resource:

Quote:
cd Dominions3.app/Contents/MacOS
but the core executable there throws the exact same error:

Quote:
/Applications/Games/Dominions 3/Dominions3.app/Contents/MacOS$ open Dominions3 -h
2007-01-14 14:54:21.612 open[4132] No such file: /Applications/Games/Dominions 3/Dominions3.app/Contents/MacOS/-h

So apparently neither the Windows nor the MacOS command lines are behaving the way you expect. In fact, it *looks* like the Doms3 app is interpreting the "-h" flag as a filename argument, based upon the error response.
Reply With Quote
  #5  
Old January 14th, 2007, 06:36 PM
Olive's Avatar

Olive Olive is offline
Sergeant
 
Join Date: Nov 2004
Location: Montpellier, France
Posts: 208
Thanks: 3
Thanked 2 Times in 2 Posts
Olive is on a distinguished road
Default Re: Command Line Switches - revisited

@Gandalf Parker : Thanks, it works.
Reply With Quote
  #6  
Old January 15th, 2007, 12:46 AM

alexti alexti is offline
First Lieutenant
 
Join Date: Dec 2003
Location: Calgary, Canada
Posts: 762
Thanks: 0
Thanked 0 Times in 0 Posts
alexti is on a distinguished road
Default Re: Command Line Switches - revisited

I can't say about Mac OSX, but on Windows standard descriptors work the same way as on Linux/UNIX if the application is built as "console" application. If application is built as "Windows" application, standard output isn't going anywhere. The programmer need to reopen descriptors into some file. That's what Dom3 must be doing.
Reply With Quote
Reply

Bookmarks


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump


All times are GMT -4. The time now is 12:57 PM.


Powered by vBulletin® Version 3.8.1
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©1999 - 2025, Shrapnel Games, Inc. - All Rights Reserved.