Skip to content

Sentry Asset Reference

The sentry asset type (classified internally as ItemSentryAsset, localized as "robotic turrets") is one of the most configurable deployable items in Unturned™ modding. A sentry asset defines an automated turret that, when placed and powered, detects, tracks, and attacks targets based on a configurable targeting mode. Unlike static barricades that simply exist in the world, sentries are active defense systems that interact with the combat, detection, and power mechanics of the game. Storing a ranged weapon inside a sentry allows the sentry to use that weapon's ammunition and damage profile when engaging targets, making the sentry's effectiveness directly dependent on what weapon the player supplies.

57 Studios™ has documented and validated the full sentry asset configuration surface across the shipped game files and the official Smartly Dressed Games documentation. This article covers every .dat field that applies to sentry assets, the detection and targeting system that governs target acquisition and loss, the three Mode enum values and their behavioral differences, the ammo consumption and weapon degradation mechanics, the sweep animation system that controls the sentry's visual scanning behavior, the inheritance chain from StorageAsset that provides the internal inventory grid, the folder structure required to deploy a functional sentry mod, and the complete field reference drawn from shipped game file evidence.

The vanilla Sentry turret deployed and active in the Unturned game world

Documentation source: This article references the official Smartly Dressed Games modding documentation for field definitions and game behavior, specifically the ItemSentryAsset class documented in the Sentry Assets chapter. Shipped game file evidence from Bundles/Items/Barricades/Sentry/, Sentry_Friendly/, and Sentry_Hostile/ is cited for field values and patterns. Community-validated notes are marked where the official documentation is silent on a detail.

Who this article is for

This article is written for Unturned™ mod authors who are comfortable with the barricade placement system, the item asset hierarchy, and the master bundle pipeline. Readers should have completed at least one barricade-type mod and one weapon mod before authoring a sentry asset. If you are new to Unturned™ modding, start with Project Folder Structure and GUIDs, Item Asset Anatomy, and Objects, Structures, and Barricades Asset Guide before returning here. Familiarity with the Gun Asset Reference and Magazine Asset Reference is strongly recommended because sentries interact directly with ranged weapon items.

What you will learn

  • Every .dat field available on the sentry asset type, including type, required status, default values, and purpose.
  • How the detection and targeting system works: detection radius, target loss radius, sweep mechanics, and the target acquisition cycle.
  • The three Mode enum values (Neutral, Friendly, Hostile) and their behavioral differences.
  • The Infinite_Ammo and Infinite_Quality flags and how they control weapon resource consumption.
  • The Requires_Power flag and the sentry's power system interaction.
  • The inheritance chain from StorageAsset and how the internal weapon storage works.
  • The Build Sentry and Build Sentry_Freeform placement categories.
  • How to author a complete sentry asset with worked .dat examples from all three vanilla sentry variants.
  • How to diagnose common sentry asset authoring errors using the diagnostic table.
  • How to tune sentry detection parameters for different gameplay scenarios.

How the sentry system works

The sentry system in Unturned™ is built around the ItemSentryAsset class, which extends the StorageAsset class. The storage base class provides an internal inventory grid where the player places a ranged weapon; the sentry subclass adds the detection, targeting, and engagement systems that make the turret autonomous.

When a player places a sentry on a valid surface, opens its inventory, and inserts a ranged weapon (a gun item with a valid ItemGunAsset configuration), the sentry enters the armed state. While armed and powered (if Requires_Power is true), the sentry begins scanning for targets within its Detection_Radius. When a valid target enters the detection radius, the sentry plays the Target_Acquired_Effect audio cue and begins tracking the target. If the target remains within the Target_Loss_Radius, the sentry tracks and fires at the target using the stored weapon's ammunition, spread, and damage profile. When the target leaves the Target_Loss_Radius, the sentry plays the Target_Lost_Effect and returns to scanning.

The sentry's targeting cycle is driven by the game's entity detection system. Each detection tick, the sentry performs a sphere cast centered on its position with a radius equal to Detection_Radius. Entities that match the sentry's target filters (controlled by Mode and the individual Target_* boolean fields) are flagged as valid targets. The sentry tracks the nearest valid target until it exits the Target_Loss_Radius, at which point tracking ends and the sentry resumes scanning for a new target.

The sentry placement and arming workflow

The player's workflow for deploying a functional sentry follows a specific sequence:

  1. Craft or spawn the sentry item.
  2. Open the build menu and select the sentry from the Utilities or Sentry category.
  3. Place the sentry on a valid surface (terrain, floor, foundation).
  4. Open the sentry's inventory (interact key on the placed sentry).
  5. Insert a ranged weapon into one of the sentry's storage grid slots.
  6. If Requires_Power is true, ensure a generator is within range and powered.
  7. The sentry automatically enters the scanning state. When a valid target approaches, it begins firing.

The sentry does not require the player to "activate" it after placing the weapon. The sentry is always active when powered and armed - it scans, tracks, and fires autonomously. The player's only ongoing responsibility is to keep the sentry supplied with ammunition (unless Infinite_Ammo is true) and to keep the weapon's quality above zero (unless Infinite_Quality is true).

File and folder structure

A complete sentry mod requires the following files:

