Netbios support patch

Developer's Forum, for discussion of bugs, code, and other developmental aspects of DOSBox.

Netbios support patch

Postby h-a-l-9000 » 2005-9-09 @ 12:42

Hi,

I've got Novell's netbios.exe working with the Dosbox IPX. Tested it with Armada and Hioctane.

Since there was a problem with data being received in non-suitable CPU mode, especially when running Armada, I had to do one massive change.
The games I usually test (see directserial patch thread) all except Armada Proving Ground which is a bit unstable work, but I had to add a workaround for Warcraft1, some bugs seem to be left.

So if you want to run Warcraft1 with this, you have to type "ipxnet localloopbackoff" before.
The problem is:
IPX broadcast packets are sent to every computer on the net, even back to the sender. Warcraft1 sends a broadcast packet, but somehow doesn't recognize the packet coming back it as its own and starts a connection attempt with itself. Possible cause could be wrong values in the IPX data structure.

But now for Netbios: I've included Novells netbios.exe in the zip file, but it can also be obtained from http://www.novell.com/coolsolutions/tools/13555.html .
You have to connect to the server first, then load netbios.exe inside Dosbox (not the other way around, because the IPX address changes when connecting to the server, and netbios.exe only checks it on startup).

Oh, and feel free to report non-functional IPX / Netbios games here.

Edit: was wrong diff file, sorry.
Attachments
netbiospatch.diff
the patch..
(41.08 KiB) Downloaded 556 times
armada_netscreen.jpg
armada_netscreen.jpg (56.15 KiB) Viewed 5156 times
armada_ingame3.jpg
armada_ingame3.jpg (57.92 KiB) Viewed 5156 times
hioctane.jpg
Hi-octane (Netbios game)
hioctane.jpg (58.58 KiB) Viewed 5156 times
netbios_binary.zip
Windows Binary with DLLs and netbios.exe
(721.01 KiB) Downloaded 761 times
Last edited by h-a-l-9000 on 2005-9-10 @ 09:53, edited 1 time in total.
h-a-l-9000
DOSBox Author
 
Posts: 4512
Joined: 2005-2-23 @ 00:14

Re: Netbios support patch

Postby HCl » 2005-9-10 @ 02:14

First of all, greetings to all. I'm a newbie on the forum but i'm pretty excited with DosBox.

Cool to see other people are working to get NetBIOS to work on DosBox! I have also been working towards this goal, but by implementing NetBIOS from scratch. I first started by implementing IPX functions 0x0005, 0x0007 and 0x000d so NetBIOS would work, but later scratched the idea of using Novell's netbios when i noticed Armada prevented netbios.exe from receiving IPX packets... My implementation of NetBIOS isn't complete, but it's enough to get Armada playing, which i confess was my primary goal. I was also testing with Syndicate: American Revolt, but it needs NetBIOS sessions and i'm not there yet.

I also have it working by broadcasting packets to everyone, Hal. However, in my code only NetBIOS over IPX packets are broadcasted, the original behaviour is maintained for programs using the IPX interface directly. I am currently checking is this broadcast can be avoided tho...

Anyway, i'm on a windows machine right now, and i lack the tools to make a diff at the moment, but i will be posting one tomorrow if the interest is there.

Best,

Mario Brito
(HCl)
HCl
Newbie
 
Posts: 9
Joined: 2005-9-10 @ 01:56

Re: Netbios support patch

Postby mirekluza » 2005-9-10 @ 07:35

Let's post what you have Mario. The more various patches, the better for DOSBOX...
Maybe you could make a separate thread for your implementation. I or somebody else will then move it into DOSBOX Patches.

Mirek
mirekluza
DOSBox Moderator
 
Posts: 1697
Joined: 2003-8-21 @ 04:19

Re: Netbios support patch

Postby h-a-l-9000 » 2005-9-10 @ 14:32

If I had known somebody is working on this I'd have done something else, or even better, nothing :happy: Well I might have fixed something here and there, especially that Armada prevented packets from being received...

I'm pretty sure sending broadcast packets back to the originator is normal IPX behavior, it just gets misinterpreted due to some bug.

Armada also works with the virtual modem (CVS).

I wonder if there is people who regularly use Dosbox Multiplayer features on the Internet. Multiplayer doesn't seem too popular here at Vogons. Maybe meet in IRC?
h-a-l-9000
DOSBox Author
 
Posts: 4512
Joined: 2005-2-23 @ 00:14

Re: Netbios support patch

Postby Qbix » 2005-9-10 @ 15:36

