Server commands and such

Post your suggestions here
Stormz
Posts: 2015
Joined: Wed May 12, 2010 7:52 pm
Location: US of A
Contact:

Server commands and such

Post by Stormz »

Would it be at all possible to have command that goes through the listplayers and finds a specific name/number then lists their name, UID, and slot? Or, if you could make it so you could toggle that info on/off when you are watching someone that way, if they are wreaking havoc, you don't have to sift through upwards of 40-160 players to find this info?

Also, it would be nice if admins could do server,serverreset or similar to reset the server. That way you don't have to go to an FTP client to restart the server if something is glitching or you add something to the serverargs. Idk how time consuming this is, so don't hate me! Lol

Is there a way to make a server "whitelist" only? Basically, on certain people can connect to it. Would it be possible to hook this up to a site to allow the website to sift through the restrictions set by the people in charge? For example if you have a server specifically for Pro/A riders, can you hook it up to the rf site to allow it to only allow those with a Pro/Am license to connect, and vice versa with B/C license?

One last thing, I feel that 00, 01, and 03 need more mods to sift out the people who are talking trash, making derogatory comments and just general mischief that makes people not want to play. Also, it'd be nice so that you don't have to wait an hour between restarts. Obviously, this requires the trust of you, so I leave this in your hands, as there aren't many in the community whom I'd trust if I were you either.
tyskorn
Posts: 6491
Joined: Sun Jan 11, 2009 5:52 pm
Team: Adept MX Graphics
Location: Utah, USA

Re: Server commands and such

Post by tyskorn »

You can do searches in listplayers. You might already know that, but it doesn't seem like you do from what I got out of the first thing. :lol: You can just do "server, listplayers alex" and it will show everyone with "alex" in their name. I don't know if that shows the slot or not, but I know it shows the UID.
mxchild
Posts: 300
Joined: Tue Aug 21, 2012 8:45 am
Team: Batman motorsport

Re: Server commands and such

Post by mxchild »

dont give admin, marshall is fine for moderating a server. i think thats what marshall was designed for anyway (to marshall the server) and with marshall you cant go wrecking anything, if im correct.
jlv
Site Admin
Posts: 14930
Joined: Fri Nov 02, 2007 5:39 am
Team: No Frills Racing
Contact:

Re: Server commands and such

Post by jlv »

"listplayers" already has a search parameter.

For resetting the server, I run the server from a script like this (name it "runforever.sh"):

Code: Select all

#!/bin/bash

cmd=$1
shift

while true
do
        "$cmd" "$@"
        sleep 10
done
Invoke it like this: nohup ./runforever.sh ./mxserver --args-file mxserver-stockargs.txt >>log-stockserver &

Then as an admin you can do "server,shutdown" and the server will automatically restart in 10 seconds.

For the whitelist, use reserved slots.

Check the README.TXT file. There's a lot of info in there.

As for the mods, I'd like more but it's hard to find good ones. If you aren't a marshal already send me your UID.
Josh Vanderhoof
Sole Proprietor
jlv@mxsimulator.com
If you email, put "MX Simulator" in the subject to make sure it gets through my spam filter.
bdownen323
Posts: 2949
Joined: Mon Nov 28, 2011 11:00 pm

Re: Server commands and such

Post by bdownen323 »

Say I were to do a list of reserved slots for my server. How would it be possible to make sure only the people with reserved slots get in?
jlv
Site Admin
Posts: 14930
Joined: Fri Nov 02, 2007 5:39 am
Team: No Frills Racing
Contact:

Re: Server commands and such

Post by jlv »

Read the README!

server,maxclients <max> [reserved]
Sets the maximum number clients and optionally the number of slots set
aside for reserved UIDs.

server,reserve <UID or ALL>
Adds a UID to the reserved list. If ALL, it will reserve the UIDs of
all currently connected clients.

server,unreserve <UID or ALL>
Removes a UID to the reserved list. If ALL, it will clear the
reserved list.

server,maxclients 40 40
server,reserve 176
server,reserve 323
etc.
Josh Vanderhoof
Sole Proprietor
jlv@mxsimulator.com
If you email, put "MX Simulator" in the subject to make sure it gets through my spam filter.
bdownen323
Posts: 2949
Joined: Mon Nov 28, 2011 11:00 pm

