Skip to main content

ghostPing

A great system to see who ghost pinged

Implementation​

simplydjs.ghostPing(message, {
// options (Optional)
})
INFO

This should be implemented in the messageDelete event and requires Message Intent!

client.on('messageDelete', (message) => {
simplydjs.ghostPing(message) // ghostPing function
})

Output​

ghost ping

Types​

simplydjs.ghostPing(
message: Message,
options: ghostOptions
): Promise<User>

Options​

ghostOptions​

ParameterTypeRequiredDefaultDescription
strictboolean❌falseEnables strict mode in ghostPing
embedCustomizableEmbed❌default embedPass a CustomizableEmbed Object to customize the ghost ping embed
export type ghostOptions = {
strict: boolean;
embed?: CustomizableEmbed;
};

Example​

  • Default settings​

messageDelete.js
const simplydjs = require('simply-djs')

simplydjs.ghostPing(message)
  • Customized with options​

messageDelete.js
const simplydjs = require('simply-djs')

simplydjs.ghostPing(message, {
strict: true,
embed: {
title: "Ghost Ping alert !",
color: simplydjs.toRgb("#406dbc")
}
})