well It would be nice if you could figure that loopback stuff out.
A special mode only for warcraft is unlogical :)
Can't help you figure it out though. Not much freetime.

On the irc channel of dosbox are a few people. but I doubt they play multiplayer.
Water flows down the stream
How to ask questions the smart way!
User avatar
Qbix
DOSBox Author
 
Posts: 10356
Joined: 2002-11-27 @ 14:50
Location: Fryslan

Re: Netbios support patch

Postby DosFreak » 2005-9-10 @ 16:16

I'm forcing myself to test out the multiplayer functions in DosBox...it's hard tho.

I've never been a fan of multiplayer, Only LAN based multiplayer gaming, MUDS, BBS's or modem to modem. There's more of a community, and more actual gaming (and less talking...) involved in those activities than the new-fangled MMOG's of today....but since I love DOS games and I used to play them via modem (Falcon 3.0 baby!) it shouldn't be that hard to get my butt in gear.


How stable is DosBox with multiple IPX connections? Is there any way to monitor the amount of data being transferred?
Game Acronym List
DosBox CVS Builds
DosBox Feature Request Thread
DosBox FAQ
PC Game Compatibility List
"Who's got time to read all the way down to the bottom of an email?"
User avatar
DosFreak
l33t++
 
Posts: 9430
Joined: 2002-6-30 @ 16:35
Location: Your Head

Re: Netbios support patch

Postby h-a-l-9000 » 2005-9-10 @ 18:46

So far I've tested everything with 2 players on LAN, some minutes game play, nothing else. Except for Armada Proving Grounds they all behaved nicely within that time. Data traffic is usually many many small packets, but this may vary by each game. You can use Ethereal to monitor Network traffic.
http://www.ethereal.com/
h-a-l-9000
DOSBox Author
 
Posts: 4512
Joined: 2005-2-23 @ 00:14

Re: Netbios support patch

Postby HCl » 2005-9-11 @ 00:44

My experiences in the Wing Commander community indicate that there quite a number of people who use DosBox to play multiplayer games online. I have personally participated on online matches coordinated on IRC... although with atrocious slowdowns due to lag (most of the older games tend to synchronize everything, which makes them very sensitive to lag...)

I tend to test networking functionality with multiple instances of DosBox on the same machine. This is definitely not the best way to do it tho, as i have a slow computer and the extra DosBox instances pretty much kill the system :neutral: Can't be helped tho, as i only have one computer at home.
HCl
Newbie
 
Posts: 9
Joined: 2005-9-10 @ 01:56

Re: Netbios support patch

Postby h-a-l-9000 » 2005-9-11 @ 17:11

@ Qbix:
The problem is I might not be able to find that bug.

@HCl:
I could think of another way of further reducing lag, need to implement/ test it though...
h-a-l-9000
DOSBox Author
 
Posts: 4512
Joined: 2005-2-23 @ 00:14

Re: Netbios support patch

Postby Qbix » 2005-9-11 @ 19:19

hal can't you compare a real ipx broadcast packet with the ones dosbox creates ?
Water flows down the stream
How to ask questions the smart way!
User avatar
Qbix
DOSBox Author
 
Posts: 10356
Joined: 2002-11-27 @ 14:50
Location: Fryslan

Re: Netbios support patch

Postby h-a-l-9000 » 2005-9-11 @ 19:48

They are identical..
h-a-l-9000
DOSBox Author
 
Posts: 4512
Joined: 2005-2-23 @ 00:14

Re: Netbios support patch

Postby JRL913 » 2005-9-17 @ 11:52

Hi, just wanted to share my enthusiasm for the work you guys are doing. As HCl said, there is quite a large community out there playing old games through dosbox and other methods. I myself play SNES emulators with my friends through the net quite regularly.

Anyway, I wanted to let you guys know that I was able to get Magic Carpet running with netbios.exe and the modified dosbox file. I'm pretty excited, as magic carpet is one of my favorite games ever. All I had to do was start the ipx server, establish the connection, run the netbios exe file, then run carpet.exe -network. The rest is configured through the game.

Thanks again for doing such a great job on making the classics playable.

Jose

PS: Accidentally posted this in the devlopment forum, so I deleted it and reposted here.
JRL913
Newbie
 
Posts: 1
Joined: 2005-9-17 @ 11:29

Re: Netbios support patch

Postby h-a-l-9000 » 2005-9-18 @ 02:01

Nice to get some feedback :happy:
h-a-l-9000
DOSBox Author
 
Posts: 4512
Joined: 2005-2-23 @ 00:14

Re: Netbios support patch

Postby HCl » 2005-9-20 @ 01:16

