No screenies, as there's no GUI. All config is done by file. It's just a daemon that runs quietly.
OldBloke, I could do that, since it's easy enough to check if a user is an admin, but your commands would have to be echoed to everyone on the server, since the /mso command doesn't have the originating username as part of the packet, and /mso always sends an MSO packet, rather than an MSS, which does, even when you ask for MSS messages.
Basically, that leaves your options as follows: a) do a command that gets echoed to everybody, like saying "kick <user> <reason>" in a standard talk window, which everyone would see or b) use the /mso command with a password, like "/mso <pass> kick <user> <reason>".
The user could easily be notified via race control message or private message the reason for the kick/ban/whatever, if you don't mind them spectating for a few seconds while they're given time to read what the server is telling them before it actually disconnects them.
Tell me how you want it to work, and your wish is my command.
The pit window enforcement still doesn't work right, but I got the rotator working today, except for the time-based rotation, but you can have it rotate tracks after any number of races you like.
Eh, what the hell, here's the current state of things..see if you can make sense of it.
Get it in
tar.gz or
ZIP (not that it needs compression :shrug
The README:
LFS Server Utility
------------------
Copyright 2007, Nathan Mills <[email protected]>
This program uses InSim to (optionally) do the following things:
* Send a MOTD to the user on connect
* Limit races to certain users (to allow league races without passwords)
* Allow only racers who have driven the track in their chosen car before
* Allow only racers with a pb within a admin-configurable amount of the
world record at certain times of day
* Limits lfsworld queries to avoid tarpitting
It will shortly also:
* Enforce a pit window with time penalties, forced spectate, kicks, or bans
Prerequisites
-------------
An LFS server
A working Perl installation. ActivePerl may work for Windows users, but I
haven't tested it. If you decide to try it work Windows, let me know what
you find! :)
An lfsworld IdentKey, if you want to use the pb check
Perl Modules:
* POE
* POE::Component::Client::HTTP
* HTTP::Request
* Time::Period
Installation
------------
- Install the required Perl modules using RPM, CPAN, or however you do it on
your operating system. POE RPMs are available for FC5 from:
http://dries.ulyssis.org/rpm/
- I installed all of the perl-POE packages, but I have plenty of disk space.
- Obtain an IdentKey for lfsworld.
- Unpack the distribution archive.
- Edit the lfsutils.cfg file to your liking. Hopefully the comments are
enough to get you started.
- Edit the contents of the motd.txt and the admin_motd.txt file, or
create your own and change the filenames in lfsutils.cfg
- Start your LFS server's InSim function on the port you configured
in lfsutils.cfg
- Start the utils.pl program with 'perl utils.pl', double clicking
it on Windows, or however else you like.
Usage Notes
-----------
Currently, there is a bit of unexpected behavior with the track rotator,
specifically that if the cars you have configured to be active in the
utility are not available on the server when you first start the utility,
nobody will be able to race, since the utility will prevent racers from
joining the race with a car other than one you specified as allowed.
Secondly, if you typo the car names, the /cars command will fail on the
server, but the utility will think it went through, possibly causing
the aforementioned trouble where none of the cars you told the utility
to accept are active on the server.
If that happens, an admin can either configure the proper cars, or use
/cars all, although the utility will still limit the usable cars, at
least the ones that should be selectable will be.
Thirdly, be sure to use all caps for the car and track names.
Two other notes. Time based rotation isn't working yet, so don't
try it. It's mostly there, but nothing ever starts the timer
initially.
If the rotator is enabled, the utility will end the race immediately
after the last person has finished.
Lastly, watch for falling bugs! ;)
License
-------
Copyright (c) 2007 Nathan Mills <[email protected]>
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights to
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
of the Software, and to permit persons to whom the Software is furnished to do
so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.