Workshop/Content/304930/<modID>/
├── Bundles/
│   └── <BundleName>.unity3d          ← master bundle containing the sentry prefab
└── Items/
    └── MySentry/
        ├── MySentry.dat               ← primary configuration
        └── English.dat                ← display name and description

The sentry folder must be placed under Bundles/Items/ for the engine to discover it at load time. The folder name is irrelevant to the engine; only the Type Sentry field determines how the .dat is parsed.

Vanilla sentry organization

The vanilla game ships three sentry variants, each in its own folder under Bundles/Items/Barricades/:

FolderModeIDHealthDescription
SentryNeutral1244150Covers an area by automatically peppering threats with gunfire
Sentry_FriendlyFriendly1372300Covers an area by automatically peppering obviously dangerous threats with gunfire
Sentry_HostileHostile1373150Covers an area by automatically peppering even slightly dangerous threats with gunfire

All three variants share the same Build Sentry placement category and the same storage dimensions (5x2), detection radius (equivalent to Detection_Radius default), and sweep parameters. The primary differences are the Mode value, the Health (300 for Friendly, 150 for Neutral and Hostile), and the targeting behavior that Mode controls.

Inheritance chain

The sentry asset inherits from the storage asset class, which itself inherits from the barricade asset class, which inherits from the item asset class. This chain gives the sentry access to the inventory grid from StorageAsset, the placement and health system from BarricadeAsset, and the identity fields from ItemAsset.

The class diagram above shows the four-level inheritance chain that gives the sentry its combined storage, barricade, and sentry-specific capabilities. The sentry is the only item type that combines storage capacity with autonomous targeting behavior.

Complete .dat field reference

Identity fields

FieldTypeExampleRequiredPurpose
IDuint161244YesNumeric item ID. Must be unique across all loaded mods. Use IDs in the 50000+ range to avoid collision with vanilla and established community mods.
GUIDuint128 hex0c005ae5e4c74575af53ffe2144fad0bYes128-bit globally unique identifier. Generate a new GUID for every new item. Never reuse GUIDs.
TypeenumSentryYesMust be Sentry for sentry turret items. Any other value causes the asset to be parsed as a different type.
UseableenumBarricadeYesMust be Barricade for sentry items. This selects the barricade placement script at runtime.
BuildenumSentryYesPlacement category enum. Sentry or Sentry_Freeform. Controls which build menu category the sentry appears in.
NamestringSentryYesInternal name. Used in console commands and cross-reference in other .dat files.
RarityenumEpicNoControls the inventory highlight color. All three vanilla sentries use Epic.
SlotenumNoneNoInventory slot. Sentries use None; they are placed in the world, not equipped.
Size_Xuint82YesWidth in inventory grid cells as a held item.
Size_Yuint82YesHeight in inventory grid cells as a held item.
Size_Zfloat0.55NoZ-axis thickness for dropped item collision.

Barricade placement fields

FieldTypeExampleRequiredPurpose
Healthuint16150YesThe hit points of the sentry. When reduced to 0, the sentry is destroyed and drops its stored weapon and salvage items.
Rangefloat4YesThe placement range from the player in meters.
Radiusfloat0.5YesThe collision radius in meters. Affects placement clearance.
Offsetfloat1YesVertical offset from the placement surface in meters.
Explosionfloat36NoThe explosion radius in meters when the sentry is destroyed.

Storage fields

FieldTypeExampleRequiredPurpose
Storage_Xuint85YesThe width of the sentry's internal inventory grid in slots.
Storage_Yuint82YesThe height of the sentry's internal inventory grid in slots.
DisplayflagpresentNoPresence of this flag (no value needed) makes the sentry's inventory visually accessible. A Display sentry shows its contents when opened by a player.
LockedflagpresentNoPresence of this flag means the sentry's inventory is locked to the owner by default. Other players cannot open the sentry's inventory without permission.

Sentry-specific detection and targeting fields

FieldTypeRequiredDefaultExamplePurpose
Detection_RadiusfloatOptional4832The radius in meters within which the sentry detects valid targets on initial scan. Larger values mean the sentry spots targets from farther away but may also acquire unwanted targets at long range.
Target_Loss_RadiusfloatOptionalDetection_Radius * 1.240The radius in meters within which the sentry continues to track a target after the target leaves the initial detection radius. Defaults to 20% larger than Detection_Radius. This hysteresis prevents the sentry from rapidly acquiring and losing targets at the detection boundary.
ModeenumOptionalNeutralNeutralControls which entity categories the sentry considers valid targets. Values: Friendly, Neutral, Hostile. The Mode enum interacts with the server's reputation and group systems.

Mode targeting behavior

The Mode enum is the primary control over who the sentry attacks. The three modes produce distinct targeting behaviors based on the server's reputation and group affiliation system.

ModeBehaviorVanilla example
FriendlyAttacks targets that are enemies of the sentry's owner. Does not attack the owner, the owner's group members, or players with friendly reputation. Only attacks clearly hostile targets.Sentry_Friendly (ID 1372) , the most restrictive targeting mode
NeutralAttacks targets that are not group members of the owner. Attacks neutral and hostile reputation players but not group members or the owner.Sentry (ID 1244) , the default mode suitable for most base defense scenarios
HostileAttacks every valid target category regardless of group affiliation or reputation. Does not attack the owner. Attacks all other players, zombies, animals, and vehicles that match the individual Target_* filters.Sentry_Hostile (ID 1373) , the most aggressive mode, used for high-security areas

