What I learned in my struggles with lag. I hope this can help someone somewhere.
Rule 0. If its not broken, don't fix it.
Rule 1. Don't keep secrets, if you know something, share it.(unless it is cheating, then share it with Sheeo)
Rule 2. Correct noobs like me when they are confused.
Different kinds of lag:
Net Lag: The units/projectiles move slower; your UI/cursor shouldn't know about it
CPU Lag: The unit/projectiles/cursor/ui all move slower/stutter
GPU Lag: Camera stutter (when you are doing a lot of zooming in and out)
Arbitrary definitions:
UI Lag: unit is selected, followed by a pause, order is given, followed by a pause. If you try to ignore these pauses you will experience missing orders/orders given to wrong units/difficult to control cursor. If you find yourself trained to deselect your units after you have given them an order. If you find yourself waiting for the cursor to switch to assist while you are holding it above a unit. If you find it difficult to give orders close to there units because the cursor is stuck on assist. If you find it more optimal to place a row of buildings with a single click instead of placing 5 different buildings with 5 separate clicks. If you have problems quickly giving a series of move orders in an arbitrary pattern, with your move orders turning into patrol orders. If you often watch your units die knowing exactly how to save them if only you could give a couple different move orders, but instead feel like your hands are tied behind your back. Then you probably have some degree of UI Lag. Test: select an engie and give it an order to build a row of factories across the map, these factories should be placed almost instantly onto the map. Test: How quickly you can create a zigzag pattern of move orders, is it you or the ui that limits the maximum speed...
Cursor Lag: The degree to which the rate of motion of the cursor varies during the game. For example, the cursor slows down while pressing keys on the keyboard or when the cursor is over a large group of units, or when you are holding shift and giving a long sequence of orders to a large group of units. (If you have an old ps/2 wired mouse and running windows xp, you probably don't have these problems) (The first thing to do is to "Disable Display Scaling On High DPI Settings" in the compatibility tab in the properties menu of the forged alliance executable C:\ProgramData\FAForever\bin)
Build menu Lag: How quickly the build menu responds to your clicks and how quickly the build menues switch between units. The AZUI mod improves this. https://www.youtube.com/watch?v=qS1nNZCilG0
Pathfinding Lag: Those who have tried playing 40x40 maps with massive amounts of units have surely seen how units wait and think before responding. The larger the group of units the longer they think. If you enable cheats and go into sandbox you can recreate this lag on a smaller scale by setting path_armybudget to 1. This lag manifests itself quite early in the game when you frequently give new move orders to small groups of units. When a group of units is given an order the computer attempts to find the optimal path for each unit and an optimal position for each unit in the group of units that will result once the move order is completed. Therefore a good player will give move orders to small groups of already organized groups of units, with long move orders broken into a series of shorter move orders that attempt to traverse obstacles. The big issue is that the speed of units that are executing a move order that was given to a group of units will be limited not only by the maximum speed of the individual units, but by how optimally and rapidly the individual paths for the units are chosen. Note: this is not Ctrl + move orders, the units will attempt to assemble into a group at the destination of the move order regardless, but will not necessarily stay in the group while traveling to the destination, unless the computer finds this optimal, hence regular orders sometime appear identical to Ctrl + move orders.
Overall pathfinding lag can be controlled by the player's choice of move orders, unless there is a large degree of ui lag. There are other factors that contribute to this lag, but I have not been able to pin point these exactly. I have seen a clear variation of this between different players and different conditions of my computer/supcom FA. It does appear that whatever you can do to free up your cpu and to increase the priority of supcom FA over other bs happening on your pc does contribute to improving pathfinding lag.
Dealing with lag using console commands:
Warning: Some commands do not take effect once you put them into the console, but become active next time you run supcom FA.(not restart replay) Some commands are reset after you restart supcom FA, others persists forever. Some commands that persist will ruin your life. Some persisting commands can have been activated by mods that you no longer have activated. If you start running random console commands to see what happens, you will eventually end up reinstalling supcom FA. ui_resetview does nothing useful.
Console++ mod for running console commands at the start of every game viking.gurut.org/Mods/console++%201.01.rar (thanks Viking)
ConExecute("command 0") in console++ results in command = 0 in the console in game(~ or shift+~)
Misc. Standard:
ConExecute("sim_DebugDelay 0")
ConExecute("ui_DisableCursorFixing on")
ConExecute("fog_DistanceFog off")
ConExecute("ren_fog off")
ConExecute("res_EnablePrefetching off")
ConExecute("ren_NewFogUpdate off")
ConExecute("ren_NewPipeline off")
ConExecute("cam_ShakeMult 0")
ConExecute("ren_ErrorCache off")
ConExecute("ren_Splats off")
ConExecute("sc_FrameTimeClamp 1") (the bigger the number the less strain on gpu, although smaller numbers appear to remove some stuttering when zooming in and out, the default is 10)
ConExecute("ren_NormalDecals off")
ConExecute("ren_DecalFidelity 200") (the smaller the number the more decals you see)
Camera position:
ConExecute("cam_NearPitch 70")
ConExecute("cam_NearZoom 105") (This sets how close you can get to the surface of the map, unless you change this I would not change the others in this section. If you make it look good on one map it might be horrible
on another. Staying zoomed out makes your cpu/gpu work less)
ConExecute("cam_FarPitch 83")
ConExecute("cam_NearFOV 60")
ConExecute("cam_FarFOV 120")
Camera Zooom: (I would not mess with these, except perhaps increasing cam_ZoomAmount to 1 while on setons, also decreasing cam_ZoomSpeedSmall might decrease the vertigo of viewers watching you play)
ConExecute("cam_ZoomSpeedSmall 0.3")
ConExecute("cam_ZoomSpeedLarge 5") (set to 50 if you have just drunk a case of redbull)
ConExecute("cam_ZoomAmount 0.8")
Cursor Behavior:
ConExecute("ui_ExtractSnapTolerance 10") (These affect the placement of mexes)
ConExecute("ui_MinExtractSnapPixels 10")
ConExecute("ui_MaxExtractSnapPixels 100")
ConExecute("ui_SelectTolerance 6") (At low values the cursor will ignore entities around it, at high values the cursor snaps onto various entities around it at the cost of ui lag)
ConExecute("ui_CommandClickScale 0.9") (At low values the cursor lag is eliminated but it become difficult to select anything, at high values the ui becomes very laggy)
ConExecute("cam_EntityBoxExpand -10") (Appears to improve ui lag at negative values)
ConExecute("ui_MinWaypointSize 50") (Larger values make it easier to manipulate orders already given)
ConExecute("ui_MaxWaypointSize 150")
ConExecute("ui_PathPreview on") (Appears to improve cursor lag and makes it easier to give orders in crowded conditions)
ConExecute("SC_ToggleCursorClip off") (Do not tab out while the game is loading if you have SC_ commands in the console++ mod(you won't get into the game), these should percist and it shouldn't be necessary to put them into the mod, however it might not be true)
ConExecute("SC_VerticalSync on") (Don't put sc_ commands in the console during the actual game, there is a 5-10% chance you will crash, without your opponent also crashing)
Net problems:
In large games when you zoom in and out of a large group of units your net may spike causing freezes. One way to make this less severe is to set net_SendDelay = 100 in the console. The default value is 25. This may or may not help during battles, if you find out, please post here.
Visual:
ConExecute("ui_LifebarOffset 0.4")
ConExecute("ren_BorderSize 30")
ConExecute("range_OuterThicknessCoeff 0.001")
ConExecute("ren_BloomBlurKernelScale 0.9")
ConExecute("ui_LifebarLOD 400")
ConExecute("ren_ShadowLOD 200")
ConExecute("ren_SelectBracketMinPixelSize 3")
ConExecute("ren_SelectBracketSize 3")
ConExecute("ren_SelectionSizeFudge 5")
ConExecute("ui_StrategicIconBlinkDuration 2")
Level of detail change during zoom: (Some combination of these commands can absolutely destroy your sim speed, so I would be very careful changing these, if someone finds a good combination please let me know)
ConExecute("sc_CameraScaleLOD 2") (This command only take effect once you restart supcom fa, not just the replay. With higher values the level of detail appears to change more rapidly, however it is very confusing exactly how things are determined. If you make the number too high things look really bad and the game stutters )
ConExecute("cam_HighLOD 0.5")(The cam_ commands do not appear to persist and have to be put into console++, it is really confusing for my head how they actually behave)
ConExecute("cam_LowLOD 1.4") (The effect of a cam_ command can be observed if you switch between different level of detail options in the game)
ConExecute("cam_MediumLOD 1") (If you set cam_HighLOD to 0.1 and then go into options and go between medium and high level of detail a few times, you will be able to see rocks from any zoom distance, however I don't think the game is playable)
ConExecute("ren_MeshDissolve 100") These allow you to see reclaim from further away at a cost to the gpu/cpu.
ConExecute("ren_MeshDissolveCutoff 0.1")
In game settings:
Vsync on
Level of detail medium (you can actually see more stuff this way I think)
AA off and Medium Fidelity, The difference in ui lag between medium and high fidelity is high enough, but you may choose to put on high fidelity on maps like Setons
On the MFD panel make sure you don't have the military overlays activated. I only have radar and sonar activated.
GPU settings: (This is probably system dependent)
Make sure your GPU does not decrease clock speed during gaming. This can occur due to power saving options, or Boost 2.0, or bugs, etc. (just check that it doesn't occur)
Turn off shader Cache
Maximum pre rendered frames 1
Triple buffering on
Anisotropic Filtering on (really helps to make icons more clear)
Threaded optimization off
Frame rate limited 60 fps
Highest available refresh rate
Allow vsync to vary refresh rate
vsync smooth afr on
Gsync on (I don't get this at all, but it makes things smoother)
AA off
FAF settings:
Turn off logs
Registry settings:
Don't mess with these and if you do write down what you did. If you do mess with it try to stay within HKEY_CURRENT_USER\Control Panel\Mouse
Run: regedit
Standard place for mouse settings: HKEY_CURRENT_USER\Control Panel\Mouse
However the above are often ignored(especially after restart) because there are multiple profiles doing random things at once in windows;
the list is here HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList with "ProfileImagePath" containing the identity of the profile
The mouse settings for these other profiles are here:
HKEY_USERS\.DEFAULT\Control Panel\Mouse
HKEY_USERS\S-1-5-18\Control Panel\Mouse
HKEY_USERS\S-1-5-19\Control Panel\Mouse
HKEY_USERS\S-1-5-20\Control Panel\Mouse
HKEY_USERS\S-1-5-21-blablalbla\Control Panel\Mouse
MouseHoverTime change from 400 to 50
This sets the time in milliseconds that the cursor has to be above an entity for the computer to realize there is an entity there
MouseHoverWidth change from 4 to 3
MouseHoverHeight change from 4 to 3
This sets the size of the mouse cursor (very similar to ui_CommandClickScale)
Together the above make it easier for the computer/user to pinpoint different entities
Sounds:
Setting audio quality to the lowest setting in speaker properties appears to help some ui lag, especially when zoomed in close.
Deleting sound files from C:\Program Files (x86)\THQ\Gas Powered Games\Supreme Commander - Forged Alliance\sounds
After messing with this I have placed all the sound files back, but this could be useful. Make sure you don't have logs enabled, because you will have a lot of errors when you zoom in. ConExecute("snd_SpewSound") appears to remedy some of the error spewage.
Other:
Remove mods that you don't use from your mods folder.
https://www.youtube.com/watch?v=7WMSFqrUcw0