Table of Contents

Class RestockableBuildableFobEntity<TInfo>

Namespace
Uncreated.Warfare.Fobs.Entities
Assembly
Uncreated.Warfare.dll

Buildable fob entity that periodically refills it's inventory from a BarricadeStateSave.

public abstract class RestockableBuildableFobEntity<TInfo> : BuildableFobEntity<TInfo>, IBuildableFobEntity, IFobEntity, ITransformObject, IDisposable where TInfo : IBuildableFobEntityInfo

Type Parameters

TInfo
Inheritance
RestockableBuildableFobEntity<TInfo>
Implements
Derived
Inherited Members
Extension Methods

Constructors

RestockableBuildableFobEntity(IBuildable, IServiceProvider, bool, TInfo?, Team, TimeSpan)

protected RestockableBuildableFobEntity(IBuildable buildable, IServiceProvider serviceProvider, bool enableAutoRestock, TInfo? info, Team team, TimeSpan refillInterval = default)

Parameters

buildable IBuildable
serviceProvider IServiceProvider
enableAutoRestock bool
info TInfo
team Team
refillInterval TimeSpan

Properties

PreventItemDrops

Whether or not contained items should be dropped when this buildable is destroyed.

public override bool PreventItemDrops { get; }

Property Value

bool

Methods

Dispose()

Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.

public override void Dispose()

HandleRestock()

protected virtual void HandleRestock()

Restock()

Restock the inventory of this buildable.

public void Restock()

Events

OnRestock

Invoked after this buildable gets restocked.

public event Action? OnRestock

Event Type

Action