Skip to content
This repository has been archived by the owner on Nov 1, 2024. It is now read-only.

Commit

Permalink
Create AutoDeleteComponent.cs
Browse files Browse the repository at this point in the history
  • Loading branch information
Vonsant authored May 2, 2024
1 parent 84765cc commit 2c15704
Showing 1 changed file with 31 additions and 0 deletions.
31 changes: 31 additions & 0 deletions Content.Server/Corvax/AutoDeleteItems/AutoDeleteComponent.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
using Content.Shared.Timing;
using Robust.Shared.Audio;
using Robust.Shared.Serialization.TypeSerializers.Implementations.Custom;

[RegisterComponent]
[AutoGenerateComponentState, AutoGenerateComponentPause]
public sealed partial class AutoDeleteComponent : Component
{
[DataField, ViewVariables(VVAccess.ReadWrite)]
public bool IsHumanoidNear = false;

[DataField, ViewVariables(VVAccess.ReadWrite)]
public bool ReadyToDelete = false;

[DataField, ViewVariables(VVAccess.ReadWrite)]
[AutoPausedField]
public TimeSpan NextTimeToDelete;

[DataField, ViewVariables(VVAccess.ReadWrite)]
[AutoPausedField]
public TimeSpan NextTimeToCheck;

[DataField, ViewVariables(VVAccess.ReadWrite)]
public TimeSpan DelayToCheck = TimeSpan.FromSeconds(10f);

[DataField, ViewVariables(VVAccess.ReadWrite)]
public TimeSpan DelayToDelete = TimeSpan.FromSeconds(20f);

[DataField, ViewVariables(VVAccess.ReadWrite)]
public int DistanceToCheck = 5;
}

0 comments on commit 2c15704

Please sign in to comment.