Open IsaMorphic opened 4 years ago
Hi very nice report you wrote there, sorry for taking a while to respond :) Unfortunately the Steam Version (Steam Version as in actually using the Steam Client for hosting) is not supported at the moment.
The reasoning behind this is that the GOG version is generally better suited for hosting. Servers running that version are also visible for Steam users and have the added benefit that they allow running multiple instances. Also steam requires setting fixed launch parameters to prevent that command line validation popup from showing up.
I believe that the last release that supported the Steam Client was 1.0.4. I'd strongly advise gainst using that version though as it introduces a very messy way of keeping the server alive that has long been deprecated (running D3D, using Windows session loading via RDP and other naughty things).
The technical reason why the Steam Client is not supported at the moment is, as you correctly identified, that the RconServer project does not contain instruction offsets for the Steam version. These offsets are used to patch various bugs in the game process that would normally prevent it from hosting a standalone server. Without the patches the server can not run at all.
Finding these offsets is not too difficult (once the bugs were identified properly) but would take a bit of time. I might give it a look some time but since this is only a hobby project I unfortunately can't promise anything.
Heyo,
Thanks for the swift and detailed response.
I did try to use the 1.0.4 version, but as you have already noted the way that version was prone to failure (I could never get the RconServer to bind properly). I thank you for your time and I hope that this wonderful little project continues to grow and improve.
May the force be with you.
Heyo,
I figured I'd actually reopen this issue, as supporting the Steam version is still desirable and I'm still interested in using this software. I'd like to here what your current stance on this is, and whether this can be made a priority.
Thanks in advance,
Yodadude2003
Experimental (untested) steam support was re-added in https://github.com/jweigelt/swbf2admin/commit/ad84c96e1fac13bbace7e6c483e050b57c03031c.
If you are interested you can check out the steam-testing
branch.
To enable Steam mode, modify core.xml:
<ServerType>Steam</ServerType>
Adjust the game's command line using the Steam client:
/win /norender /nosound /autonet dedicated /resolution 640 480
Sounds great! I'll check it out as soon as I can and get back to you once I do.
So, good news! I just compiled and tested the "steam-testing" branch. It appears that the process attaches successfully and Rcon binds and logs in properly.
However, I am not able to see the server when I run the game on a different machine (with a different steam account of course). I'm assuming this has to do with port forwarding of some sort that I haven't taken the time to do.
Let me know if you suspect a different issue is at play.
On that note, I don't believe its very practical for me at this moment to run a dedicated server, as that would require me to purchase yet another copy of the game and run it on a different machine. I looked into potentially using Sandboxie, but something like that would take a lot of time and troubleshooting to setup, not to mention the (unlikely) possibility of being banned for using software like that.
Despite this, I'll keep the issue open in case I change my mind or if someone else has something to add.
Sincerely, Yodadude2003
Hello! I have been spending some time today trying to get the most recent release of SWBFAdmin working with the Steam release of the game, and it doesn't appear to be working. I have configured the server as per the README, and changed the ServerType in ./cfg/core.xml to Steam. I also set the ServerPath variable to the game's installation directory and copied the contents of ./server to the GameData subdirectory.
Shown here is the output to the console window from when I attempted to start the server via WebAdmin:
The moment the game launches, it immediately crashes and SWBFAdmin tries to launch it again.
The game also leaves a brief log.txt file in the GameData directory, containing this line:
bind failed with error %u
It also appears that in the source code for RconServer, some of the OFFSET_{insert-name-here} definitions are missing for Steam in bf2server.h.This leaves me with a couple questions:
Thanks, Yodadude2003