Page MenuHomeFeedback Tracker

AI enablesimulation and hideobject still impacts framerate
Closed, ResolvedPublic

Description

Much like a somewhat related issue that was fixed recently (http://feedback.arma3.com/view.php?id=18451), I've moved on to caching of AI units. This issue seems to be a different beast as one can't simply modify the "config.bin" of AI to figure out exactly what is still simulating.

If one were to set:

                _x disableAI "TARGET";
                _x disableAI "AUTOTARGET";
                _x disableAI "MOVE";
                _x disableAI "ANIM";
                _x disableAI "FSM";
                _x enableSimulation false;
                _x allowDamage false;
		_x hideobject true;

One would think that the unit would no longer consume resources. However when testing hundreds of AI, such is not the case and the only way to regain FPS would be to deletevehicle.

Related forum topic (ZBE_Cache): http://forums.bistudio.com/showthread.php?177125-WIP-ZBE_Cache-(caching-addon-script) {F23903}

Details

Legacy ID
1869008580
Severity
None
Resolution
Fixed
Reproducibility
Always
Category
Performance
Steps To Reproduce

Run repo mission, baretail the rpt log (highlight ZBE if you'd like) and look at FPS. It's automated. Adjust sleep as necessary for your machine's performance (in init.sqf).

"ZBE 144 Groups, 144 Units, 7 NoCacheFPS, 30 CachedFPS, 54 DeletedFPS"

7NocacheFPS means with 144 Groups, 1145 Units. 30CachedFPS means 144 groups 1001 "cached" units. 54DeletedFPS means 144 groups, 144 units.

No repo mission test:

Spawn in 744 units (or any high number) then execute:
{

                _x disableAI "TARGET";
                _x disableAI "AUTOTARGET";
                _x disableAI "MOVE";
                _x disableAI "ANIM";
                _x disableAI "FSM";
                _x enableSimulation false;
                _x allowDamage false;
		_x hideobject true;

} forEach allUnits;

Keep an eye on FPS.

Then do:

{deleteVehicle _x} forEach allUnits;

Notice FPS returns to pre-createvehicle state.

Additional Information

I've tried removing all weapons, stripping all gear, etc thinking it could be something to do with equipment or weapons but no change in FPS. It's also interesting to note that:

_x enablesimulation false;
_x hideobject true;

by itself (without any of the disableAI commands) results in the same or *slightly* lower FPS.

What is still simulating?

One could roll their eyes at such a "performance" issue as most missions don't spawn in so many units (most create/delete during mission runtime) however I argue that createvehicle and deletevehicle sends packets which impacts netcode performance which is multiplied with high playercount.

enablesimulation false objects do NOT send packets and would be much desired IF such a "caching" method had comparable performance to createvehicle/deletevehicle.

Event Timeline

zorrobyte edited Steps To Reproduce. (Show Details)May 6 2014, 6:41 AM
zorrobyte edited Additional Information. (Show Details)
zorrobyte set Category to Performance.
zorrobyte set Reproducibility to Always.
zorrobyte set Severity to None.
zorrobyte set Resolution to Fixed.
zorrobyte set Legacy ID to 1869008580.May 7 2016, 6:34 PM
zorrobyte edited a custom field.

Repo mission added. I could simplify however I have a busy week ahead. Fank may look at it later.

Test system: i5-2500K @ 4.8GHZ/Nvidia GTX 670

1.18 Stable Branch (5/12/2014)
"ZBE 144 Groups, 1145 Units, 15 NoCacheFPS, 48 CachedFPS, 60 DeletedFPS"

12-05-2014
No new EXE
Size: ~199 MB
http://goo.gl/EN8ciF
"ZBE 144 Groups, 1145 Units, 13 NoCacheFPS, 47 CachedFPS, 60 DeletedFPS"

Will update from time to time with new dev branch builds.

13-05-2014
EXE rev. 124294
Size: ~83 MB
http://goo.gl/4KAfxB
...
"Minor PhysX optimization"
...
"ZBE 144 Groups, 1145 Units, 17 NoCacheFPS, 51 CachedFPS, 59 DeletedFPS"

Hello,

the framerate should be better now (exe rev. 124691 and higher). We did as much as we could at the moment. We realise how important this issue is and certainly we'll give it more love in future when conditions allow so.

Thank you.

MadDogX added a subscriber: MadDogX.May 7 2016, 6:34 PM

Mass closing tickets marked as resolved more than 1 month ago.

If the issue is in fact not resolved, please create a new ticket referencing this one and ask for it to be re-opened.