The Mode system uses the server's reputation tracking. A player who attacks another player accumulates negative reputation. The Friendly sentry uses this reputation data to distinguish "clearly hostile" targets from neutral or friendly players.

Per-target-type filtering fields

FieldTypeDefaultPurpose
Target_PlayersbooltrueIf true, the sentry targets player entities.
Target_ZombiesbooltrueIf true, the sentry targets zombie entities.
Target_AnimalsbooltrueIf true, the sentry targets animal entities.
Target_VehiclesbooltrueIf true, the sentry targets vehicle entities.

These boolean fields are AND-ed with the Mode filter. A sentry set to Mode Friendly with Target_Players true will attack enemy players. A sentry set to Mode Hostile with Target_Players false will ignore players and engage only zombies, animals, and vehicles that match the hostile mode criteria.

Power and bypass fields

FieldTypeDefaultPurpose
Requires_PowerbooltrueIf true, the sentry must be within the power radius of a powered generator to detect, track, and attack targets. If false, the sentry operates without external power, functioning as a standalone autonomous turret.
Sentry_Bypasses_PvEboolfalseIf true, the sentry can damage players and vehicles even on servers with PvE mode enabled. This allows sentries to function as base defense against players in PvE environments where direct player-to-player damage is normally disabled.
React_To_AttacksboolfalseIf true, the sentry immediately focuses on any entity that damages the sentry, regardless of whether that entity matches the normal targeting filters. This is a retaliatory behavior: the sentry prioritizes attackers over other valid targets until the attacker is dead or leaves the loss radius.

Ammo and quality consumption fields

FieldTypeDefaultPurpose
Infinite_AmmoboolfalseIf true, the stored weapon's magazine attachments are not depleted when the sentry fires. The weapon effectively has unlimited ammunition. If false, the sentry consumes ammunition from the weapon's loaded magazine normally.
Infinite_QualityboolfalseIf true, the stored weapon's quality (durability) does not degrade when the sentry fires. If false, the weapon's quality decreases with each shot and the weapon breaks when quality reaches zero.

The AmmoConsumptionProbability and QualityConsumptionProbability fields seen in shipped sentry files are not part of the standard ItemSentryAsset field set - they are additional fields on barricade storage items that control the probability of consuming ammo or quality per shot. Values of 0.25 (as seen on all three vanilla sentries) mean a 25% probability per shot that ammo or quality is consumed. This is distinct from the Infinite_Ammo and Infinite_Quality flags: the flags are hard overrides, while the probability fields are stochastic consumption modifiers.

Audio fields

FieldTypeDefaultPurpose
Target_Acquired_Effectasset pointer (GUID)ab5f0056b54545c8a051159659da8beaThe audio effect played when the sentry first detects a valid target. The default GUID points to a sentry-target-acquired sound.
Target_Lost_Effectasset pointer (GUID)288b98b718084699ba3653c592e57803The audio effect played when the sentry loses tracking on a target. The default GUID points to a sentry-target-lost sound.

Sweep fields

FieldTypeDefaultPurpose
Sweep_Yawfloat120The yaw range (in degrees) that the sentry sweeps left and right while scanning. A value of 120 means the sentry rotates 60 degrees left of center and 60 degrees right of center (120 degrees total arc).
Sweep_Periodfloat6.3The time in seconds for the sentry to complete one full sweep cycle (left to right and back to center). Shorter values make the sentry scan faster, detecting targets more quickly at the cost of a more frantic visual appearance.

The sweep system controls the sentry's visual scanning behavior. While no target is acquired, the sentry rotates left and right across the Sweep_Yaw arc at a speed determined by Sweep_Period. When a target is acquired, the sentry stops sweeping and faces the target, tracking it until lost.

The Build Sentry versus Build Sentry_Freeform distinction

The Build field supports two enum values for sentries: Sentry and Sentry_Freeform. These values determine the placement preview behavior.

Build valuePlacement behaviorUse case
SentryStandard barricade placement. The sentry snaps to the nearest valid surface grid and must be placed on a flat, clear area.Standard base defense sentries that sit on floors or foundations.
Sentry_FreeformFreeform placement. The sentry can be placed on more varied surfaces and angles without strict grid snapping.Sentries designed for unconventional placement (on vehicle roofs, on uneven terrain, at custom angles).

Both values produce the same runtime behavior after placement. The difference is only in the placement UX. Choose Sentry for standard turrets and Sentry_Freeform for sentries that need to be mounted in unusual locations.

Worked example: the three vanilla sentries

Neutral Sentry (default targeting)

The standard sentry at Bundles/Items/Barricades/Sentry/Sentry.dat:

GUID 0c005ae5e4c74575af53ffe2144fad0b
Type Sentry
Rarity Epic
Useable Barricade
Build Sentry
ID 1244

Size_X 2
Size_Y 2
Size_Z 0.55

