Commit graph

8 commits

Author SHA1 Message Date
Daniel Gibson
b38aff8995 Fix sending clients from lobby to game when lobby and game are on same server
In the current case (only "direct" lobby backend, i.e. connect to a
server directly), lobby and game are always on the same server anyway..

It used to send the IP of the first network interface.. that kinda works
on Windows and FreeBSD in LANs (i.e. not over the internet or even
behind a NAT), but not at all on Linux, because the first device seems
to be the loopback device there (at least on my machine)..
Now it sends net_ip (so it should even work behind NAT) or, if net_ip is
set to "localhost" (the default), 0.0.0.0 is sent, which the client
interprets as "just use the IP of the lobby you're already connected to"
2013-03-17 23:35:12 +01:00
Daniel Gibson
6e6703b93f Print net checksums as unsigned int
because it actually *is* unsigned and the negative values look strange
2013-03-17 23:35:12 +01:00
Daniel Gibson
e8c8a04c07 rewrote posix_net.cpp based on win_net.cpp
And suddenly hosting a server on linux works at least locally
(with client and server on the same machine).
Even though there are still strange bugs (massive lags in one
direction, doesn't work in LAN), at least it works at all now.
2013-03-17 23:33:39 +01:00
Robert Beckebans
dd9b8a8710 Added support for precompiled headers for MSVC which reduced the compiled time from 4 minutes to 67 seconds. 2012-12-22 16:18:19 +01:00
Daniel Gibson
ee88148bd1 eliminate more longs
for 64bit compatibility.
2012-12-13 01:28:41 +01:00
Robert Beckebans
86deed26b8 Merged 64 bit fixes. 2012-12-12 12:11:55 +01:00
Robert Beckebans
f55a763ca4 Formatted code using Artistic Style for better readability. 2012-11-28 16:47:07 +01:00
Brian Harris
5016f605b8 Initial commit 2012-11-26 12:58:24 -06:00