Local play over LAN

Need help seting up a server, or have a question on how to run one? This is the place.
Post Reply
BeanCounter
Private First Class
Private First Class
Posts: 8
Joined: Sat Apr 18, 2009 9:26 pm

Local play over LAN

Post by BeanCounter »

I downloaded BZFlag onto my two home computers today.

It's a great game, however my son and I would like to play one-on-one.


My setup:

I have cable internet with a cable modem
I have a Linksys wireless router connected to the cable modem
I have one Windows XP desktop PC and one Windows Vista desktop PC, each with a wireless network card to access the wireless internet.

With this setup, I can run most games over a LAN (we play Microsoft Combat Flight Simulator often) in multi-player mode since both computers are on the same network.


So:

I'm now trying to setup a "server" in BZFlag that will let us play one-on-one and can't figure out how to do it. I'm not sure whether that means my PC "hosts" the game or if I set up some kind of internet server that works by invitation only.

Can someone tell me how to do this? (Explain it at the second grade level please - I'm not an IT expert)

Thanks in advance...

Jeff
dango
Private First Class
Private First Class
Posts: 1400
Joined: Sun Feb 06, 2005 5:40 pm
Location: Somewhere over there.

Re: Local play over LAN

Post by dango »

BZFlag comes with a bzflag server "bzfs.exe"

You can run it through the terminal, or use a program like StartBZFS.
I'd recommend the previous.

If you just start bzfs with no options, it will run a random map, with no jumping, no rico, and 1 shot, on port 5154.

If you know your ip address, put that in the "server" section when joining, and make sure "port" is set to 5154.
When you join from the server that is hosting, use 127.0.0.1 (localhost)

You can add

Code: Select all

+r -j -ms 5
when running bzfs to add ricochet, jumping, and 5 shots. You can also add a password via -password <yourpass> if you want to edit server variables. (just type /password <yourpass> to gain admin permissions, then you can /set whatever you want, like shotspeed [_shotSpeed] and tank speed [_tankSpeed])

Code: Select all

-world C:\path\to\world.bzw
can be used to play on a custom world.

Code: Select all

"C:\Program Files\BZFlag2.0.10\bzfs.exe" -j +r -ms 3 -world "C:\Program Files\BZFlag2.0.10\misc\hix.bzw" -password supersecretpassword
Would create a server with rico, jumping, 3 shots, a password, and the hix map, for example.
You can read here for more info on BZFS: http://my.bzflag.org/w/BZFS
Image
BeanCounter
Private First Class
Private First Class
Posts: 8
Joined: Sat Apr 18, 2009 9:26 pm

Re: Local play over LAN

Post by BeanCounter »

Thanks for your post, but I really need it "dumbed down" so that I get it.

I don't know what you mean by "run it through the terminal".

When I open BZFlag I get a menu that says

JOIN GAME
OPTIONS
SAVE SETTINGS
HELP
QUIT

If I choose JOIN GAME I get a menu that says

FIND SERVER
CONNECT
Call Sign:
Password:
Team:
Server:
Port: 5154
Email:
Start Server



So where do I get to this other files BZFS.exe ? And how do I get the server to run?

I'm OK with the defaults of random map and no jumping.

Thanks!

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

Re: Local play over LAN

Post by blast »

Starting the server

You only need to do this on one computer.

On XP: Go to the Start menu, click run, type 'cmd' (without the quotes), and click OK.
Or on Vista: Click start, type "Command Prompt" and hit enter.

You should see a screen with a black background and white font.

Type the following.

Code: Select all

ipconfig
You should see a line that says "IP Address". Write this down somewhere, as you will use this to connect to the server.

After that, you can type the following, assuming version 2.0.10:

Code: Select all

cd "\Program Files\BZFlag2.0.10"
This will change to the installation directory of bzflag. You can then type:

Code: Select all

bzfs -d
You should see a tiny bit of output. If you need to stop the server, hold down the Ctrl key and press C. It will return you to a prompt. This will start a default server on port 5154.

If you want a server that might be more fun, try this instead:

Code: Select all

bzfs -d -j +r -ms 5 +f good{2}
That will enable jumping, ricochet, increase the shot count to 5, and add 2 of every good flag. There is a lot more settings that you can adjust, and you can get a list by typing:

Code: Select all

bzfs -help
Joining the clients

After you have a copy of bzfs running (the server), you can start up the client on both computers. Go to the Join menu, and delete the "Server" value and type in that IP address you wrote down earlier. Enter 5154 for the port. Then hit the Connect option. Repeat this on your other computer.

If all went well, you should both be on your local private server and be able to duke it out. ;)
"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
BeanCounter
Private First Class
Private First Class
Posts: 8
Joined: Sat Apr 18, 2009 9:26 pm

Re: Local play over LAN

Post by BeanCounter »

I got it!

The LAN is up and working. We played games last night on the random and hix maps.