Health 150
Range 4
Radius 0.5
Offset 1

Storage_X 5
Storage_Y 2
Display
Locked

Mode Neutral
React_To_Attacks true

AmmoConsumptionProbability 0.25
QualityConsumptionProbability 0.25

Explosion 36

Blueprints
[
	{
		CategoryTag "bfac6026305f4737a95fd275ebff65a6" // Utilities
		InputItems
		[
			{
				ID "3407a91dde0c4454b91d5af072f11a4c" // Spotlight
			}
			{
				ID "4eb615311edb4ef98ee95d8c70ba3c25" // Metal Rifle Rack
			}
			{
				ID "669bab19df634f859a2e61c39e428e59" // Rangefinder
			}
			{
				ID "5830b84bf8074caa91cf3f4dde0dd19e" // Blowtorch
				Delete false
			}
		]
		OutputItems this
		Skill Craft
		Skill_Level 3
		RequiresNearbyCraftingTags
		[
			"7b82c125a5a54984b8bb26576b59e977" // Workbench
		]
		Effect "84347b13028340b8976033c08675d458" // Wrench
	}
]

Should_Close_When_Outside_Range true
PlacementAudioClip Sounds/MetalPlacement.mp3
Has_Clip_Prefab false

Friendly Sentry (restricted targeting)

GUID 5a7281e9af4c435b8cb7f9f5acf05aa9
Type Sentry
Rarity Epic
Useable Barricade
Build Sentry
ID 1372

Size_X 2
Size_Y 2
Size_Z 0.55

Health 300
Range 4
Radius 0.5
Offset 1

Storage_X 5
Storage_Y 2
Display
Locked

Mode Friendly
React_To_Attacks true

AmmoConsumptionProbability 0.25
QualityConsumptionProbability 0.25

Explosion 36

Should_Close_When_Outside_Range true
PlacementAudioClip Sounds/MetalPlacement.mp3
Has_Clip_Prefab false

Hostile Sentry (aggressive targeting)

GUID 8f7670d2dabc449d8f38c8cb656c6acf
Type Sentry
Rarity Epic
Useable Barricade
Build Sentry
ID 1373

Size_X 2
Size_Y 2
Size_Z 0.55

Health 150
Range 4
Radius 0.5
Offset 1

Storage_X 5
Storage_Y 2
Display
Locked

Mode Hostile
React_To_Attacks true

AmmoConsumptionProbability 0.25
QualityConsumptionProbability 0.25

Explosion 36

Should_Close_When_Outside_Range true
PlacementAudioClip Sounds/MetalPlacement.mp3
Has_Clip_Prefab false

All three variants share the same blueprint recipe (spotlight, metal rifle rack, rangefinder, blowtorch), storage dimensions (5x2), explosion radius (36), and ammo/quality consumption probability (0.25). The differences are the Mode value and the Health (Friendly has 300; Neutral and Hostile have 150).

Authoring a new sentry asset

Step 1: assign ID and GUID

Choose an ID in the mod's assigned range (50000+). Generate a fresh GUID:

ID 50080
GUID a3b4c5d6e7f84a9b0c1d2e3f4a5b6c7d

Step 2: set type and build fields

Type Sentry
Useable Barricade
Build Sentry

Use Build Sentry for standard barricade-snapped placement. Use Build Sentry_Freeform for sentries that need freeform placement.

Step 3: set identity and inventory fields

Name MyCustomSentry
Rarity Epic
Slot None
Size_X 2
Size_Y 2
Size_Z 0.55

Step 4: set barricade fields

Health 200
Range 4
Radius 0.5
Offset 1
Explosion 36

Step 5: set storage fields

Storage_X 5
Storage_Y 2
Display
Locked

The Display flag allows players to see the sentry's contents when opening its inventory. The Locked flag prevents unauthorized players from accessing the stored weapon. The storage grid dimensions (5x2 = 10 total slots) must be large enough to hold at least one weapon. Most weapons occupy 3-6 grid slots, so a 10-slot grid provides comfortable capacity for a weapon plus spare ammunition magazines.

Step 6: set targeting fields

Mode Neutral
React_To_Attacks true

Target_Players true
Target_Zombies true
Target_Animals true
Target_Vehicles true

Step 7: set detection and sweep fields

Detection_Radius 48
Target_Loss_Radius 60
Sweep_Yaw 120
Sweep_Period 6.3

Step 8: set ammo and quality behavior

Infinite_Ammo false
Infinite_Quality false

AmmoConsumptionProbability 0.25
QualityConsumptionProbability 0.25

Step 9: set power requirement

Requires_Power true
Sentry_Bypasses_PvE false

Step 10: set audio effects

Target_Acquired_Effect ab5f0056b54545c8a051159659da8bea
Target_Lost_Effect 288b98b718084699ba3653c592e57803

Step 11: author English.dat

Name Custom Defense Sentry
Description An automated sentry turret that detects and engages hostile targets. Insert a ranged weapon to arm. Requires generator power.

Step 12: prepare the master bundle

The sentry prefab requires the InteractableSentry script on the root object, plus a storage interaction component for the inventory interface. The prefab hierarchy:

