View Issue Details

IDProjectCategoryView StatusLast Update
0004249The Dark ModGUIpublic21.12.2018 15:47
Reporterdemagogue Assigned ToAgent Jones  
Status assignedResolutionopen 
Summary0004249: Request for AI Spawnarg to turn off Stealth Score counting Plot Enforced Busts
DescriptionVman339 made a request in the forums for a way for mappers to make the Stealth Score & presumably Alerts not to count plot or mapper enforced busts.


It seems reasonable because such busts aren't the player's fault, sometimes it could even be an in-game cutscene, and the old ghosting rules allowed players not to count them. It's still up to the mapper to decide though.

I think the spawnarg should be variable too. I mean, turning it on or off in the game by script allows, e.g., an AI's alerts to not count in one plot scene, but they do in normal gameplay later. (That may not be an issue, but I know some spawnargs aren't effective if you change them post-spawn.)
TagsNo tags attached.


Agent Jones

Agent Jones

13.11.2015 16:30

developer   ~0007890

Last edited: 13.11.2015 16:38

View 2 revisions

Here's my fix:
AI.cpp, inside idAI::UpdateEnemyPosition() change these lines:

line 7800 - if ((lastTimePlayerSeen < 0) && (lastTimePlayerLost < 0) && !spawnArgs.GetBool("NoAlertScore", "0"))

line 7806 - else if (lastTimePlayerLost > 0 && !spawnArgs.GetBool("NoAlertScore", "0"))

declare "bool NoAlertScore;" inside struct SObjEntParms so we can use it in missionEvent()

inside FillParmsData(idEntity *ent, SObjEntParms *parms) at line 1100 add:
parms->NoAlertScore = ent->spawnArgs.GetBool("NoAlertScore", "0");

inside MissionEvent(), around line 215 insert additional if check:
if (EntDat1->NoAlertScore) {
                goto Quit;

Finally, add this for mappers in entityDef atdm:ai_base (tdm_ai_base.def)
"editor_bool NoAlertScore" "If true, this AI won't affect your stealth score"

This spawnarg can be turned on and off ingame by a script.

Issue History

Date Modified Username Field Change
08.11.2015 02:13 demagogue New Issue
13.11.2015 15:39 Agent Jones Assigned To => Agent Jones
13.11.2015 15:39 Agent Jones Status new => assigned
13.11.2015 16:30 Agent Jones Note Added: 0007890
13.11.2015 16:38 Agent Jones Note Edited: 0007890 View Revisions