.com.unity Forums

.com.unity Forums (http://forum.shrapnelgames.com/index.php)
-   Space Empires: IV & V (http://forum.shrapnelgames.com/forumdisplay.php?f=20)
-   -   PBW Server and Client for SE5 (http://forum.shrapnelgames.com/showthread.php?t=31503)

Combat Wombat October 31st, 2006 10:49 PM

PBW Server and Client for SE5
 
CaptRR on #spaceempires has allowed me to distribute the client and server he created for a SE5 PBW, he created it purly for personal use for a game with his brother but he realizes that others may be interested in using it. I hope that this one day leads to a central PBW server like we have for SE4 right now.

19:27] CaptRR: its also pretty buggy, so it will probably have some crashing issues if everythings not like its suppose to be
[19:28] CaptRR: thats what I get for creating a vb program after too many drinks
[19:28] CaptRR: :p
[19:31] CaptRR: also one more note (like I said this thing is still pretty beta), you need a C:/Temp directory, otherwise it will cause problems, this is a remnent of some old code, that I am getting rid of in the next build
[19:31] CaptRR: thats for the client
[19:33] CaptRR: oh and one last thing (sorry to keep adding stuff to this, this is the first time I am giving the code out, so havn't written all this down like I should have), on the server, do no use the se5 save directory as the save game directory
[19:34] CaptRR: since I the program moves the files in and out of the se5 savegame directory for processing
[19:34] CaptRR: and then cleans up after itself once the turn has processed

They are written in vb.net you need the .net framework 2.0. I haven't setup a server to test it yet but I looked at the code and it seems like it should work but then again I don't know VB so who knows lol.

Server:
http://www.secenter.org/SE5PBWPreBetaServer.zip
Client:
http://www.secenter.org/SE5PBWPreBetaClient.zip

aegisx October 31st, 2006 10:53 PM

Re: PBW Server and Client for SE5
 
Will this allow us to run hands off games yet?

CaptRR October 31st, 2006 10:56 PM

Re: PBW Server and Client for SE5
 
If by, hands off games, you mean submit a turn, and the server takes care of the rest, then yes, it does.

Combat Wombat October 31st, 2006 10:56 PM

Re: PBW Server and Client for SE5
 
yes that is what it is supposed to do

CaptRR October 31st, 2006 10:59 PM

Re: PBW Server and Client for SE5
 
Also, I would like to make, a note, you still need an ftp server, so that the client has a place to send the files too.

I am working on a order of events, but that will take a few minutes to write up.

CaptRR October 31st, 2006 11:32 PM

Re: PBW Server and Client for SE5
 
Order of events, for the little se5 server and client that I made.


Here is the setup:


Server:

Running an ftp server

Running SE5 Server Lite software

FTP maps to C:\SE5PBW\ (i.e when you log into the ftp server it you see the contents of C:\SE5PBW\), this is what I call our working directory. Do not have this the same as your normal SE5 save directory.

A Copy of Space Empires 5 installed, and in good working order (don’t forget patches)




Client

A working copy of space empires 5 installed and in good working order

A copy of SE5 PBW Client Lite software

Have already edited the localsettings.xml file that is in the same directory as the PBW client software

Have a directory call C:\Temp\


Here’s what the System does:

1. Administrator creates a new directory in the C:\SE5PBW\ directory i.e. C:\SE5PBW\MPGame\ . This Directory name will go into <pbwserverdirectory>/MPGame<pbwserverdirectory> in the clients localsettings.xml



2. The Administrator puts the created .gam file into the C:\SE5PBW\MPGame\ Directory. Lets say the filename was call MPGame.gam , you would then place <savegamename>MPGame</savegamename> (notice its without the .gam extension), into the localsettings.xml of the client.


3.The Client, would then start up the PBW client software.

a.Software connects to the server and grabs a copy of gamesettings.xml, that was created by the server automatically. This tells the client when the next turn is. If the servers next turn time is different than what the client has archived, then it means a new turn has posted. If the times are the same, you are presented with a dialog that tells you no new turn.

b.If a new turn has posted it makes the Run Turn button available

c.When the Run Turn Button is pushed, The client downloads the .gam file and any other associated files (combat files, movement, ect).

d.The client the then starts up Space Empires 5.

e.The User must load the downloaded game (I am trying to find a way for this to be automated, but as yet, I have had very little luck), and dial his password.

f.After you have done your turn, press end turn.

g.The Client then uploads the .plr file and disables the run turn button.

i.You must restart the client for it to read the correct turn, sorry this is a bug and it will be fixed.


4. The Server now has the files from all the players (or the time has run out)

a.The Server copies the .plr files and the .gam file to the SE5 savegame directory.

b.SE5 runs the turn via the command line.

c.SE5 Creates a new .gam file, and its associate files

d.These files are moved to the C:\SE5PBW\MPGame\Folder

e.The game gameinfo.xml file Is appended with the time for the next turn.

5.The process starts over again from Step 3 every time there is a turn.

CaptRR October 31st, 2006 11:35 PM

Re: PBW Server and Client for SE5
 
1 Attachment(s)
Here is a word document order of events, its much more readable.

CaptRR October 31st, 2006 11:40 PM

Re: PBW Server and Client for SE5
 
I probably should have noted that this is using .net framework 2.0

aegisx November 1st, 2006 10:47 PM

Re: PBW Server and Client for SE5
 
I meant using it to test AI/custom empires without sitting there hitting end turn or writing a macro to send the keys http://forum.shrapnelgames.com/images/smilies/happy.gif

capnq November 13th, 2006 07:58 PM

Re: PBW Server and Client for SE5
 
< bump > in response to query in other thread


All times are GMT -4. The time now is 07:50 AM.

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