MySentryPrefab (root, with InteractableSentry script)
├── Model (MeshRenderer + MeshFilter - the sentry body and turret)
├── TurretPivot (child transform, rotated by sweep system)
│   └── Barrel (MeshRenderer + MeshFilter - the gun barrel model)
├── Animator (optional, for animated turret components)
└── AudioSource (optional, for ambient hum or targeting sounds)

Step 13: test in-game

  1. Copy the master bundle and .dat files to the local Unturned™ install's mod folder.
  2. Launch Unturned™ in single-player.
  3. Open the in-game console with ~.
  4. Spawn the sentry: @give <sentryID>.
  5. Place the sentry on flat terrain.
  6. Open the sentry's inventory and insert a ranged weapon with ammunition.
  7. If Requires_Power is true, place and fuel a generator within range.
  8. Attract a zombie or spawn an enemy. Confirm the sentry detects, tracks, and fires.
  9. Move the target out of the loss radius. Confirm the sentry loses tracking and returns to scan.
  10. Test sentry destruction: damage the sentry and confirm it explodes and drops the stored weapon.

Testing a sentry in single-player

  1. Spawn the sentry item and confirm it appears in inventory.
  2. Place the sentry on a valid surface. Confirm the placement preview matches expectations.
  3. Open the sentry's inventory. Verify the storage grid displays correctly.
  4. Insert a weapon (e.g., a rifle with a loaded magazine).
  5. Spawn a hostile entity (zombie). Confirm the sentry acquires it within the detection radius.
  6. Confirm the Target_Acquired_Effect audio cue plays.
  7. Confirm the sentry rotates to face the target and fires the stored weapon.
  8. Confirm ammunition is consumed from the weapon's magazine (unless Infinite_Ammo is true).
  9. Confirm weapon quality degrades (unless Infinite_Quality is true).
  10. Move the target beyond the loss radius. Confirm the sentry loses tracking and resumes scanning.
  11. Destroy the sentry. Confirm the explosion and weapon drop.

Diagnostic table

SymptomMost likely causeResolution
Sentry does not appear in inventory after @giveID mismatch or folder placementConfirm ID is unique and .dat is under Bundles/Items/
Sentry appears but cannot be placedUseable Barricade missing or wrongAdd Useable Barricade to the .dat
Sentry placed but inventory does not openStorage_X or Storage_Y missing or set to 0Set storage dimensions to positive values
Sentry inventory opens but weapon cannot be insertedSentry is Locked and player is not the ownerPlace the sentry as the server owner or use admin tools
Sentry does not detect targetsDetection_Radius is too small or entity filters exclude the target typeIncrease Detection_Radius; verify Target_* booleans
Sentry detects target but does not fireStored weapon has no loaded ammunitionLoad a magazine into the weapon before inserting it
Sentry fires but no damage registersWeapon has no ammunition or is out of rangeConfirm weapon has ammo; check sentry range to target
Sentry fires and consumes ammo too fastAmmoConsumptionProbability is too highReduce to 0.25 or lower for standard balance
Sentry fires but weapon never degradesInfinite_Quality is true or QualityConsumptionProbability is 0Set Infinite_Quality false and adjust probability
Sentry does not require power when it shouldRequires_Power is false or missingSet Requires_Power true
Sentry requires power when it should notRequires_Power is trueSet Requires_Power false
Sentry attacks friendly playersMode is Hostile instead of Friendly or NeutralChange Mode to the appropriate value
Sentry does not attack hostile players in PvESentry_Bypasses_PvE is falseSet Sentry_Bypasses_PvE true
Sentry does not retaliate when damagedReact_To_Attacks is false or missingSet React_To_Attacks true
Sentry target acquired sound does not playTarget_Acquired_Effect GUID is wrong or not setUse the default GUID or a valid audio asset pointer
Sentry sweep animation is wrong speedSweep_Period is too short (fast) or too long (slow)Adjust Sweep_Period from the default 6.3 seconds
Sentry destroyed with no explosionExplosion is 0 or omittedSet Explosion to a positive radius value
Sentry storage is empty after destructionThis is correct behavior , stored items drop on destructionPlace sentry in a secure area to protect stored weapons
Sentry model is invisible when placedPrefab not found in master bundleConfirm prefab name in bundle matches Name field

Balance considerations

Detection_Radius tuning

The detection radius controls how far the sentry can spot targets. A larger radius means earlier warning and engagement at greater distance, but also means the sentry may acquire targets that were not intended - zombies or neutral players at the edge of the base perimeter. The cohort recommendation is to match the detection radius to the expected engagement distance of the stored weapon type:

Weapon type storedRecommended Detection_RadiusRationale
Sidearm / SMG (short range)16-24Matches the weapon's effective engagement range
Assault rifle (medium range)32-48Vanilla default (48) works well for rifles
Sniper / DMR (long range)48-64Takes advantage of the weapon's range advantage
Shotgun (very short range)8-16Shotguns are ineffective beyond short range

Target_Loss_Radius hysteresis

