Delete
CacheTable:Delete()
You can only delete a cache within the server.
A function that is used to completely clean and delete a cache. Perfect for player-spawned events. After a cache is deleted it can no longer be used and all of the events under the cache are disconnected or removed. (Binds, Remotes, and Player Leaving/Joining connections)
Delete Arguments:
No required Arguments
Example Usage:
local SwarmSpawnCache = Cache:Create("Forbrads swarm",
{Global = true},
{
Swarms = {game.ReplicatedStorage.NPCs.BadGuy:Clone(),game.ReplicatedStorage.NPCs.BadGuy:Clone()},
StartTime = 10,
}
)
task.wait(20)
SwarmSpawnCache:Delete()
Updated almost 2 years ago
Did this page help you?