Obj sentrygun: Difference between revisions
Jump to navigation
Jump to search

Note:Content moved to Rendering and studio model related KIO/Keyvalues for continuation of page history
Note:Values higher than 2 are accepted (need to be typed in with SmartEdit off), with the limit being 90. With higher levels, the objects gain more health/damage/recharge speed.
Note:Content moved to Rendering and studio model related KIO/Inputs for continuation of page history
Note:Content moved to Rendering and studio model related KIO/Outputs for continuation of page history
m (→Flags) |
Kestrelguy (talk | contribs) (switched from Targetname, Parentname, and Angles templates to BaseAnimating templates.) |
||
Line 1: | Line 1: | ||
{{lang|Obj sentrygun}} | |||
{{tf2 point|obj_sentrygun}} | {{tf2 point|obj_sentrygun}} | ||
[[Image:TF2 Sentries.PNG|thumb|400px|right|Sentry Guns in TF2 at levels 1, 2 and 3.]] | [[Image:TF2 Sentries.PNG|thumb|400px|right|Sentry Guns in TF2 at levels 1, 2 and 3.]] | ||
Line 5: | Line 6: | ||
Used to place a Sentry Gun in your map. The Sentry Gun is a defensive building that puts heavy fire on any enemies that come into range. The Sentry Gun has a range of 1100 Hammer Units from its origin. | Used to place a Sentry Gun in your map. The Sentry Gun is a defensive building that puts heavy fire on any enemies that come into range. The Sentry Gun has a range of 1100 Hammer Units from its origin. | ||
==Keyvalues== | ==Keyvalues== | ||
{{KV | {{KV BaseAnimating|base=1}} | ||
{{KV TFObject}} | {{KV TFObject}} | ||
Line 16: | Line 15: | ||
==Inputs== | ==Inputs== | ||
{{I | {{I BaseAnimating|base=1}} | ||
{{I TFObject}} | {{I TFObject}} | ||
==Outputs== | ==Outputs== | ||
{{O | {{O BaseAnimating|base=1}} | ||
{{O TFObject}} | {{O TFObject}} |
Revision as of 09:57, 19 April 2022


obj_sentrygun
is a point entity available in Team Fortress 2.
Entity description
Used to place a Sentry Gun in your map. The Sentry Gun is a defensive building that puts heavy fire on any enemies that come into range. The Sentry Gun has a range of 1100 Hammer Units from its origin.
Keyvalues

TFObject:
- Team (TeamNum) <choices>
- Team
- 2 : Red
- 3 : Blue
- Starting Upgrade Level (defaultupgrade) <choices>
- Object spawns in the selected level.
- 0 : Level 1
- 1 : Level 2
- 2 : Level 3

- SolidToPlayer (SolidToPlayer) <choices>
- Object is solid or non-solid to players. !FGD
- 1 : Solid
- 0 : Non-solid
Flags
- 2 : Invulnerable
Bug:Invulnerable buildings can still be stunned with the Sapper, or completely destroyed with the Red Tape Recorder [todo tested in ?]
- 4 : Upgradable
- 8 : Infinite Ammo
Inputs

TFObject:
- SetHealth <integer >
- Sets the current and maximum health. If the object is upgraded, the health will scale according to the new value.
Bug:Crashes if set to 0. [todo tested in ?]
- AddHealth <integer >
- Increase the current health of the object. Does not surpass maximum health. Does not destroy the building if set at 0.
- RemoveHealth <integer >
- Decrease current health of the object. Destroys the object if the health hits 0.
- SetSolidToPlayer <boolean >
- Sets the object to be solid or non-solid to players. 0 - non-solid, 1 - solid. !FGD
Note:The builder of the building will always be solid to the object.
- SetBuilder
- Sets the builder of the object to the !activator.
- Show
- Makes the building visible and re-enables it.
- Hide
- Makes the building invisible and disables it.
Bug:Does not hide the obj_dispenser screen. A workaround is to fire the
SetInactive
(orSetActive
) on the vgui_screen entity, although it will apply to all buildings. [todo tested in ?]
- Enable
- Enable the object.
Note:Using
Enable
after using theHide
input will enable the building and keep it invisible.Bug:
Enable
will reset the upgrade level on the object. Use theShow
input instead, which properly re-enables the object. [todo tested in ?]
- Disable
- Disable the object.
Outputs

TFObject:
- OnDestroyed
- Sent when object dies.
- OnDamaged
- Sent when hurt. Works with !activator.