The target loss radius should always be larger than the detection radius to prevent the sentry from rapidly acquiring and losing a target that is standing at the detection boundary. The default behavior (Detection_Radius * 1.2) provides a 20% hysteresis margin. For sentries in high-traffic areas where targets frequently cross the detection boundary, increase the loss radius multiplier to 1.5 or 2.0 to reduce target flip-flopping.

AmmoConsumptionProbability and economy

The AmmoConsumptionProbability field controls the expected lifespan of a loaded magazine in the sentry. At 0.25 (25% probability per shot), a 30-round magazine lasts approximately 120 shots on average. At 1.0 (100% probability), the same 30-round magazine lasts exactly 30 shots. For survival servers with scarce ammunition, lower values make sentries more economical. For high-intensity PvP servers, higher values create meaningful ammunition pressure on defenders.

Consumption probabilityExpected rounds per 30-round magazineGameplay impact
0.10 (10%)~300Very ammo-efficient; sentries can operate for extended periods
0.25 (25%)~120Vanilla default; reasonable balance
0.50 (50%)~60Ammo-hungry; defenders must resupply frequently
1.0 (100%)30Full consumption; each shot costs one round from the magazine

Infinite_Ammo and server role

The Infinite_Ammo flag should be used deliberately. A sentry with Infinite_Ammo true requires no ammunition supply, which removes the logistical pressure of keeping sentries fed. This is appropriate for admin-guarded locations, event zones, or briefing areas where sentries are decorative or tutorial. For standard survival gameplay, Infinite_Ammo false creates a meaningful supply chain where players must craft or loot ammunition for their sentries.

Frequently asked questions

Can a sentry fire without a weapon inserted?

No. The sentry requires a ranged weapon in its internal storage to fire. Without a weapon, the sentry scans and tracks targets but does not engage. The sentry's detection and sweep systems function independently of whether a weapon is present - the sentry can detect targets and play the acquired and lost audio cues, but the firing system requires a weapon. This is a common point of confusion for new sentry modders: the sentry appears functional (it scans, acquires targets, plays sounds) but does not actually fire because no weapon is loaded.

What weapon types can a sentry use?

A sentry can use any item that the engine recognizes as a ranged weapon (ItemGunAsset). This includes pistols, rifles, shotguns, sniper rifles, LMGs, and SMGs. Melee weapons, throwable items, tools, and consumables cannot be used by sentries. The sentry accesses the weapon's damage fields, fire rate, spread, and magazine configuration from the weapon's .dat file and the loaded magazine's .dat file. If the weapon uses a caliber that does not have a compatible magazine loaded, or if the loaded magazine is empty, the sentry cannot fire.

Does a sentry inherit the weapon's fire mode?

Yes. The sentry fires the weapon at the weapon's configured fire rate, using the weapon's spread pattern (hip-fire spread, not aimed spread). The sentry does not ADS (aim down sights); it fires from the hip position at the configured fire rate of the weapon. This means a sentry with a sniper rifle fires at the sniper's semi-auto rate, not at a sentry-specific fire rate. The sentry's engagement behavior is entirely driven by the stored weapon's configuration.

Can a sentry use attachments on the stored weapon?

The sentry accesses the stored weapon as a single item. If the weapon has attachments equipped (sight, grip, barrel, tactical attachments), those attachments are part of the weapon item and their effects apply normally. A weapon with a suppressor equipped through the sentry will fire silently. A weapon with a scope attachment will still use its hip-fire spread (the sentry does not ADS), so the scope's magnification bonus does not apply, but the weapon's base accuracy bonuses from the attachment class apply.

How do I make a sentry that does not require power?

Set Requires_Power false. The sentry will operate without a generator. This is appropriate for simple tripwire-style turrets, battery-powered defense drones, or magic/fantasy setting sentries where electricity is not part of the game's fiction. The vanilla sentries all default the power requirement behavior, and the shipped game files do not explicitly include Requires_Power false because false is the default for the field when omitted in the context of the inheritance chain.

Can a sentry distinguish between player factions?

The Mode system uses the server's group affiliation and reputation tracking. Players in the same group as the sentry's owner are not attacked. Players with friendly reputation toward the owner are not attacked by Friendly sentries but may be attacked by Neutral sentries. The sentry does not have its own faction configuration system; it relies entirely on the server's existing reputation and group mechanics. For RP servers with custom faction systems, a server-side plugin is required to override the sentry's targeting behavior.

What happens to the stored weapon when the sentry is destroyed?

