News:

SimuTranslator
Make Simutrans speak your language.

Crashes on Multiplayer Joining

Started by Lycake, September 05, 2017, 10:20:54 AM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

Lycake

Hello,

unfortunately my buddies and I weren't able to get a 3 man multiplayer going. I was the host and had no issues throughout. The first client connects fine, but as soon as the second client connects, the first one crashes right after the "saving game" bar. This happens no matter who connects first and seems to be independent of the pak used (we tried Pak128.Britain and Pak64). No matter what we tried, we couldn't get more than 2 players playing together.

There are no error messages, just the standard windows "stopped working" message. Trying to log the error using the start parameters log and debug didn't work.

Debugging the crashed client with Visual Studio reveals the following exception: "Unhandled exception at 0x7563897A (msvcrt.dll) in simutrans.exe: 0xC0000005: Access violation reading location 0x00000000." Hello null pointer!

Anyone got any ideas how to get around this problem so I can get more than two people playing together?

Thanks for any help you might provide!

greetz,
Cake

Dwachs

Did the server crash? Do all three players use the same version of the program?
Parsley, sage, rosemary, and maggikraut.

Lycake

No as I said I was host and had no issues. I didnt crash and could play fine. Even the second client that connected could play with me just fine. Just the client that was connected before crashed once the third player entered. The game went on normally. Would the player who just crashed reconnect, the other one would crash immediately.

little diagram maybe to make the situations more clear:

H = Host (me), A = Player 2, B = Player 3

H opens game: Game runs normal
A connects: Game runs fine with H and A playing
B connects: A crashes, otherwise game runs fine with H and B playing
A connects again: B crashes, otherwise game runs fine with H and A playing

I hope that clears it up what is happening.

We are all using the standard steam version and downloaded the paks through steam aswell. I am not sure which version number this is exactly atm, because Im not home, but we checked and all had the same one.

TurfIt

Steam build clients do indeed crash when another client joins... no idea what that build has mangled.
Non-steam builds work properly.

Ters

If we knew where in msvcrt.dll it crashes, that might give a clue, but given the process specific address of 0x7563897A, it looks like it has been loaded at a non-standard address (which is a security feature these days). We would also have to know which exact version of msvcrt.dll it is. But it might be in a function that is called from a thousand different places.

Lycake

Well at least I now know it's not a bug specific to me, but a general steam build problem. Also I can confirm that non steam builds work fine for me aswell.

Thanks for the help. I think this topic should be moved to the bug section instead of the help center ;)

Greetz,
Cake

DrSuperGood

As far as I am aware there is only 1 developer of the steam build and he uses his own branch of the code which has many, steam required, differences from the main branch.

Although we all help him when we can, there are some minor communication problems when it comes to problems he is having and why. This is partly why SDL2 has seen some work recently.