Shutting Out the Outside World

Help with Setup, Hardware, Performance or other Issues...Or just pimp your rig.
Post Reply
User avatar
jweeks
Private First Class
Private First Class
Posts: 32
Joined: Wed Dec 24, 2003 2:55 pm

Shutting Out the Outside World

Post by jweeks »

I would like to run 1.10 on an internal server. How do I block the listing of other BZflag servers so that my students only see, and thus can only access, our local server?

Don't tell me to change something on my network because I don't have access to my network to make changes. In other words, I need to change the BZflag program. BTW, everything is Windows, including the server.

Thank you.
User avatar
blast
General
General
Posts: 4933
Joined: Fri Mar 21, 2003 3:49 pm
Location: playing.cxx
Contact:

Post by blast »

Well, each client would have to be run with the -nolist paramater.
"In addition to knowing the secrets of the Universe, I can assure you that I am also quite potty trained." -Koenma (Yu Yu Hakusho)

Image
User avatar
jweeks
Private First Class
Private First Class
Posts: 32
Joined: Wed Dec 24, 2003 2:55 pm

Post by jweeks »

blast wrote:Well, each client would have to be run with the -nolist paramater.
How does one do that?

There must be a simple way to modify the program that does not require a player to set a parameter. Remember...I said this was for use by students. I can't trust high school students to not access other BZflag servers on the Internet.
User avatar
blast
General
General
Posts: 4933
Joined: Fri Mar 21, 2003 3:49 pm
Location: playing.cxx
Contact:

Post by blast »

Well, you could hard code that setting in, in bzflag.cxx I suppose.
"In addition to knowing the secrets of the Universe, I can assure you that I am also quite potty trained." -Koenma (Yu Yu Hakusho)

Image
User avatar
larsl
Dev Monkey
Dev Monkey
Posts: 50
Joined: Tue May 20, 2003 2:35 pm
Location: Stockholm
Contact:

Post by larsl »

Remove the "-list" option in bzflag.cxx, change DefaultListServerURL in Protocol.h to an empty string, and make sure that the list server url isn't read from the config file. You will also have to make the "Server" field in the "Join Game" menu uneditable, or your students can just go to http://db.bzflag.org/db/ and copy a server address. And you need to remove the server parameter parsing from bzflag, or the students can go to the same webpage, copy an address and use the command 'bzflag my.copied.bzserver'.
User avatar
larsl
Dev Monkey
Dev Monkey
Posts: 50
Joined: Tue May 20, 2003 2:35 pm
Location: Stockholm
Contact:

Post by larsl »

Or, if you don't mind the students seeing the server list but just don't want them to connect to any other server, go to the function joinGame() in playing.cxx (line 5698 in the current CVS version) and add these lines before the rest of the function body:

Code: Select all

strcpy(startupInfo.serverName, "my.bzflag.server");
startupInfo.serverPort = 5154;
...with the serverName and serverPort changed to your server name and port, of course.
Post Reply