Tamper → Configuration

Configuration

Call Tamper.Configure once at startup to control how the module handles strikes and kicks. If you never call it, the defaults apply.

Signature

Tamper.Configure(options: \{threshold: number?, autokick: boolean?, onKick: function?})

Options

OptionDefaultDescription
threshold3Number of strikes before the autokick or onKick callback fires.
autokicktrueWhen true and no onKick is provided, Tamper calls player:Kick() automatically at the threshold.
onKicknilOptional callback (player, strikes, reason) called instead of the default kick. Use this to log, ban, or apply custom enforcement.

Example

local Tamper = RoExpress.Tamper

Tamper.Configure({
    threshold = 5,
    autokick  = false,
    onKick    = function(player, strikes, reason)
        warn("[Tamper]", player.Name, "reached", strikes, "strikes. Reason:", reason)
        player:Kick("Exploit detected — you have been removed.")
    end,
})

Passive detection

Tamper watches the request pipeline automatically. A malformed packet — missing required fields, wrong types, or an invalid method string — issues an automatic strike and logs the reason. You do not need to configure anything to enable this; it runs as long as Tamper is loaded.

Version mismatches are handled separately and do not go through the strike system. A mismatched version token results in a silent drop with no strike. See Version Checking.

See also

← Tamper  ·  Strikes | issue and query strikes manually  ·  Version Checking | silent drop on version mismatch