One bug I haven't solved yet is that I can "host" the LAN game from my XP computer and join it from my Vista computer, but it doesn't seem to work the other way around.

No problem though, it works fine. I'll just use the XP machine to set it up.

THANKS VERY MUCH FOR YOUR HELP !
User avatar
JeffM
Staff Sergeant
Staff Sergeant
Posts: 5196
Joined: Fri Dec 13, 2002 4:11 am

Re: Local play over LAN

Post by JeffM »

Verify that your vista firewall is setup to allow bzfs to listen for games, by default all incoming connections are blocked on vista.
ImageJeffM
rhapsody
Private First Class
Private First Class
Posts: 41
Joined: Thu Apr 30, 2009 11:31 am

Re: Local play over LAN

Post by rhapsody »

One question, what if I wanted to start the server using a map i created, then what would i type in cmd?
User avatar
mrapple
Sergeant Major
Sergeant Major
Posts: 460
Joined: Wed May 27, 2009 11:59 am
Location: Unknown
Contact:

Re: Local play over LAN

Post by mrapple »

rhapsody wrote:One question, what if I wanted to start the server using a map i created, then what would i type in cmd?
you would do everything the same, but add
Windows:
-world C:\path\to\file.bzw

or
Mac/Linux:
-world /path/to/file.bzw
Image
rhapsody
Private First Class
Private First Class
Posts: 41
Joined: Thu Apr 30, 2009 11:31 am

Re: Local play over LAN

Post by rhapsody »

hmm, i typed in:

cd "\Program Files\BZFlag2.0.10"

then: bzfs -d -world C:\path\to\(my map file).bzw

and it listed a ton of stuff, none which I understand, but either way it was having me think this was going to be successful. But upon "start server" and changing world map to my map, it has error connecting still, any suggestions?
User avatar
blast
General
General
Posts: 4934
Joined: Fri Mar 21, 2003 3:49 pm
Location: playing.cxx
Contact:

Re: Local play over LAN

Post by blast »

You need double quotes around the filename since you have spaces.
"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
rhapsody
Private First Class
Private First Class
Posts: 41
Joined: Thu Apr 30, 2009 11:31 am

Re: Local play over LAN

Post by rhapsody »

Well, i have tried numerous things, none of which have worked so that's lead's me to the conclusion that my map may have an error, or i am not giving the right "path".

When i type in -ddd i get this :

Code: Select all

C:\Program Files\BZFlag2.0.10>bzfs -ddd
ColDet Octree obstacles = 36
  grid extent[0] = -432.785156, 435.098785
  grid extent[1] = -453.384644, 414.499268
  grid extent[2] = 0.000000, 867.883911
  world extent[0] = -432.785156, 435.098785
  world extent[1] = -437.785767, 398.900391
  world extent[2] = 0.000000, 10.250000
ColDet Octree leaf nodes  = 21
ColDet Octree total nodes = 28
ColDet Octree total elements = 49
Collision Octree processed in 0.001 seconds.
Map size: uncompressed = 1228, compressed = 595
Compression: 0.001 seconds
MD5 generation: 0.000 seconds
Note: no acceleration limit has been set.  Players using "mouse
enhancements" may cause problems on this server due to very high
acceleration rates which are not handled well by dead reckoning
algorithms.  To eliminate this warning, set the -a switch in your
configuration.  '-a 50 38' is recommended for standard-speed servers.
Higher speed servers will need higher values for -a in order to not
affect gameplay.  '-a 0 0' may be used to shut this message up without
affecting any players, including those using "mouse enhancements".
style: 10
There is a voting arbiter with the following settings:
        vote time is 60 seconds
        veto time is 2 seconds
        votes required are 2
        vote percentage necessary is 50.099998
        vote repeat time is 300 seconds
        available voters is initially set to 200
Running a private server with the following settings:
        listening on 0.0.0.0:5154
        with title of ""
LIBCURL version:  libcurl/7.16.3-CVS c-ares/1.3.3-CVS
Does it look like there is any errors?

also, i am keeping the map in my bzflag worlds file, not sure if that's the right place to have it...
User avatar
Bambino
Private First Class
Private First Class
Posts: 1210
Joined: Mon Apr 21, 2008 10:27 pm
Location: Alberta, Canada

Re: Local play over LAN

Post by Bambino »

That looks normal to me when I start a server. It looks like you didn't specify a map file.
"Anyone who has never made a mistake has never tried anything new." -- Albert Einstein
GU League | Ducati League | OpenLeague
User avatar
blast
General
General
Posts: 4934
Joined: Fri Mar 21, 2003 3:49 pm
Location: playing.cxx
Contact:

Re: Local play over LAN

Post by blast »

That looks like it's running just fine to me. You should be able to join the server "localhost" (or the LAN IP address, if you're not running the client on the same machine as the server) on port 5154.
"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
Post Reply