CAI PlayerAlly

From Valve Developer Community
Revision as of 01:10, 29 May 2025 by Breakin' Benny (talk | contribs) (Ever since the SP stuff was moved to its own branch with the TF2 SDK update, the MP stuff has wound up in the main one)
Jump to navigation Jump to search
C++ Class hierarchy
CAI_PlayerAlly
CAI_BaseActor
CAI_ExpresserHost
CAI_BaseHumanoid
CAI_BaseHumanoidBase
CAI_BaseNPC
CBaseCombatCharacter
CBaseFlex
CBaseAnimatingOverlay
CBaseAnimating
CBaseEntity
C++ ai_playerally.cpp

Keyvalues

GameEndAlly <boolean> (in all games since Half-Life 2: Episode One)
This NPC will cause the game to end if killed.

Inputs

IdleRespond  !FGD
EnableSpeakWhileScripting
Allow this NPC to speak responses while in a scripted sequence or while StartScripting is active.
DisableSpeakWhileScripting
Cancels this NPC's ability to speak responses while in a scripted sequence or while StartScripting is active if it was previously enabled by EnableSpeakWhileScripting.

Since Half-Life 2: Episode One Half-Life 2: Episode One

SpeakResponseConcept <stringRedirectInput/string>
Speak the specified response concept immediately.
MakeGameEndAlly
If set, game ends if this character dies.
MakeRegularAlly
If set, game does not end if this character dies.
AnswerQuestion <integerRedirectInput/integer> !FGD
AnswerQuestionHello <integerRedirectInput/integer> !FGD