.com.unity Forums

.com.unity Forums (http://forum.shrapnelgames.com/index.php)
-   Dominions 3: The Awakening (http://forum.shrapnelgames.com/forumdisplay.php?f=138)
-   -   Starting a new game... (http://forum.shrapnelgames.com/showthread.php?t=30567)

Esben Mose Hansen October 1st, 2006 10:12 AM

Starting a new game...
 
Have anyone tried to start a new game from the command line, without any user interaction? Naively, I thought it could done with something like
<font class="small">Code:</font><hr /><pre>
dom2 --mapfile eye.map -g gamename
</pre><hr />
But that just gives
<font class="small">Code:</font><hr /><pre>
&amp;#65533;ot gick fel!
no fatherland file found
N&amp;#65533;ot gick fel!
no fatherland file found
</pre><hr />
This is really a snag for my new server, so please help http://forum.shrapnelgames.com/images/smilies/laugh.gif

Esben Mose Hansen October 2nd, 2006 02:00 PM

Re: Starting a new game...
 
Are there really no way to do this? *sniffs* Even in dom3?

thejeff October 2nd, 2006 02:59 PM

Re: Starting a new game...
 
I can't experiment with it now, but I don't think you want -g. That's the host switch, isn't it?

Johan K October 2nd, 2006 03:01 PM

Re: Starting a new game...
 
Yup -g is the host switch and should not be used for game createion. Starting a new game with switches only is not implemented unfortunatelly. But you might be able to get around that by start a tcp game and then quitting it and continue it as a e-mail game.

Esben Mose Hansen October 2nd, 2006 03:34 PM

Re: Starting a new game...
 
Quote:

Johan K said:
Yup -g is the host switch and should not be used for game createion. Starting a new game with switches only is not implemented unfortunatelly. But you might be able to get around that by start a tcp game and then quitting it and continue it as a e-mail game.

Most sad. So no way to make a pbm server :/ And I had a good part of the web frontend coded, too. Ah well.

Johan K October 2nd, 2006 04:20 PM

Re: Starting a new game...
 
I din't say there was no way. It might be possible if you use the tcp server stuff to create the game, which might be possible to do automatically. But I haven't tried it.

Gandalf Parker October 2nd, 2006 05:07 PM

Re: Starting a new game...
 
YAY!
HOORAH!
CHEERS!
After two days of playing with switches and the order of the switches THIS WORKED!

dom3 -ST --port 5432 --era 1 --mapfile eye.map --uploadtime 0 pbem

We are BACK in business!
Gandalf Parker

Gandalf Parker October 2nd, 2006 05:12 PM

Re: Starting a new game...
 
Even MORE good news!
This one also works! The other one should work for Dom2 but this one is Dom3 only

dom3 -STd --port 5432 --era 1 --mapfile eye.map --uploadmaxp 6 pbem

OK definetly leave off the -g
And the uploadmxp thing is a new switch (one which I requested) which allows you to set the number of players that a game can have. It will auto-start when it hits that number. It was mostly for things like small-map blitz games where you wanted them to choose any nation you wanted but you wanted the game to start after 2 people joined, or 3 people, or 4. You could even start a full game and use --noclientstart so that it would start automatically when the nations were full.

ANYWAY.. it will autostart the game. If you have 6 gods uploaded to the game dir, and set it for max 6 players, then it will check the files and start the game. YAY!

Taqwus October 2nd, 2006 05:17 PM

Re: Starting a new game...
 
Johan, you've been turned into a Monster Toad? I hope you get better soon. http://forum.shrapnelgames.com/images/smilies/wink.gif

Gandalf Parker October 2nd, 2006 05:30 PM

Re: Starting a new game...
 
So says the goose http://forum.shrapnelgames.com/images/smilies/happy.gif

The hardest part on ironing this out was getting past my thinking of the -g switch as being for naming the game. Well not the hardest part but that was my longest stupid roadblock. Definetly leave off the -g and put the game name at the end of the command string

Esben Mose Hansen October 2nd, 2006 05:41 PM

Re: Starting a new game...
 
Hey, that sounds good http://forum.shrapnelgames.com/images/smilies/happy.gif Can't be done with dom2, though.... there is no way to add the gods. Still, I should be able to complete the server pretty quickly once I have the game http://forum.shrapnelgames.com/images/smilies/happy.gif I think this server will be far better than the last one. At least, there shouldn't be a limit this time http://forum.shrapnelgames.com/images/smilies/happy.gif

a big thanks to Gandalf for doing the switch playing http://forum.shrapnelgames.com/images/smilies/happy.gif And Johan for adding that last critical switch http://forum.shrapnelgames.com/images/smilies/happy.gif

Gandalf Parker October 2nd, 2006 05:49 PM

Re: Starting a new game...
 
The first one, using uploadtime, should work with Dom2.
It would take me abit to test it though

Esben Mose Hansen October 3rd, 2006 09:05 AM

Re: Starting a new game...
 
Quote:

Gandalf Parker said:
The first one, using uploadtime, should work with Dom2.
It would take me abit to test it though

I tested it yesterday... it just waits for people to upload after the timeout, probably because there is no gods. If it didn't, I doubt it would auto-pickup the gods, unless there is something I am missing?

AMF October 3rd, 2006 09:19 AM

Re: Starting a new game...
 
So...does this mean that there's pretty definitely going to be a Dom 3 PBW server?

http://forum.shrapnelgames.com/images/smilies/happy.gif

Gandalf Parker October 3rd, 2006 12:27 PM

Re: Starting a new game...
 
Quote:

Esben Mose Hansen said:
Quote:

Gandalf Parker said:
The first one, using uploadtime, should work with Dom2.
It would take me abit to test it though

I tested it yesterday... it just waits for people to upload after the timeout, probably because there is no gods. If it didn't, I doubt it would auto-pickup the gods, unless there is something I am missing?

Did you leave off the -g?
And yes, there does have to be gods. What I did was create /savedgame/pbem directory and copy 6 god files to it. Then I ran that command.

I did do it with Dom3 which might make a difference. I was just figuring that since uploadtime existed in Dom2 that it might work there also.

Esben Mose Hansen October 3rd, 2006 01:50 PM

Re: Starting a new game...
 
Hey! Copying in .2h (god) files did the trick! Very nice http://forum.shrapnelgames.com/images/smilies/laugh.gif I still have to kill the manually, but no problem there. Thank you!

Gandalf Parker October 3rd, 2006 02:03 PM

Re: Starting a new game...
 
My startup script creates a kill script in the same directory as the game.

PID=`ps a | grep $GAME | grep dom3 | cut -d" " -f2`
echo "kill "$PID &gt;$DIR/kill.sh

That way to kill MyGame all I have to do is
savedgames/MyGame/kill.sh

You could add that to the post.sh but that doesnt seem to work on killing a game right after startup.

If you run the game with a -d to a log then you could watch for thing that says its watching for uploads and then run the kill command.

Esben Mose Hansen October 3rd, 2006 02:30 PM

Re: Starting a new game...
 
Killing it is not a problem, I'll just watch out for something suitable on stdout and kill it when I get it.

And yes, I am working on a pbm server. Whether it will be finished before or after I get the game remains to be seen http://forum.shrapnelgames.com/images/smilies/happy.gif

Psientist January 14th, 2007 02:39 PM

Re: Starting a new game...
 
Esben - have you made any progress on a play-by-email-server? I was considering doing the same, perhaps with a web frontend (which I guess would make it a play-by-web server).

Gandalf Parker October 31st, 2009 12:42 PM

Re: Starting a new game...
 
I banged my head on this for days! I needed to do a pbem which I havent done in quite awhile. I found this thread where I proudly proclaimed that I had beat this problem. But it didnt work!

OK I know I am raising-from-the-dead an old thread (ironic that its Halloween today) but I will add an important note here.
the incoming gods must be renamed to not have numeric designators.
In other words early_fomoria_3.2h must be renamed to early_fomoria.2h

When the game was patched to allow us to create and save multiple gods in the same nation and same era by adding a numeric on the end of each one, the command-line recognition of those files was not updated. So apparently they must be renamed to the old style in order to start a pbem.

Gandalf Parker

llamabeast October 31st, 2009 01:12 PM

Re: Starting a new game...
 
This is a strange thing to post today. I think it was probably you who told me this three years ago!

Gandalf Parker October 31st, 2009 07:56 PM

Re: Starting a new game...
 
Yes but I have a crappy memory. Especially for things I dont use all the time. I figured it out, then forgot it. I need to put things someplace like this where I can find them later.

BTW what program are you using for attachments?

llamabeast October 31st, 2009 09:23 PM

Re: Starting a new game...
 
Oh, some perl module. The whole e-mail processing stuff is some perl module.


All times are GMT -4. The time now is 09:41 PM.

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