berto -> RE: Unit Counters Hang When Moving Long Distances (2/6/2022 12:08:29 PM)
|
On second thought... In Manual/LUA_FUNCTIONS_REFERENCE.txt, there is this: FUNCTION unset_move_tracking () DESCRIPTION Toggles OFF game engine unit movement tracking, thereby on_unit_move() is not triggered. Consider calling this function (in on_startup(), and on_resume()) if game performance lags. INPUTS none RETURN VALUE none EXAMPLES unset_move_tracking() SEE ALSO set_move_tracking () is_move_tracking () move_tracking () And its companion function: FUNCTION set_move_tracking () DESCRIPTION Toggles ON game engine unit movement tracking, thereby triggers on_unit_move(). INPUTS none RETURN VALUE none EXAMPLES set_move_tracking() SEE ALSO unset_move_tracking () is_move_tracking () move_tracking () There is much processing overhead as, in real time, the game engine communicates the details of movement to the CSEE. Add to that the extra processing required to render the 3D, yes, you might observe the occasional stutter. One fix would be to get in the habit of using the 8 or 9 hotkey to 2D zoom out before long-distance helo moves, then use the appropriate hotkey to toggle back to your earlier map zoom level. Also note the first two bullet point items here: http://www.matrixgames.com/forums/fb.asp?m=5132033 If the above suggestions don't suffice, if this issue continues to be terribly bothersome, you might consider adding the highlighted to your user.lua file (located in the top-level game folder): ------------------------------------------------------------------------------------------------------------------------ --[[ user.lua -- called each time a scenario is started, or resumed (after a save and scenario restart). Intended for global identifiers, "uber functions" (unofficial, subject to change), and other shared, common odds & ends. --]] ------------------------------------------------------------------------------------------------------------------------ --[[ -- With DEBUG=true, user.lua, init.lua, and all [scenario filename].lua files in Scenarios folder will adapt to this setting; -- use when debugging your Event files. -- Hand edit the DEBUG toggle here, maybe, but better to set DEBUG at the game engine command line with the -G switch -- (sets DEBUG to true; omitting the switch, DEBUG defaults to false); and/or use Ctrl+Alt+G in-game to goggle DEBUG=true -- DEBUG=false. DEBUG = false #DEBUG = true -- Note also that the command-line switch -E toggles on/off Lua script execution tracing. -- In addition to the command-line switch -L# (e.g., -L3) to raise/lower the game engine LogLevel (higher is more verbose, -- and slower). -- With all logging cranked up to the max -- ... -G -E -L5 ... -- the game will run glacially s-l-o-w, so beware! --]] ------------------------------------------------------------------------------------------------------------------------ unset_move_tracking () ------------------------------------------------------------------------------------------------------------------------ The above would toggle OFF movement tracking in all scenarios. Not advised. If it is bothersome only in some scenarios, you can instead try this (as mentioned in the LUA_FUNCTIONS_REFERENCE.txt): Consider calling this function (in on_startup(), and on_resume()) if game performance lags. You would do that edit in individual scenario Lua files' on_startup() and on_resume(). Try not to do any of this; try to leave ON movement tracking, the default. Because otherwise on_unit_move() is not triggered, and the CSEE (and the SAI) are deprived of real-time movement and unit location updates thereby. That could have bad CSEE/SAI implications. So only turn movement tracking OFF if you really feel the need to. It might be something else, but this movement tracking thing might be the prime suspect. Good luck.
|
|
|
|