Bot npc archer: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (Updated old entity format to {{this is a}}. This action was perfomed by a bot.)
(Preparing page for move. This action was perfomed by a bot.)
Line 1: Line 1:
{{lang|Bot npc archer}}{{ent not in fgd}}
{{langsp}}
{{this is a|e0|game=tf2|name=bot_npc_archer}}
{{ent not in fgd}}


{{code class|CBotNPCArcher|bot_npc_archer.cpp}}
{{code class|CBotNPCArcher|bot_npc_archer.cpp}}
Line 34: Line 34:
{{O BaseAnimating}}
{{O BaseAnimating}}
{{O BaseEntity}}
{{O BaseEntity}}
[[Category:NextBot Entities]]

Revision as of 12:24, 12 January 2024

English (en)Translate (Translate)
Icon-NotInFGD.png
This entity is not in the FGD by default.
See below for instructions on making it available.
C++ In code, it is represented by theCBotNPCArcherclass, defined in thebot_npc_archer.cppfile.

Entity description

This is a NextBot using the models\player\sniper.mdl model which wields a Huntsman. It will go into humiliation pose unless one of the following entities is present on the map:

If at least one of those entities exists, the archer will shoot any BLU player which can be attacked. The NPC aims for heads and aims ahead in case a target is moving. When a BLU player is killed by a headshot from this entity, the kill feed will display an environmental headshot death icon. In the case of a bodyshot, a regular environmental death will be shown. Despite first appearances, this NPC is teamless, and can take and give damage to RED or BLU players. A similar teamless state has been seen with poor coding.

Icon-Bug.pngBug:The entity does not compensate for gravity when shooting.  [todo tested in ?]
Icon-Bug.pngBug:When spawned using the ent_create bot_npc_archer command, this entity will try to go to the origin of the map, if a NAV file is present. This is because the command causes the game to spawn the entity to the origin of the map, and then teleports it to where the player is looking (if possible).  [todo tested in ?]

Dedicated console variables

Cvar/Command Parameters or default value Descriptor Effect
tf_bot_npc_archer_arrow_damage 75 arbitrary float Determines the arrow damage of NPC archer arrows.
tf_bot_npc_archer_health 100 arbitrary integer Determines the health of NPC archer bots.
tf_bot_npc_archer_shoot_interval 2 arbitrary float Determines the interval at which NPC archer bots fire.
tf_bot_npc_archer_speed 100 arbitrary integer Unused.

Keyvalues

Note.pngNote:Content moved to Rendering and studio model related KIO/Keyvalues for continuation of page history


Inputs

Note.pngNote:Content moved to Rendering and studio model related KIO/Inputs for continuation of page history


Outputs

Note.pngNote:Content moved to Rendering and studio model related KIO/Outputs for continuation of page history