Skip to content

monogutsy/AutoClearItems

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 

Repository files navigation

AutoClearItems

.NET TShock Terraria API License

A TShock plugin that automatically removes old dropped items from the ground at configurable intervals. Helps reduce world clutter and maintain server performance while protecting recently dropped loot from being removed too soon.

Features

  • Automatic item cleanup on a repeating timer
  • Configurable cleanup interval
  • Countdown warnings before each cleanup cycle
    • 1 minute warning
    • 30 second warning
    • 10 second warning
    • Final countdown (5, 4, 3, 2, 1)
  • Protection for newly dropped items (configurable minimum age)
  • Automatic configuration file generation
  • Lightweight and efficient
  • No commands required
  • No permissions required

Installation

  1. Download AutoClearItems.zip from Releases.
  2. Extract the archive.
  3. Place AutoClearItems.dll inside your server's ServerPlugins folder.
  4. Restart the server.
  5. AutoClearItems.json will be generated automatically in the tshock folder.

Configuration

The configuration file is located at:

tshock/AutoClearItems.json

Default Configuration

{
  "CleanupIntervalMinutes": 5,
  "MinimumItemAgeSeconds": 180,
  "EnableOneMinuteWarning": true,
  "EnableThirtySecondWarning": true,
  "EnableTenSecondWarning": true,
  "EnableFinalCountdown": true,
  "BroadcastMessages": true,
  "ShowRemovedItemCount": true,
  "LogCleanupOperations": true
}

Configuration Options

Option Type Default Description
CleanupIntervalMinutes int 5 How often cleanup runs, in minutes.
MinimumItemAgeSeconds int 180 How old an item must be before it can be removed.
EnableOneMinuteWarning bool true Show a warning at 60 seconds remaining.
EnableThirtySecondWarning bool true Show a warning at 30 seconds remaining.
EnableTenSecondWarning bool true Show a warning at 10 seconds remaining.
EnableFinalCountdown bool true Show a 5-4-3-2-1 countdown before cleanup.
BroadcastMessages bool true Send cleanup messages to players.
ShowRemovedItemCount bool true Display how many items were removed.
LogCleanupOperations bool true Log cleanup activity to the server console.

Building From Source

dotnet build

Requires the TShock NuGet package (6.1.0).

Compatibility

Dependency Version
Terraria 1.4.5.6
TShock 6.1.0
.NET 9.0
TSAPI 2.1

License

This project is licensed under the MIT License.

About

A TShock plugin that automatically clears old items dropped on the ground every few minutes. It helps keep your world clean, reduces clutter, and prevents lag while protecting newly dropped loot from being removed too soon. Fully configurable through a JSON file and works automatically

Topics

Resources

License

Stars

Watchers

Forks

Packages

 
 
 

Contributors

Languages