|
|
|
|
|
Re: m and h files merger tool |
Mon, 13 February 2012 06:10 |
|
|
I always remember this when my new games start... Ron, any chance you'll release it?
Just curious if the hold up is on account of it taking a lot of time to implement or if there are some security issues?
Any rough idea, how long would it take if you can take out dedicated time to do it?
I know my minefields.. but I'm a chaff sweeper.
I used to curse when I got stuck in traffic... till I realised I AM traffic.Report message to a moderator
|
|
|
|
|
|
|
|
Re: m and h files merger tool |
Wed, 28 March 2012 12:03 |
|
|
/drool.
And this despite the fact that it will actually be used more against me, than by me.
Report message to a moderator
|
|
|
|
|
|
|
Re: m and h files merger tool |
Thu, 30 May 2013 10:37 |
|
Ron | | Commander Forum Administrator Stars! AutoHost Administrator | Messages: 1231
Registered: October 2002 Location: Collegedale, TN | |
|
nmid wrote on Mon, 13 May 2013 08:44Yearly bump... slightly late
Any other known/reliable coders who could possibly help out, in the roll out of this tool?
I've never heard back from XyliGUN (that I know of) addressing my concerns about a way it could crash AutoHost.
See the quote below:
Ron wrote on Sun, 25 March 2012 21:29The Host Utility interface is done for the turn merge utility. (just hidden at the moment)
It lets the host pick which player is on what team, then writes that info to an .ini file that the utility uses when it runs.
The code to actually call the utility is complete and I've tested it.
Currently, the utility gives a non-zero run level error when a team member did not submit an .x file before the turn gen. This currently 'crashes' Stars! AutoHost. I have emailed XyliGUN about this and offered several suggestions about how to handle it and other issues.
In fact, XyliGUN has not logged into this forum since April 13, 2012. If he is no longer around, then the only thing I can do is check that all .x files are present before turn merge. If not all .x files present, then cannot do turn merge.
Ron Miller
Stars! AutoHostReport message to a moderator
|
|
|
Re: m and h files merger tool |
Thu, 30 May 2013 10:50 |
|
Ron | | Commander Forum Administrator Stars! AutoHost Administrator | Messages: 1231
Registered: October 2002 Location: Collegedale, TN | |
|
Actually, the turn merge tool gives a non-zero run level error for other problems besides missing .x file(s). When this happens, as I recall, it actually crashes Wine itself. If any of you are familiar with Linux and Wine and want to help me with this, please contact me.
The code I'm using to handle this in PERL is:
@command = ("cd /stars/games/$game_name; /usr/bin/wine \"/stars/prog/sahturnmerger.exe\" $game_name-turn-merge.ini >> /stars/games/$game_name/turn-merge-error.log 2>&1");
&handle_sys;
#
# Function: handle_sys
#
# Purpose: Handle system calls, and their error messages.
#
#
sub handle_sys {
$e_flag = 0;
AGAIN:
$rc = 0xffff & system @command;
if ($rc == 0) {
$error_flag = 0;
# print "handle_sys: exit 0\n";
}
elsif ($rc == 0xff00) {
# print STDOUT "handle_sys: exit 0xff00\n";
printf "system(%s) returned %#04x: ", "@command", $rc;
print "command failed: $!\n";
if ($error_flag == 1) {
if ($e_flag == 0) {
print "Trying again after 20 seconds.\n";
sleep(20);
$e_flag = 1;
goto AGAIN;
}
# print STDOUT "handle_sys: error_flag == 1...exiting\n";
exit;
}
# print STDOUT "handle_sys: error_flag != 1... exiting\n";
exit;
}
elsif ($rc > 0x80) {
# print STDOUT "handle_sys: exit 80\n";
printf "system(%s) returned %#04x: ", "@command", $rc;
print "ran with non-zero exit status $rc\n";
# print STDOUT "handle_sys: exiting\n";
exit;
}
else {
printf "system(%s) returned %#04x: ", "@command", $rc;
print "ran with ";
if ($rc & 0x80) {
$rc &= ~0x80;
print "coredump from ";
}
print "signal $rc\n";
# print STDOUT "handle_sys: exiting\n";
exit;
}
}
I'm willing to work on this again. It's 99% complete, but I can't have it crashing the whole system if it has a non-zero run-level error.
nmid, send me a small test game, 4 players, 2 teams. In the email, specify which player is on which team. We'll test this out.
[Updated on: Thu, 30 May 2013 10:55]
Ron Miller
Stars! AutoHostReport message to a moderator
|
|
|
|
|
Re: m and h files merger tool |
Fri, 05 July 2013 19:01 |
|
Ron | | Commander Forum Administrator Stars! AutoHost Administrator | Messages: 1231
Registered: October 2002 Location: Collegedale, TN | |
|
Test game made, 4 players, nmid is testing various things with the merger utility.
I'm coding stuff in Host Utility and SAH scripts to handle merging, and I can turn on the ability for hosts to use merging now. By default, merging is turned off, and hosts can request that it be turned on.
Still to do:
- Add code to ensure all .x files in place when merging active. (If not all present, then the merge utility will crash SAH.)
- Add option to gen turn but turn off merging for that turn if now all .x files present.
- Code merger notification on game page and turn gen emails, so players will be aware of what other players are on their team and sharing data. Players on a team will not be told who are on other teams.
[Updated on: Fri, 05 July 2013 19:01]
Ron Miller
Stars! AutoHostReport message to a moderator
|
|
|
|
|
Re: m and h files merger tool |
Wed, 24 July 2013 14:31 |
|
XyliGUN | | | Messages: 325
Registered: July 2004 Location: Russia, St.Petersburg |
|
|
Fixed version of SAH turn merger was sent to Ron.
* error level is always 0, and error message can be found in output
* m files with multiple turns supported
* optional minefields merge works
* optional packets merge works
* optional wormhole merge works
Things not yet implemented:
* optional fleets merge
Offtopic:
I'm apologise for being away and not replying for so long time. But a real life pressure was too high for the last year. Including such things like a new job, new home, some health problems, etc, etc, etc. But, after all, it's more or less back to normal now. So, let keep going!
PS: I found 5000 messages related to Stars! in my mailbox after not cheking it within a year.
"Progress isn't made by early risers. It's made by lazy men trying to find easier ways to do something."
Robert A. Heinlein, Time Enough For LoveReport message to a moderator
|
|
|
|