View Issue Details

IDProjectCategoryView StatusLast Update
0003019The Dark ModGUIpublic24.02.2012 00:48
Reporterdemagogue Assigned Tograyman  
PrioritynormalSeveritynormalReproducibilityhave not tried
Status resolvedResolutionfixed 
Product VersionTDM 1.07 
Target VersionTDM 1.08Fixed in VersionTDM 1.08 
Summary0003019: The "Stealth Score" stat for Alert-4 (agit. searches) is cascading, so it overcounts
DescriptionBaddcog reported a cascade for Alert-4's in the Alert stats GUI, which is reminiscent of the cascade for Alert-5 that grayman fixed a few months ago.

The discussion thread is here: forums.thedarkmod.com/topic/13499-menustatistics-issues/

His statistics were reported as follows:

alerts:40 supiciouss 1306 searched 19 sightings for (2m (it cuts off screen after that)

alerts
1.33x0 0
2.7x1 7
3.37x2 74
4.1269 x 3 3807
5.19x5 95
-------------
3983
TagsNo tags attached.

Relationships

related to 0002887 resolvedgrayman Stealth Score Level-5 bust ("being seen") isn't countable for the stats GUI because of incrementing "cascade" 

Activities

grayman

grayman

23.02.2012 19:28

viewer   ~0004346

Last edited: 23.02.2012 19:33

Here's what's happening ...

When an AI is alerted, the event is logged in mission statistics based on the AI's alert level at that moment. A simple counter is kept per alert level, and the counter bumps up by 1.

If an AI hears a player footstep, that raises his alert level a small amount. If he hears enough footsteps to raise him to alert level 4, he'll draw his weapon and start searching. Along the way to level 4, each footstep registers as a unique alert for the level the AI was at when he heard it.

So we might see statistics similar to the following when the player walks toward an AI, but stays out of sight:

Alert level 1: 1
Alert level 2: 1
Alert level 3: 1
Alert level 4: 15
Alert level 5: 0

If the AI spots the player, the sighting is one alert event, and each subsequent player footstep as the AI chases the player is registered as a unique alert event at level 5, and you can easily end up with stats that look like this if you lead the AI on a long chase:

Alert level 1: 1
Alert level 2: 1
Alert level 3: 1
Alert level 4: 15
Alert level 5: 150

We took care of the cascading for level 5 by simply tracking unique sightings and total time seen, so that changes the stats to:

Alert level 1: 1
Alert level 2: 1
Alert level 3: 1
Alert level 4: 15
Alert level 5: 1

It still leaves the high '15' value for level 4, though.

I'm guessing the original intent was to track the number of unique events that raise an AI to a particular alert level for the first time.

The code is not doing that. Instead, the code counts the number of times an AI is found to be at a certain level when an event occurs.

grayman

grayman

24.02.2012 00:48

viewer   ~0004347

Only bump the alert stat counts if the AI’s alert index increases.

Also fixed a bug in keeping track of the previous alert level, when the level wanted to cross indices but was capped.

rev. 5293:

AI.cpp

Issue History

Date Modified Username Field Change
13.02.2012 08:00 demagogue New Issue
13.02.2012 08:00 demagogue Status new => assigned
13.02.2012 08:00 demagogue Assigned To => grayman
13.02.2012 08:00 demagogue Relationship added child of 0002887
13.02.2012 08:01 demagogue Relationship deleted child of 0002887
13.02.2012 08:01 demagogue Relationship added related to 0002887
13.02.2012 08:03 demagogue Description Updated
13.02.2012 08:06 demagogue Description Updated
13.02.2012 08:17 demagogue Product Version TDM 1.08 => TDM 1.07
23.02.2012 19:28 grayman Note Added: 0004346
23.02.2012 19:32 grayman Note Edited: 0004346
23.02.2012 19:33 grayman Note Edited: 0004346
24.02.2012 00:48 grayman Note Added: 0004347
24.02.2012 00:48 grayman Status assigned => resolved
24.02.2012 00:48 grayman Resolution open => fixed
24.02.2012 00:48 grayman Fixed in Version => TDM 1.08