Base boss: Difference between revisions

From Valve Developer Community
Jump to navigation Jump to search
m (Added {{lang}}.)
m (cleaned up grammar.)
Line 1: Line 1:
{{lang|Base boss|title=base_boss}}
{{lang|Base boss}}
{{tf2 point|base_boss}} Its the entity that the{{ent|tank_boss}}entity, seen in [https://wiki.teamfortress.com/wiki/Mann_vs._Machine Mann vs. Machine], uses as a base, and has most of its behavior originating from. Thus so, it shares many behavior found within the<code>tank_boss</code>entity. A few examples being:
{{tf2 point|base_boss}} It is the entity that the {{ent|tank_boss}} entity uses as a base and thus shares a lot of its behaviors. A few examples include:
* Crushes engineer buildings that collides with it
* Crushes engineer buildings that collide with it
* TFBots treat this entity as an enemy
* TFBots treat this entity as an enemy
* Drops currency pack on death
* Drops currency pack on death
* Plays sounds to a client when it gets damaged
* Plays sounds to client when it gets damaged
 
{{ent|base_boss}} itself was originally intended for the now-scrapped {{tfwiki|Raid}} gamemode. By itself, it is static and does not perform anything; however, it is still of use in setting up a custom hitbox for any custom static NPC bosses.
By itself, it is static and does not perform anything. However, it is still of use in setting up a custom hitbox for any custom static NPC bosses
 
{{code class|CTFBaseBoss|tf_base_boss.cpp}}
{{code class|CTFBaseBoss|tf_base_boss.cpp}}
__TOC__


==Keyvalues==
==Keyvalues==
Line 15: Line 12:
{{KV|model|string|Filepath to the model this entity will use. Will use the model bounding box to determine its hitbox and collision}}
{{KV|model|string|Filepath to the model this entity will use. Will use the model bounding box to determine its hitbox and collision}}
{{KV|speed|float|The speed that this entity moves.}}
{{KV|speed|float|The speed that this entity moves.}}
{{KV|start_disabled|int|Start the entity disabled.}}
{{KV BaseEntity|base=1}}
{{KV BaseEntity|base=1}}
{{KV EnableDisable}}


==Inputs==
==Inputs==
Line 24: Line 21:
{{IO|RemoveHealth|Subtract this amount of health from the entity.|param=int}}
{{IO|RemoveHealth|Subtract this amount of health from the entity.|param=int}}
{{IO|SetSpeed|Sets this entity's speed to this value.|param=int}}
{{IO|SetSpeed|Sets this entity's speed to this value.|param=int}}
{{I BaseEntity|base=1|noscroll=0}}
{{I EnableDisable}}
{{I EnableDisable}}
{{I BaseEntity|base=1}}


==Outputs==
==Outputs==
{{IO|OnHealthBelow90Percent|to=OnHealthBelow10Percent|Fires when the entity's health goes below X percent of its maximum health.}}
{{IO|OnHealthBelow90Percent|to=OnHealthBelow10Percent|Fires when the entity's health goes below X percent of its maximum health.}}
{{IO|OnKilled|Fired when the entity is killed.}}
{{IO|OnKilled|Fired when the boss is killed.}}
{{O BaseEntity|base=1}}
{{O BaseEntity}}


<!-- Where do I fit this even -->
==See Also==
==Trivia==
*{{ent|tank_boss}}
* Initially, this entity was made for the ultimately scrapped PvE gamemode, [https://wiki.teamfortress.com/wiki/Raid Raid], and was to be featured more extensively with the mode's custom NPC bosses.

Revision as of 10:36, 8 October 2022

English (en)Translate (Translate)

Team Fortress 2 base_boss is a point entity available in Team Fortress 2 Team Fortress 2. It is the entity that the tank_boss entity uses as a base and thus shares a lot of its behaviors. A few examples include:

  • Crushes engineer buildings that collide with it
  • TFBots treat this entity as an enemy
  • Drops currency pack on death
  • Plays sounds to client when it gets damaged

base_boss itself was originally intended for the now-scrapped Tfwiki favicon.png Raid gamemode. By itself, it is static and does not perform anything; however, it is still of use in setting up a custom hitbox for any custom static NPC bosses.

C++ In code, it is represented by theCTFBaseBossclass, defined in thetf_base_boss.cppfile.

Keyvalues

health ([todo internal name (i)]) <integer>
Determines the initial health.
model ([todo internal name (i)]) <string>
Filepath to the model this entity will use. Will use the model bounding box to determine its hitbox and collision
speed ([todo internal name (i)]) <float>
The speed that this entity moves.


Start Disabled (StartDisabled) <boolean>
Stay dormant until activated (with theEnableinput).

Inputs

SetHealth <integerRedirectInput/integer>
Sets the entity's health to this value.
SetMaxHealth <integerRedirectInput/integer>
Sets the entity's maximum health to this value.
AddHealth <integerRedirectInput/integer>
Add this amount of health to the entity.
RemoveHealth <integerRedirectInput/integer>
Subtract this amount of health from the entity.
SetSpeed <integerRedirectInput/integer>
Sets this entity's speed to this value.

EnableDisable:

Enable / Disable
Enable/disable this entity from performing its task. It might also disappear from view.

Outputs

OnHealthBelow90Percent to OnHealthBelow10Percent
Fires when the entity's health goes below X percent of its maximum health.
OnKilled
Fired when the boss is killed.


See Also