cache.invalidate — drop an instance from the executor's instance cache
cache-invalidateClear a Roblox Instance from the executor's cache so the next lookup returns a fresh reference, allowing de-synced edits to go unnoticed.
Instructions
Invalidate the executor's cached reference to a single Instance via cache.invalidate(inst). After invalidation the next time the game indexes that instance it receives a FRESH reference rather than the cached one — the classic technique for de-syncing a server-trusted object so your subsequent edits to the cached copy go unnoticed, or for forcing the executor to re-wrap a part you have been tampering with. The target is resolved from a Luau path/expression via loadstring('return ' .. expr). Requires the cache library (type(cache)=='table') with cache.invalidate — both are type-guarded and the call is pcall-wrapped, returning { error } when missing or on failure. Mutates live executor state. Returns { ok } or { error }. Signature: { instancePath: string, threadContext: number?, timeoutMs: number? }. Phase: act; cost=medium; idempotency=contextual-write. Requires: active-client, resolved-target, explicit-mutation-approval. Produces: structured-result. Verify with: assert-state. Safety: MUTATING; writes live game/client state. On failure: inspect tool-schema for exact fields, defaults, constraints, and an invocation example.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| timeoutMs | No | Optional per-call deadline in milliseconds; omit it to use the tool or server default. | |
| instancePath | Yes | Luau path/expression resolving to the Instance to invalidate, e.g. 'game.Workspace.Boss' or 'game.Players.LocalPlayer.Character.HumanoidRootPart'. Evaluated as `return <expression>`. | |
| threadContext | No | Optional Roblox thread identity for this call; omit it to use the server default. |