Added 9 new statistics in the /stats command

Ticket volume, Average tickets/user, System uptime, Current tickets, Ticket age, Message/Embed/File/Component amount.
This commit is contained in:
DJj123dj
2025-08-28 11:20:02 +02:00
parent 82f2aeaa90
commit 706006e319
5 changed files with 226 additions and 41 deletions
+5 -2
View File
@@ -412,14 +412,17 @@ const statsEmbeds = () => {
const scope = opendiscord.stats.get("opendiscord:ticket")
const participantsScope = opendiscord.stats.get("opendiscord:participants")
if (!scope || !participantsScope) return
const messagesScope = opendiscord.stats.get("opendiscord:messages")
if (!scope || !participantsScope || !messagesScope) return
const data = await scope.render(scopeData.id.value,guild,channel,user)
const participantsData = await participantsScope.render(scopeData.id.value,guild,channel,user)
const messagesData = await messagesScope.render(scopeData.id.value,guild,channel,user)
instance.setColor(generalConfig.data.mainColor)
instance.setTitle(scope.name)
instance.setDescription(data)
instance.addFields({name:participantsScope.name,value:participantsData,inline:false})
instance.addFields({name:participantsScope.name,value:participantsData,inline:true})
instance.addFields({name:messagesScope.name,value:messagesData,inline:true})
})
)