iNcog Posted April 15, 2016 Report Share Posted April 15, 2016 Hey guys, iNcog here, perhaps you remember me? It's been some time, so I don't think that most do. I've been keeping an eye on the game though. First off, I have to say that it's a pleasure to see the progress which has been made since I first tried the game in the 16th iteration. Very nice to see this, a huge kudos to the game devs still working on this project. As for my opening of this thread, well I have a few technical questions which I need to ask. I'd already tried to get a few of my friends from other RTS games (in particular, Age of Empires game and Starcraft) to try out 0 AD. The consensus from them is that the game has some very unique design and cool features, however there are a few technical issues which discourage them from actively picking up the game. Here are my questions (which stem partly from their remarks): - I notice a pretty significance in game responsiveness between playing single player and playing multiplayer from the lobby. The command lag (click somewhere, the unit only starts moving after about half a second) is quite important in multiplayer. From what I remember, this is due to the way servers are set up so that the game is equally responsive for everyone playing. I can't remember the technical terms, I just know that this is intentional. My question: Is this command lag present when playing in LAN or P2P set-ups (players directly connected)? - This is a small issue, but one which is enough to discourage people from playing 0 AD actively. When clicking a building or a unit, it seems that only 90% of the clicks register. Clicking is superior to drag-boxing in many circumstances, so I wanted to know if something could be done about the fact that some clicks simply don't select the unit or building? Just try clicking on the villager center / forum, you'll find that you need to click at its base rather than near the top of the building. Could perhaps an invisible or transparent texture get added to aid with that? Otherwise the game is really amazing. I love what I'm seeing. ^^ Quote Link to comment Share on other sites More sharing options...
sanderd17 Posted April 15, 2016 Report Share Posted April 15, 2016 1. The turn time in MP is set to 500ms, while in SP it's 200ms. This is to allow the network connection to send the commands in time, so you don't get game lag (game time taking longer than real time). The disadvantage is that commands indeed seem to come through with a bit of a delay. It should indeed be possible to reduce this value in the case of low latency connections (like on a LAN). But that's not possible yet since the value is hard-coded. There are/were plans to make the value dynamic: test the latency every once in a while, and update the turn time to match it. Though that's not implemented yet, and I don't see it happening very soon (as it's not that easy to do). 2. Clicking at the top of a building or unit works fine for me (except for foundations that being build). Maybe that's an OS-specific issue? Is there any correlation between those reporting the issue and the OS they use? 1 Quote Link to comment Share on other sites More sharing options...
iNcog Posted April 15, 2016 Author Report Share Posted April 15, 2016 (edited) Quite a fast reply, you're as reliable as ever. ^^ Nice to see that. As for the technical discussion. In regards to clicks not perfectly registering, I use windows and have noticed this and the friend who made the remark to me as well also uses Windows (though he made the remarks maybe 2 years ago). So perhaps it's a windows problem. I can look into making a small video if you would like to see the issue first hand, if you want. As for turn time (that was the term I was looking for), what you're describing is pretty interesting. If the turn time were set to 30 ms, would that induce lag in single player, if the system ran the game at 30 fps for example? 30 fps -> 1/30 * 1000 = 33.3 ms so the game latency would be higher than the turn time latency, thus inducing lag. Is that how it works? 500 ms is quite a lot, you see, it's enough to turn off most veteran RTS players. That said, I can absolutely see the interest in running the game without lag. So it's a compromise. ^^ 200ms is also noticeable but it's still much better than 500 ms. Is turn time done dynamically in other games? I also fully understand how the project is managed so obviously any tall order is going to require a lot of resources in terms of man-power. I also notice you saying that value is hard-coded, but wouldn't it be a simple matter to just adjust the value (in the hard-code, obviously) so as to reduce the turn time a little? Edit: Oh and just to be sure: LAN does work with this game, correct? Edited April 15, 2016 by iNcog Quote Link to comment Share on other sites More sharing options...
niektb Posted April 15, 2016 Report Share Posted April 15, 2016 7 hours ago, iNcog said: Edit: Oh and just to be sure: LAN does work with this game, correct? Sure it does, but you need to type in the IP manually (no such thing as autodiscovery available yet) Quote Link to comment Share on other sites More sharing options...
sanderd17 Posted April 15, 2016 Report Share Posted April 15, 2016 500ms is really needed for the average multiplayer over the internet. So adjusting the hard-coded value probably won't happen. But I do understand that it's a bit much for a lan game, where the lag is lower. A turn needs to be short enough to register commands quickly, but it also needs to be long enough to fit all network traffic and calculations. Else the game time would start to go slower, and everything would start to happen in slow motion. So these values are a compromise to support the average game. 1 Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted April 16, 2016 Report Share Posted April 16, 2016 I am the curious one. Has 400 ms been try? Is this enough for simulation and enough reduction to feel more natural for player? 1 Quote Link to comment Share on other sites More sharing options...
sanderd17 Posted April 16, 2016 Report Share Posted April 16, 2016 400ms will give a better feel in the start of the game (when calculations easily fit in that time), but it will make the lag worse in the end-game. The values are defined here, if anyone is interested: http://trac.wildfiregames.com/browser/ps/trunk/source/network/NetTurnManager.cpp#L41 Both the host and the client will have to change that value and recompile to test it though. Quote Link to comment Share on other sites More sharing options...
wowgetoffyourcellphone Posted April 16, 2016 Report Share Posted April 16, 2016 Intriguing. What about a migrating turn length? Starts at 300ms and then gradually increases to 500+ over time? Possible (easier) solution (than dynamic turn lengths) or just dumb idea? lol 1 Quote Link to comment Share on other sites More sharing options...
iNcog Posted April 16, 2016 Author Report Share Posted April 16, 2016 OK, thanks for the answers and super interesting answers at that. 500ms is just too high for most people, unfortunately, though it's not like I don't see why it's there. Otherwise, would it be possible to considering using a service like Voobly in order to directly connect two players together in LAN mode? Quote Link to comment Share on other sites More sharing options...
sanderd17 Posted April 16, 2016 Report Share Posted April 16, 2016 @wowgetoffyourcellphone, better fix it like it should IMO. @iNcog, not sure how including an external service would help with this ... 1 Quote Link to comment Share on other sites More sharing options...
iNcog Posted April 16, 2016 Author Report Share Posted April 16, 2016 I meant for this: Sure it does, but you need to type in the IP manually (no such thing as autodiscovery available yet) Though yeah I should probably have said so. if voobly for example (though could be anything, i just remember voobly because of AoC, there's also other services like game ranger), could connect two players directly, it might emulate LAN conditions and allow for 200ms turn times instead of 500 ms. though that might actually induce some lag if one player's set up isn't good enough, i guess 1 Quote Link to comment Share on other sites More sharing options...
sanderd17 Posted April 16, 2016 Report Share Posted April 16, 2016 I don't think that adding a step in-between can make the UDP traffic that much faster than a direct connection. After all, it's not the bandwidth that matters most (the packages are rather small), but it's the latency that matters. And latency will only increase when you increase the distance and the number of devices in-between. 1 Quote Link to comment Share on other sites More sharing options...
iNcog Posted April 16, 2016 Author Report Share Posted April 16, 2016 OK that makes sense. Quote Link to comment Share on other sites More sharing options...
Palaxin Posted April 17, 2016 Report Share Posted April 17, 2016 (edited) On 4/15/2016 at 7:20 AM, iNcog said: The consensus from them is that the game has some very unique design and cool features, however there are a few technical issues which discourage them from actively picking up the game. Here are my questions (which stem partly from their remarks): - I notice a pretty significance in game responsiveness between playing single player and playing multiplayer from the lobby. The command lag (click somewhere, the unit only starts moving after about half a second) is quite important in multiplayer. From what I remember, this is due to the way servers are set up so that the game is equally responsive for everyone playing. I can't remember the technical terms, I just know that this is intentional. My question: Is this command lag present when playing in LAN or P2P set-ups (players directly connected)? Yesterday I was introducing my friends to 0 A.D. and we did some multiplayer games via LAN connection. They were thinking similarly: nice overall impression, but they immediately noticed the 500 ms turn length. We were three human players and no AI and there was nearly no lag at all, so I agree to reduce turn length at least for LAN connections. Apparently other games manage to be more fluent, even when played over the internet. For example in League of Legends reactions are so crucial that similar turn lengths would totally destroy the game. However they use separate servers for each (part of a) continent so this should help with this problem indeed. Taking only physical properties into account (the very hard limit for connections of all type), a signal travelling in a cable needs about 100 ms to cross half the globe (the longest possible distance on earth surface) and about 67 ms if it propagates as an electromagnetic wave through the air. Double the values for client → server → client. Of course you can't assume that the signals travel directly and each device has to process the information so it adds additional delay. Edited April 17, 2016 by Palaxin 1 Quote Link to comment Share on other sites More sharing options...
iNcog Posted April 17, 2016 Author Report Share Posted April 17, 2016 Well put. I'm not sure how other games handle turn rates, but it's definitely better for it to be as low as possible. Naturally, lag is also a pretty big concern so the obvious solution is to NOT just turn down the turn rate and call it a day. I'm wondering a little more about the dynamic turn rate. It could be something quite difficult to implement? Or, theoretically speaking, could a mod be made with an emphasis on performance (allowing for turn rates to be lowered)? Unfortunately that would not sync with the 0 AD version of people having the normal version. Quite a pickle. As for the cursor issue, I think I've figured out. Units are selected on mouse-up, rather than mouse down. There are two "clicks" when you click a button, one click down, one click when it's released. Buildings are selected on mouse up, so you need to release the click in order to select the unit. If you move the cursor when the click is down, you start a drag box. I think that's where that placebo issue is Quote Link to comment Share on other sites More sharing options...
sanderd17 Posted April 17, 2016 Report Share Posted April 17, 2016 It can't be done in a mod, as it needs engine modifications. But that doesn't really influence the complexity of the problem. There's an advantage that with the current game, it already keeps the network lag caused by players. So now the host should just calculate some good default from that every x turns (f.e. make sure 90% of the turns fit in the given turn time). Other games probably do this differently. They could already start the animation before the command is and to the host. So just to provide some user feedback. This would probably give better results visually, but making a distinction between real and virtual commands well be hard. I do understand the mouse issue now. So I guess it's mainly because your mouse is to precise, and it starts drawing a rectangle to early. I don't have a gaming mouse, and I'm not that fast to move, so I never really make an accidental bounding box. 1 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.