Sorry, forgot to answer this a while back:

I could think of another way of further reducing lag, need to implement/ test it though...


I wouldn't bother with it.. Back then we were playing with 4 people online and i believe someone was slowing the entire group down. I just played 1vs1 a few days ago and it was very playable, so in my opinion this shouldn't be a priority.
HCl
Newbie
 
Posts: 9
Joined: 2005-9-10 @ 01:56

Re: Netbios support patch

Postby h-a-l-9000 » 2005-9-20 @ 09:33

With two computers it may be ok, but 3+ get double round-trip time (every packet is sent to the server first and from there back to the addressed computer).
h-a-l-9000
DOSBox Author
 
Posts: 4512
Joined: 2005-2-23 @ 00:14

Re: Netbios support patch

Postby HCl » 2005-9-20 @ 10:30

I understand that, although i've also played 3-sided games in the past with quite acceptable speeds. In any case, if you want to improve the tunneling code to use a more peer-to-peer approach for packet transmission, go for it, you certainly won't see me complaining ;-)
HCl
Newbie
 
Posts: 9
Joined: 2005-9-10 @ 01:56

Re: Netbios support patch

Postby HunterZ » 2005-9-20 @ 15:14

Whether or not high-latency players slow things down for everyone else depends on the networking code of each particular game.

The general idea with realtime games is that one computer is designated as the server, and is responsible for tracking the current state of the game world. Updates on player actions are processed as they come in, and updates on the game world status as a whole are sent out to each other player at regular intervals.

At one point when I was growing up, our family had a 120MHz 486 and a 33MHz 386. My brother and I connected them with a serial cable and played multiplayer games of Doom and Descent on them. We noticed that the slower 386 caused Doom to sometimes run at a slower framerate on both computers, while Descent ran slower only on the 386 (giving the player on that computer a disadvantage but sparing the 486 player from the annoyances of lower framerates).

I believe that as far as latency problems go, Valve solved this in their Half-Life netcode. However, many people mistakenly continued to believe that hi-latency players would degrade the latency of all players - a misconception that annoyed me to no end back when I played Counter-Strike frequently.
You're perfect, yes it's true...but without me, you're only you.
User avatar
HunterZ
l33t++
 
Posts: 6048
Joined: 2003-1-31 @ 19:04
Location: Seattle

Re: Netbios support patch

Postby Landorin » 2006-2-17 @ 16:47

Hello,

Someone just linked this thread to me since I was unable to get Hi Octane running in multiplayer mode. I just got the game again and noticed how good it is (there doesn't seem to be any game like that released again). Thanks a lot for this netbios patch.
I'm a bit confused, however. If I use a different dosbox version (cvs) I can start the netbios.exe as well, so why would I need a different dosbox.exe and the dll files you provided? I am just curious to know whether these files are needed because I'd like to use netbios with a different cvs version (the one that has optimized scaling so the game runs faster).
Also: what is that .diff file good for and how is it used?

In case someone doesn't know what to do or can't get Hi Octane working, here's a short how-to:
1) in Dosbox type "ipxnet startserver" (that's for the host, the clients have to type "ipxnet connect IpAdressofHostserver" after the host started the server)
2) run netbios.exe
3) start Hi Octane
4) In options menu there should now be a new option called network options. Go there and check the box for "network"
5) now the confusing part: don't waste your time looking around for something called "network race" in the race menu. Simply select any race you want (single/death match) and after you selected your car the game will automatically establish a connection. Now the other players have 30 seconds to get into the game (they have to connect to the ipx server first in dosbox, of course) and voilá you're set!
Landorin
Newbie
 
Posts: 8
Joined: 2004-10-21 @ 18:20

Re: Netbios support patch

Postby h-a-l-9000 » 2006-2-17 @ 17:16

Ykhwong's build also has this patch included.
Netbios can be loaded on plain CVS but will refuse to work properly.
h-a-l-9000
DOSBox Author
 
Posts: 4512
Joined: 2005-2-23 @ 00:14

Re: Netbios support patch

Postby Landorin » 2006-2-18 @ 10:20

Really? That's weird, I got the latest cvs and copied over the optimized scaling cvs and netbios.exe loaded just fine and multiplayer seemed to work, thus my confusion. :confused:

Anyways, Ykhwong added Netbios last September and removed it in the same month so your solution is one of the very few that are available and working at the moment.
Landorin
Newbie
 
Posts: 8
Joined: 2004-10-21 @ 18:20

Next

Return to DOSBox Development

Who is online

Users browsing this forum: No registered users and 0 guests