Logic director query: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
(-added class hierarchy)
No edit summary
 
(2 intermediate revisions by 2 users not shown)
Line 1: Line 1:
{{lang|Logic director query}}
{{LanguageBar}}
__NOTOC__
__NOTOC__
{{CD|CLogicDirectorQuery}}
{{CD|CLogicDirectorQuery}}
{{l4d2 point|logic_director_query}} It is used to output the [[info_director|AI Director]]'s 'anger' value, where the director is angered by players that are performing well. This provides an opportunity for map elements to be adjusted in an attempt to appease the AI Director. Some examples include adjusting the goal distance and increasing/decreasing obscuring weather effects.
{{this is a|logical entity|name=logic_director_query|game=Left 4 Dead 2}} It is used to output the [[info_director|AI Director]]'s 'anger' value, where the director is angered by players that are performing well. This provides an opportunity for map elements to be adjusted in an attempt to appease the AI Director. Some examples include adjusting the goal distance and increasing/decreasing obscuring weather effects.


Any number of logic_director_query entities can exist in the same map, each with their own value range and noise settings.
Any number of logic_director_query entities can exist in the same map, each with their own value range and noise settings.
Line 13: Line 13:


==Inputs==
==Inputs==
{{IO|HowAngry|Asks the director: “On a scale of <Min Anger Range> to <Max Anger Range>, how angry are you?”}}
{{I|HowAngry|Asks the director: “On a scale of <Min Anger Range> to <Max Anger Range>, how angry are you?”}}


==Outputs==
==Outputs==
{{IO|OutAnger|Director is this much angry (expressed as an integer), fired in response to <code>HowAngry</code>. Sends the current remapped value of the director's anger to an entity of your choice ([[logic_case]] is generally the most useful).|param=int}}
{{O|OutAnger|Director is this much angry (expressed as an integer), fired in response to <code>HowAngry</code>. Sends the current remapped value of the director's anger to an entity of your choice ([[logic_case]] is generally the most useful).|param=int}}
{{IO|On20SecondsToMob|Fires 20 seconds before a mob is spawned.}}
{{O|On20SecondsToMob|Fires 20 seconds before a mob is spawned.}}
{{IO|On60SecondsToMob|Fires 60 seconds before a mob is spawned.}}
{{O|On60SecondsToMob|Fires 60 seconds before a mob is spawned.}}


== See also ==
== See also ==
* [[L4D2 Level Design/Director Queries]]
* [[L4D2 Level Design/Director Queries]]

Latest revision as of 04:53, 29 April 2025

English (en)中文 (zh)Translate (Translate)
C++ Class hierarchy
CLogicDirectorQuery
CPointEntity
CBaseEntity

logic_director_query is a logical entity available in Left 4 Dead 2 Left 4 Dead 2. It is used to output the AI Director's 'anger' value, where the director is angered by players that are performing well. This provides an opportunity for map elements to be adjusted in an attempt to appease the AI Director. Some examples include adjusting the goal distance and increasing/decreasing obscuring weather effects.

Any number of logic_director_query entities can exist in the same map, each with their own value range and noise settings.

KeyValues

Name (targetname) <string>[ Edit ]
The name that other entities refer to this entity by, via Inputs/Outputs or other keyvalues (e.g. parentname or target).
Also displayed in Hammer's 2D views and Entity Report.
See also:  Generic Keyvalues, Inputs and Outputs available to all entities

Min Anger Range (minAngerRange) <integer>
Max Anger Range (maxAngerRange) <integer>
The range of integers used to represent the director's anger. The value will be mapped within it. Choosing a wider range of numbers allows finer "anger management".
Noise (noise) <choices>
Randomises the entity's output slightly. “No noise” will cause the output being the exact remapped value of the director's anger, while “complete noise” will result in a random number within the anger range. There are various other levels in between.

Inputs

HowAngry
Asks the director: “On a scale of <Min Anger Range> to <Max Anger Range>, how angry are you?”

Outputs

OutAnger <integerRedirectOutput/integer>
Director is this much angry (expressed as an integer), fired in response to HowAngry. Sends the current remapped value of the director's anger to an entity of your choice (logic_case is generally the most useful).
On20SecondsToMob
Fires 20 seconds before a mob is spawned.
On60SecondsToMob
Fires 60 seconds before a mob is spawned.

See also