discord.set_timestamps

Client

Sets the elapsed or remaining time shown on the Discord rich presence activity


Syntax

local status = discord.set_timestamps(
    start_at,
    end_at = 0
)

Parameters

TypeNameDescription
intstart_atOffset in seconds from now to start the timer
intend_atOffset in seconds from now to end the timer

Returns

TypeNameDescription
boolstatustrue on successful execution, or false on failure

Examples

Set various timestamps on a rich presence activity
-- Start elapsed timer from now
discord.set_timestamps(0)

-- Start timer with a 5 minute countdown
discord.set_timestamps(0, 300)

On this page