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

This Month's Specials

Air Command 3.0- Save $12.00
War Plan Pacific- Save $7.00

   







Go Back   .com.unity Forums > Shrapnel Community > Space Empires: IV & V

Reply
 
Thread Tools Display Modes
  #11  
Old October 24th, 2003, 06:46 AM
Ruatha's Avatar

Ruatha Ruatha is offline
Major General
 
Join Date: May 2002
Location: Linghem, Östergötland, Sweden
Posts: 2,255
Thanks: 0
Thanked 0 Times in 0 Posts
Ruatha is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

Next to do:
Auto run batch file and auto update deadline.
History.


What has been fixed:
If you name the empires without player with player name "-" it won't be marked red and will be displayed with the name "(none)".
If the empire is dead name the player "-" and name the empire for example "Dead" or whatever.

(The " shouldn't be included in the textfile)

[ October 24, 2003, 06:43: Message edited by: Ruatha ]
Reply With Quote
  #12  
Old October 24th, 2003, 08:00 AM
Ruatha's Avatar

Ruatha Ruatha is offline
Major General
 
Join Date: May 2002
Location: Linghem, Östergötland, Sweden
Posts: 2,255
Thanks: 0
Thanked 0 Times in 0 Posts
Ruatha is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

It's not much time one has to edit the Posts in....

*For the auto turn I was plannng on making a dos or windows program that runs constantly and checks the current time and the deadlines in as many defined deadline.txt files as wanted, when a deadline is found it will run the game with files from that directory, game file and plr turn files.
move all plr files to a backupdirectory and zip a new turnfile and add it to the gamefile directory.
Update the deadline.txt.
Continue to check all defined deadlines.txt.

Either written in Turbo pascal (Dos) or Delphi (windows).
Support for Mods.
There won't be any auto mail function, for a long while.

*Will also add news section and web based admin possibility as alternative to current text file based.

Anyone wanting to write part or sections of the site are welcome, otherwise I'll do it as a continually thing, slowly..

Any suggestions or other ideas?

[ October 24, 2003, 07:31: Message edited by: Ruatha ]
Reply With Quote
  #13  
Old October 24th, 2003, 09:20 AM
Ruatha's Avatar

Ruatha Ruatha is offline
Major General
 
Join Date: May 2002
Location: Linghem, Östergötland, Sweden
Posts: 2,255
Thanks: 0
Thanked 0 Times in 0 Posts
Ruatha is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

Gosh, I hate the new "Edit time expired"!!

Changed "European standard time" to "Local server Time" on main page.

Will make auto app trayable.

Suggestions.

ver 1.01
Reply With Quote
  #14  
Old October 24th, 2003, 03:15 PM
Gandalph's Avatar

Gandalph Gandalph is offline
Captain
 
Join Date: Mar 2002
Location: Santa Cruz, CA
Posts: 947
Thanks: 0
Thanked 0 Times in 0 Posts
Gandalph is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

How to get the "Upload" section to show a player has uploaded his turn?

Also the download game file function is not working.

[ October 24, 2003, 14:27: Message edited by: Gandalph ]
__________________
All that is gold does not glitter,
Not all those who wander are lost;
The old that is strong does not wither,
Deep roots are not reached by the frost.

Reply With Quote
  #15  
Old October 24th, 2003, 03:27 PM
Fyron's Avatar

Fyron Fyron is offline
Shrapnel Fanatic
 
Join Date: Jul 2001
Location: Southern CA, USA
Posts: 18,394
Thanks: 0
Thanked 12 Times in 10 Posts
Fyron is an unknown quantity at this point
Default Re: Ruatha: PBW Alternate Scripts

I suggest you not have any code read in the contents of text files to get variables. Instead, have files like "config.php" and "playerdata.php". Reading from text files is relatively slow, and prone to error, much more so than just having .php files included. And, it still just requires editing files to be installed, so it is not that big a change for the user of the script.

Also, it would be good to be able to have all the main .php files in a folder, and then have various folders for different games in subfolders, with their appropriate config files and gamefile etc. folders. So you have something like:

se.net/pbw contains the pure code .php, with nothing specific to any game
se.net/pbw/b5modgame contains the mentioned config.php and playerdata.php, as well as its subfolders of gamefile, turnfiles, etc.

[ October 24, 2003, 14:30: Message edited by: Imperator Fyron ]
__________________
It's not whether you win or lose that counts: it's how much pain you inflict along the way.
--- SpaceEmpires.net --- RSS --- SEnet ModWorks --- SEIV Modding 101 Tutorial
--- Join us in the #SpaceEmpires IRC channel on the Freenode IRC network.
--- Due to restrictively low sig limits, you must visit this link to view the rest of my signature.
Reply With Quote
  #16  
Old October 24th, 2003, 03:48 PM
Ruatha's Avatar

Ruatha Ruatha is offline
Major General
 
Join Date: May 2002
Location: Linghem, Östergötland, Sweden
Posts: 2,255
Thanks: 0
Thanked 0 Times in 0 Posts
Ruatha is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

Quote:
Originally posted by Gandalph:
How to get the "Upload" section to show a player has uploaded his turn?

Also the download game file function is not working.
There has been changes made in this area today, do you have the latest files?

Fyron fixed an error where no gamefiles except those named NGC... could be downloaded!

I fixed an error where the check for uploaded files compensated wrongly for letter case, it should work now.
Reply With Quote
  #17  
Old October 24th, 2003, 03:49 PM
Ruatha's Avatar

Ruatha Ruatha is offline
Major General
 
Join Date: May 2002
Location: Linghem, Östergötland, Sweden
Posts: 2,255
Thanks: 0
Thanked 0 Times in 0 Posts
Ruatha is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

Quote:
Originally posted by Imperator Fyron:
I suggest you not have any code read in the contents of text files to get variables. Instead, have files like "config.php" and "playerdata.php". Reading from text files is relatively slow, and prone to error, much more so than just having .php files included. And, it still just requires editing files to be installed, so it is not that big a change for the user of the script.

Also, it would be good to be able to have all the main .php files in a folder, and then have various folders for different games in subfolders, with their appropriate config files and gamefile etc. folders. So you have something like:

se.net/pbw contains the pure code .php, with nothing specific to any game
se.net/pbw/b5modgame contains the mentioned config.php and playerdata.php, as well as its subfolders of gamefile, turnfiles, etc.
The multiple folder thing will be fixed to next Version (in a day or two)
Thanx for the suggestion.
About the PHP instead of txt, will think of a good way to fix that, should be doable without to much hassle.
How where you thinking, that I should include variables in include.php where all names etc are entered and then include that file into the main index.php with the include instruction? That seems easiest.
And then make a web page to enter and alter the data in text boxes, so that no real text editing is necessary. Will do this!

[ October 24, 2003, 15:00: Message edited by: Ruatha ]
Reply With Quote
  #18  
Old October 24th, 2003, 05:17 PM
Ruatha's Avatar

Ruatha Ruatha is offline
Major General
 
Join Date: May 2002
Location: Linghem, Östergötland, Sweden
Posts: 2,255
Thanks: 0
Thanked 0 Times in 0 Posts
Ruatha is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

Idea for new structure for next EPS (Emergency Pbw Site):


ELSEWHERE (OTHER DIRECTORY)
PASSWORD.CFG - Password for autoturn utility and main admin (Setup new games)

---------------
main Directory (Whatever name)

INDEX.PHP
Start page, choose game if more than one otherwise autodirect to MAIN.PHP

MAIN.PHP Main page where everything happens, display players, empires, uploaded, deadline, news, history.

GETTURN.PHP
Getturn script

SENDTURN.PHP
Sendturn Script

TIMEZONE.PHP
Displays deadline in different timezones, each player can check his timezone.

ADMIN.PHP
Admin script, change player names, empires, e-mails, number of players, admin password, news, turns to backup.

AUTOTURN.EXE
Checks if turns has expired or all has uploaded and then autoexecutes them if needed, updates deadlines, checks all subdirectories for DEADLINE.PHP.
Creates new games by setting up subdirectories and placing the appropriate files there.
Password used to access this program is stored in PASSWORD.CFG
Can be used to customize the sites, i e colours and any page image (Same image all pages).
Program is trayable.


-------------------
Game Directories (Name = Gamename, subdirectories)

GAMEINFO.PHP
Used to store game variables;
Number of players,
Playernames
E-mails
Empire name
Host name and e-mail.
News
Number of turns to backup
Timezone.

DEADLINE.PHP
File defining deadline and turn type (Manual, all uploaded and auto), Used in both PHP script and in AUTOTURN.EXE.
Date stored in Central European time, altered to the set timezone when displayed in each game.

TURNFILES
Directory for player turnfiles (PLR)

GAMEFILE
Directory for Gamefiles (ZIP)

BACKUP
Zipped old PLR and GAM files

[ October 24, 2003, 16:21: Message edited by: Ruatha ]
Reply With Quote
  #19  
Old October 24th, 2003, 05:56 PM
Ruatha's Avatar

Ruatha Ruatha is offline
Major General
 
Join Date: May 2002
Location: Linghem, Östergötland, Sweden
Posts: 2,255
Thanks: 0
Thanked 0 Times in 0 Posts
Ruatha is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

Now I see that it tries to send UPLOAD.PHP when getting the turnfile. Will fix this after work (approx 27 hours of work left first...)

Last time I managed to get rid of the PHP extension by changing the file type, but this latest verion adds upload as name, will have to check why.

EDIT:STRANGE, the next computer I tried here at work worx perfect, right filename and extension!!

EDIT AGAIN:
I have a clue:
It works great on the computer with a Swedish Version of Windows 2000 but not on the one with an English Win 2000, Why?????
So Fyron, when I use Swedish win 2000 or Win XP I can download the turnfile from your site without the PHP extension.
Will have to check this further!

[ October 24, 2003, 17:02: Message edited by: Ruatha ]
Reply With Quote
  #20  
Old October 24th, 2003, 06:35 PM
geoschmo's Avatar

geoschmo geoschmo is offline
National Security Advisor
 
Join Date: Jan 2001
Location: Ohio
Posts: 8,450
Thanks: 0
Thanked 4 Times in 1 Post
geoschmo is on a distinguished road
Default Re: Ruatha: PBW Alternate Scripts

Ruatha, fyi I am having the same problem with getting the game file on mine.

http://pbw.spaceempires.net/geoschmo/survivor2/

I got around it by modifing the index.php to look for the file directly instead of pulling up the upload.php file. But that's not a good permanent fix because I will have to modify the index file every turn.

Thanks so much for making these files available by the way. It's a big help.

What are the chances of adding a button to the index that will pull up a new email box and fill in all the player emails? It would make notifying them of a new turn very convienent. I guess you'd just need something to parse the player text file and populate a mailto command. Anyway, just a suggestion.

Geoschmo
__________________
I used to be somebody but now I am somebody else
Who I'll be tomorrow is anybody's guess
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 04:17 PM.


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