Re: Server commands and such

Post by bdownen323 »

Awh man never saw that in the readme to be honest! Thanks, this will be helpful for Elsinore!
kawy949
Posts: 977
Joined: Sat Feb 11, 2012 11:33 pm
Location: UK
Contact:

Re: Server commands and such

Post by kawy949 »

The only thing I am yet to understand is how to ghost lappers when they are a certain distance behind the leader. The readme is a little confusing on that part?
yzmxer608
Posts: 15352
Joined: Mon Dec 29, 2008 4:30 am
Team: SYS
Location: Wisconsin, U.S.A

Re: Server commands and such

Post by yzmxer608 »

That's only for riders who can be considered off the track or stopped, not just lappers.
--off-course-bias <bias>
--off-course-scale <scale>

This sets the amount of time a rider can be slower than the leader
before being considered off course. The time is computed as
"leader-time * off-course-scale + off-couse-bias". Default 10
second bias, 1.5x scale.
Pretty much the larger the overall result is of the calculation, the more time it takes for the rider to go invisible. The part I'm not sure about is if it uses the overall time slower than the leader or just their time in the current timing gate interval for the lap.
TeamHavocRacing wrote:If I had a nickel for every time someone asked for this, I would have a whole shitload of nickels.
Prada
Posts: 1099
Joined: Wed Aug 03, 2011 3:35 pm

Re: Server commands and such

Post by Prada »

Not sure if this is off topic or not. But instead of typing in the command every time, could we just simplify it and get a menu for commands to just click on? Like a hotkey or something? Maybe you already have this I don't know lol, I've never ran a server
Stormz
Posts: 2015
Joined: Wed May 12, 2010 7:52 pm
Location: US of A
Contact:

Re: Server commands and such

Post by Stormz »

Thanks for all the info, JLV and Tyskorn. I had no idea you could search like that.

As for the resetting thing, I'll add that to my server tonight. Thanks.

Gotta go re-read the readme now haha.
Stormz
Posts: 2015
Joined: Wed May 12, 2010 7:52 pm
Location: US of A
Contact:

Re: Server commands and such

Post by Stormz »

Prada wrote:Not sure if this is off topic or not. But instead of typing in the command every time, could we just simplify it and get a menu for commands to just click on? Like a hotkey or something? Maybe you already have this I don't know lol, I've never ran a server
If you are using the same command a lot, just use the up and down arrows then change as needed. That's what I do and it seems to work ok.
jlv
Site Admin
Posts: 14930
Joined: Fri Nov 02, 2007 5:39 am
Team: No Frills Racing
Contact:

Re: Server commands and such

Post by jlv »

yzmxer608 wrote:Pretty much the larger the overall result is of the calculation, the more time it takes for the rider to go invisible. The part I'm not sure about is if it uses the overall time slower than the leader or just their time in the current timing gate interval for the lap.
It's the interval. I think it includes the surrounding sections too.
Josh Vanderhoof
Sole Proprietor
jlv@mxsimulator.com
If you email, put "MX Simulator" in the subject to make sure it gets through my spam filter.
Stormz
Posts: 2015
Joined: Wed May 12, 2010 7:52 pm
Location: US of A
Contact:

Re: Server commands and such

Post by Stormz »

Trying to get the runforever.sh file to run.

I keep getting this when i send it via putty...

nohup: appending output to `nohup.out'
nohup: cannot run command `/runforever.sh': No such file or directory
[2] 32477
[2]+ Exit 127 nohup /runforever.sh ./mxserver --args-file serverargs.txt


What does this mean or what am I doing wrong?
Axionkt
Posts: 75
Joined: Tue Dec 16, 2008 2:39 am

Re: Server commands and such

Post by Axionkt »

Stormz wrote: [2]+ Exit 127 nohup /runforever.sh ./mxserver --args-file serverargs.txt

What does this mean or what am I doing wrong?
It depends on where you put the runforever.sh file but if it's in the current directory you have to add a period:

Code: Select all

nohup ./runforever.sh ./mxserver --args-file serverargs.txt
Post Reply