View Full Version : How to fix I-War 2 MP and make it a good game
MajorTom
04-12-2004, 03:50 PM
I've found some technical issues in the MP game, very recently, that I would like to discuss. I think they explain why I-War2 EOC MP never really got off the ground and many turned their back on it.
Of course: The pre F14.6 version really did suck due to the lack of DX8 netcode implimentation. But, that was fixed by the patch
Now, what do you think about the issues below?
Issue 1: The TRI
Using TRI causes a lag effect because the settings are not propagated in the MP game:
Example: If a player uses full power to engines he moves at a faster speed than the representation of his ship on the server (and on all the other clients). The position of his ship in relation to the position of other players ships (seen from his client instance of the game) is not consistent with the positions calculated on the server.
As a result: The player can shoot at a target and probably will see a hit. But, the server won't allocate the hit because the shot, seen from the servers perspective, didn't hit anything.
If the TRI user is a client other ships positions appear to jump around , whenever he gets a positional update from the server. If the player using TRI is the Host, he rarely even notices a difference.
Fixing this is easy: Delete the keybinds for the TRI from the default.ini for the duration of a MP game.
It is possible to have the MP game script verify the TRI is no longer bound. Players with TRI bound could be rejected from a game with a specific notice why.
Issue 2: the Score Screen
GUI screens in EOC run at a different game tick than the MP game. If a player called up the score screen during the MP game his ship would move much faster on his client instance of the game, and things will be screwed up: The same effect happens as discribed under TRI above but they are even more predominate.
To fix this, I've coded a new ingame score screen that is displayed on the players HUD and not, as was previously the case, in a GUI function.
Issue 3: Modding effects
If the speed of a MP ship (or some weapons properties) was/were changed in the resource folder, that would cause a lag-like effect too (that was however only seen on the modded client). Because of this manifestation, some thought, although it never was the case, I-War2 MP would be vulnerable to cheating.
This issue is fixed twofold by the hardcoded ini check as already implimented in what_rocksv2 and EpicOnline.
To me, this explains the lack of popularity for EOC MP and shows how that can be fixed. What do you think?
Have you ever noted any other issues not covered here?
Nanoprobe
04-13-2004, 09:14 AM
Actually, lack of popularity is just from lack of popularity in dogfighting space-sims in general. And moreso online because I believe it takes a little more bandwidth to have a stable full-3D game going (first-person stuff is generally limited to 2D planes, allowing for prediction with less data - could be wrong here) - and since it's only more recently that the majority of gamers have broadband, so having 56kers playing space-sims on the net doesn't work.
Anyway, I'm ranting.
One of the nicest things to get working would have been LaGrange points, but none of my experiments there got it to work consistently - mostly the game just crashed.
MajorTom
04-13-2004, 10:33 AM
Originally posted by Nanoprobe
....(first-person stuff is generally limited to 2D planes, allowing for prediction with less data - could be wrong here)
- and since it's only more recently that the majority of gamers have broadband, so having 56kers playing space-sims on the net doesn't work.
I dunno the details about prediction in EOC MP but I'm pretty sure the TRI and the score screen effects would screw up any games prediction calcs!
Hmm, BF 42 for example has planes and parachutes too. UT2K4 has flying sims too now. They may be exploiting broadband advantages.
Since most have broadband now, that would be another reason to give EOC MP a new chance too.
One of the nicest things to get working would have been LaGrange points, but none of my experiments there got it to work consistently - mostly the game just crashed.
You mean in MP, to jump from one server to another?
Sounds like a cool idea. Any idea why the game crashed? Would the server app create the L-Point mesh?
In EpicOnline we have a Jumpgate to take you back to the SP game and it even shows you a cutscene while thats happening. It works reliably (I've never had a crash at that point).
If the L-Point mesh won't show in the MP game, we could use the jumpgate and I'm pretty sure we could make a static server to server L-Point (or a couple of them) if the IP address of the other server(s) was known and constant.
Dynamic L-Points, that would periodically update and show the names of any servers around (the closest ones within an acceptable ping range) could well be possible too, if you started a "dummy" client via a special dedicated server script.
(you would have to set flux to allow 2 instances of the game if you also wanted to play as a client on the dedicated server)
Red_Hex
04-13-2004, 03:29 PM
fps netcode doesnt use 2 planes of movement. thats plain wrong.
Nanoprobe
04-14-2004, 09:19 AM
Red_Hex - no, but the prediction code sometimes does, IMO. Quake 2 is a good example of this - most of the time you're moving on a 2D plane, unless you're jumping/falling, so the calculations can be simplified a bit - if you're running, you're either going to turn left or right, or jump (ignoring other stuff like shooting). Based on that, the client only has to send a rotation delta and an 'isJumping' flag to the server - a space-sim, assuming a constant movement speed again, would have to send three rotation deltas. That's nearly triple the packet size assuming you don't quantize/compress the data.
If you actually play a networked game of Q2 you'll notice how much attention is paid to even interpolating positions when you're in midair (i.e. none), compared to the smooth movements of a player who's running on the ground.
MajorTom - I was more referring to using LaGrange points to jump around the system and have a system-wide MP game.
MajorTom
04-14-2004, 11:06 AM
Originally posted by Nanoprobe
...... - a space-sim, assuming a constant movement speed again, would have to send three rotation deltas. That's nearly triple the packet size assuming you don't quantize/compress the data.
Sounds like you are saying "it'll never work no matter what you do"
Anyhow, BF 42 and UT2K4 are obviously using flight sims too and before I-War2 was released allegience was a popular Space Sim. They all seem to be working satisfactorily
I still think the issues above are valid explanations for the problems with EOC MP and not the netcode itself. There may, of course, be other reasons I've not discovered yet, but thats what this thread is for. :D
I was more referring to using LaGrange points to jump around the system and have a system-wide MP game.
Aahh, no wonder it crashed. A system wide MP game would be very iffy because with EOC flux, accuracy deminishes very rapidly with distance. (one of the reasons why objects are culled at the 400 km range)
In the middle of the system (aka "map") you would have a constant hit rate while in the perimeter of a system, shooting at (or manipulating) a sim would give you very random hits at best .
You could achieve the same effect, though, with multiple servers. Each servers map (with say 400 km radius) would represent a smaller part of the whole system. The servers would be connected by "L-points" like for example Coyote is connected to Hoffers Wake, and the servers would be named accordingly.
Believe me, you can put a lot of stuff to discover and do in a 400 km radius. Since MP doesn't have/allow LDS, travel time across the 400 km map would be roughly comparable to trans-system travel in the SP game with LDS.
Red_Hex
04-14-2004, 03:52 PM
then what about tribes, 3d movement, no problems playing it in 99. and unreal tournament, there have been plenty of flying vehicle mods
in fact screw that; i was rocket jumping 20 miles off the arena on gravity-modded servers in quake 1 back in 1996. you spent most of the time in the air.
i rest my case
Nanoprobe
04-15-2004, 11:48 AM
*shakes head* Whatever, guys. I didn't say it was impossible, I just said space-sims are generally harder to predict and take more bandwidth.
Red_Hex - Quake 2 had horrible interpolation when you were in mid-air - especially if you were falling very fast. Not that it didn't work, but it was disorienting to aim at someone who was 'lagging' (for lack of a much better word) through the air.
MajorTom
04-21-2004, 08:07 PM
Here's another issue, and a fix for it explained below.
With all this stuff fixed, I really do believe the next MP mod will be great fun and I hope you all give it a chance.
Explanation:
Shortly after version F14.6 was released we noted that the use of bots would cause some servers to crash. i.e the game wasn't stable with bots but it would run well with real players only.
Thats why bots support was disabled in the what_rocksv2 scripts (except in one botmatch where only 2 bots are created at a time per player)
After weeks of testing and even completly recoding the bot implementation scripts:
The reason for the crashes appears to be nothing more than newer, faster PCs. (than the ones avaliable as the game was designed)
Apparently when bots kill each other in rapid succesion the C++ app that turns the server transmit flag off can't/doesn't react as fast as the deathscript kills the sim. So, the server tries to transmit an update for a null handle and crashes.
(Players have the same handle for the duration of a session even when they die, so they can't cause a crash, while the bots are re-created and get a new handle each time)
I dunno if this is a 100 % valid explanation but I do know that the fix works 100%!
2 times 5 hours solid server uptime with 8 bots and 2 players on 2 opposing teams! (before the fix it was like 5 to 15 minutes of server uptime with the same bots).
The fix is simple: the dead bot is placed 750 km away (out of site) and the script waits 5 secs before killing it. Meanwhile, a dummy sim explodes where the bot was shot, so the player never notices a difference.
(you can't just wait 5 secs or more in the deathscript because the player would still see the dead bot, long after it is 'dead').
The new, forthcoming MP mod will be way wicked cool stuff!
Stephen Robertson
04-22-2004, 07:38 AM
Sounds cool MajorTom. I'll have to play a game with you. You'll probably beat me, as I'm completely out of practice. :D
MajorTom
04-23-2004, 12:01 AM
Thats cool Stephen, it would be great to see you in a game.
If you join the same team I'm on I'll be very glad to keep your six clear ;)
Otherwise, well, we'll see :D
MajorTom
04-30-2004, 04:19 PM
One of the features in the new MP mod will be animated ships.
Here's a movie to DL with the animation in action. It's only 497 kb and plays 22 seconds.
It shows you the animation cycle as an external view and from the Hud perspective looking at your own ship.
download it, unzip it, double click the .wmv file, let your windows media player go to work (http://feeling42.bei.t-online.de/stuff/starwars/xwing/xw_anim.zip) :D
To reduce download size, the movie was made at 15 fps so the animation shown is a little slower than it actually runs in the game.
Unheard Of
04-30-2004, 04:50 PM
That looks fantastic :up:
vBulletin® v3.7.2, Copyright ©2000-2009, Jelsoft Enterprises Ltd.