The stored weapon (and any other items in the sentry's storage grid) drops to the ground as a world item when the sentry is destroyed. The weapon can be picked up by any player who finds it. This is important for base defense strategy: a destroyed sentry gives raiders access to whatever weapon was stored inside. If the weapon is valuable, the base designer should weigh the risk of losing it against the benefit of having the sentry operational.

Can I make a sentry with a larger storage grid?

Yes. Increase Storage_X and Storage_Y to provide more internal inventory slots. The sentry's storage grid is the same system used by all StorageAsset items. A sentry with Storage_X 10 and Storage_Y 5 (50 slots) can hold multiple weapons, spare magazines, and repair kits. However, the sentry only fires one weapon at a time - it uses the weapon in the first valid slot, not multiple weapons simultaneously. The additional storage is for convenience, not for multi-weapon operation.

Does the sentry target its owner?

No. The sentry never targets its owner, regardless of Mode setting. The owner is the player who placed the sentry. This is a hardcoded safety check to prevent friendly fire from base defense systems. If a player places a sentry and then stands in front of it, the sentry will not engage. If another player of the same group stands in front of it, the behavior depends on the Mode setting (Friendly will not attack, Neutral and Hostile may).

Can I place a sentry on a vehicle?

Standard sentries with Build Sentry snap to terrain and building surfaces. Sentries with Build Sentry_Freeform can be placed on vehicle surfaces, allowing vehicle-mounted turrets. The freeform placement mode provides more flexibility for unconventional mounting positions. Vehicle-mounted sentries require the vehicle to be powered (if Requires_Power is true) and remain functional while the vehicle is operational.

Best practices

  • Generate a fresh GUID for every sentry asset. Never reuse GUIDs from other items.
  • Choose IDs in the 50000+ range to avoid collision with vanilla and established community mods.
  • Match Detection_Radius to the stored weapon's effective engagement range. A sentry with a shotgun should not have a 48-meter detection radius.
  • Set Target_Loss_Radius higher than Detection_Radius by at least 20% to prevent target flip-flopping.
  • Use Mode to control sentry aggressiveness. Friendly for interior base defense, Neutral for perimeter defense, Hostile for high-security areas.
  • Keep Health balanced against the sentry's cost and role. An expensive sentry that dies in one hit is a poor investment.
  • Set Infinite_Ammo and Infinite_Quality to false for normal gameplay. Only use true for admin zones, tutorial areas, or special event items.
  • Match Sweep_Period to the desired visual scanning speed. 6.3 seconds is the standard; faster values (3-4 seconds) look more aggressive.
  • Always provide an English.dat that communicates the sentry's power requirement and weapon requirement.
  • Test the sentry with at least two different weapon types (a fast-firing SMG and a slow-firing sniper) to confirm fire rate and ammunition consumption behave correctly.
  • Verify the sentry's explosion radius does not damage nearby friendly structures.

Advanced considerations

Sentries in RP server contexts

On roleplay (RP) servers such as Horizon Life RP - a 57 Studios™ development context - sentries serve as faction-level defensive assets. The Mode field interacts with the server's faction reputation system; a sentry set to Friendly mode will not attack players from allied factions but will attack enemy faction members. Server-side claims plugins enforce ownership; only the owning faction can access the sentry's storage (due to the Locked flag) and retrieve the stored weapon. RP servers may restrict sentry crafting to specific professions (engineers, security specialists) and enforce per-faction sentry limits to balance base defense capabilities.

Sentries in competitive PvP contexts

On competitive PvP servers, sentries are both defensive tools and loot targets. An active sentry with a high-quality weapon is a force multiplier for base defense, but a destroyed sentry yields that weapon to the raiders. Base designers should consider placing cheaper weapons (common rifles, moderate ammunition) in sentries and reserving high-value weapons for personal storage. The React_To_Attacks flag is especially important on PvP servers: a sentry that does not retaliate when being shot at is a stationary target that does not fight back.

Custom sentry prefab with animated turret

The vanilla sentry uses a simple static model with a rotatable turret pivot. Custom sentry mods often include more elaborate animated components - a rotating radar dish, a camera lens that tracks the target, a barrel that recoils on each shot. These animations require the appropriate Unity Animator Controller states and must be wired to the InteractableSentry script's transform properties.

Multi-weapon sentry configurations

A single sentry can hold multiple weapons in its storage grid, but it only fires one weapon at a time. The sentry selects the first valid weapon in the grid (the weapon in the smallest-index slot that has loaded ammunition). When that weapon runs out of ammunition, the sentry does not automatically switch to a second weapon - it stops firing until the weapon is reloaded or replaced. Players must manually open the sentry's inventory, reload the weapon, or swap it for a fresh one. This is a critical gameplay constraint: sentries cannot operate indefinitely without player intervention (unless Infinite_Ammo is true).

Appendix A: sentry asset .dat quick-reference template

ID <50000+>
GUID <generated-uuid-no-hyphens>
Type Sentry
Name <InternalName>

Rarity Epic
Slot None
Size_X <2>
Size_Y <2>
Size_Z <0.55>

Useable Barricade
Build Sentry

Health <200>
Range <4>
Radius <0.5>
Offset <1>

Storage_X <5>
Storage_Y <2>
Display
Locked

Detection_Radius <48>
Target_Loss_Radius <60>
Mode <Neutral|Friendly|Hostile>
Target_Players true
Target_Zombies true
Target_Animals true
Target_Vehicles true
Sentry_Bypasses_PvE false
React_To_Attacks true
Requires_Power true

Infinite_Ammo false
Infinite_Quality false

Sweep_Yaw <120>
Sweep_Period <6.3>

Target_Acquired_Effect <default-guid>
Target_Lost_Effect <default-guid>

Explosion <36>

Blueprints
[
	{
		CategoryTag "<crafting-category-guid>"
		InputItems
		[
			{
				ID "<input-item-guid>"
				Amount <1>
			}
		]
		OutputItems this
		Skill Craft
		Skill_Level <0-7>
		RequiresNearbyCraftingTags
		[
			"<crafting-station-guid>"
		]
		Effect "<effect-guid>"
	}
]

AmmoConsumptionProbability 0.25
QualityConsumptionProbability 0.25

Should_Close_When_Outside_Range true
PlacementAudioClip Sounds/MetalPlacement.mp3
Has_Clip_Prefab false

Appendix B: sentry targeting mode quick-reference table

ModeAttacks owner?Attacks group members?Attacks neutrals?Attacks hostiles?Best use case
FriendlyNoNoNoYesInterior base defense, safe zones
NeutralNoNoYesYesPerimeter defense, general purpose
HostileNoYesYesYesHigh-security areas, combat zones

The Target_* boolean fields further refine each mode. For example, a Friendly sentry with Target_Players false and Target_Zombies true will only shoot zombies, not players - even hostile players are ignored because the player targeting is disabled at a higher priority than the mode filter.

Appendix C: sentry troubleshooting table

SymptomMost likely causeResolution
Sentry does not appear in inventoryID mismatch or .dat folder locationConfirm ID is unique; verify folder under Bundles/Items/
Sentry cannot be placedCollision obstruction, invalid surface, or Useable field wrongClear area; check Useable Barricade
Sentry placed but inventory inaccessibleStorage_X or Storage_Y is 0Set positive storage dimensions
Sentry does not detect targetsDetection_Radius too small or all Target_* booleans are falseIncrease radius; enable target type filters
Sentry detects but does not fireNo weapon stored, weapon has no ammo, or weapon type is not rangedInsert ranged weapon with loaded magazine
Sentry fires but weapon quality drops to zero and breaksInfinite_Quality is false and QualityConsumptionProbability is non-zeroThis is correct behavior; repair or replace the weapon
Sentry ammo depletes instantlyAmmoConsumptionProbability is 1.0 (100%)Reduce to 0.25 or lower
Sentry does not lose targets at boundaryTarget_Loss_Radius is too large relative to Detection_RadiusReduce loss radius or increase detection radius
Sentry attacked the ownerThis is not possible per hardcoded safety checkVerify the sentry's owner is correct
Sentry active sound is incorrectTarget_Acquired_Effect or Target_Lost_Effect GUID is wrongUse correct GUID for the intended audio effect

Appendix D: external references

ResourceURLNotes
Smartly Dressed Games modding documentationhttps://docs.smartlydressedgames.com/en/stable/Official field reference for sentry assets and storage assets
Unturned on Steamhttps://store.steampowered.com/app/304930/Unturned/Game changelog; combat update notes may reference sentry behavior changes
Gun Asset Reference/items/gun-asset-referenceWeapon configuration reference; the weapon types that sentries can use
Magazine Asset Reference/items/magazine-assetMagazine configuration; the ammunition consumables that sentries use
Storage Asset Reference/items/storage-assetStorage system reference; the base class that gives sentries their inventory grid
Generator Asset Reference/items/generator-asset-referenceGenerator documentation for powered sentry configurations
Objects, Structures, and Barricades Asset Guide/items/objects-structures-assetsBarricade placement system reference
Item Asset Anatomy/items/item-asset-anatomyShared field reference for all item types
Project Folder Structure and GUIDs/items/project-folder-structure-and-guidsGUID generation and folder layout prerequisites
Master Bundle Export/items/master-bundle-exportUnity bundling workflow for packaging sentry prefabs

Authoring checklist

Before publishing a sentry mod to the Steam Workshop, confirm the following:

  • [ ] GUID is unique - generated fresh, not copied from another asset
  • [ ] ID is in the 50000+ range and unique within the mod project
  • [ ] Type Sentry is present
  • [ ] Useable Barricade is present
  • [ ] Build Sentry or Build Sentry_Freeform is present
  • [ ] Storage_X and Storage_Y are set to positive values large enough for a weapon
  • [ ] Display flag is present if the sentry's inventory should be visible
  • [ ] Locked flag is present for default ownership protection
  • [ ] Mode is set to the intended targeting behavior
  • [ ] Detection_Radius is appropriate for the expected engagement distance
  • [ ] Requires_Power is set according to the sentry's power design
  • [ ] English.dat is authored with Name and Description in the same folder
  • [ ] Master bundle contains the sentry prefab with InteractableSentry script
  • [ ] Prefab has a turret pivot transform for sweep rotation
  • [ ] Material is assigned in Unity, not pink in the prefab
  • [ ] Blueprints block (if present) uses correct input GUIDs and crafting station tags
  • [ ] Tested in single-player: placeable, weapon insertable, target acquisition works, firing consumes ammo, destruction drops weapon
  • [ ] Tested with multiple weapon types to confirm fire rate and ammunition behavior
  • [ ] Tested without power (if Requires_Power true) to confirm sentry does not operate
  • [ ] Workshop description documents the weapon requirement and power requirement

Document history

VersionDateAuthorNotes
1.02026-07-2657 StudiosInitial publication. Complete sentry asset .dat field reference, targeting mode system, detection mechanics, storage integration, worked examples from all three vanilla sentry variants, FAQ, diagnostic tables, appendices.

Cross-references