warn2

Privateunrated

Content

86 lines
{=(COMMENT): list of mod role ids separated by comma, only roles in this list can use the command}
{=(modroles):696051487201296562,696051487201296561}

{=(COMMENT): replace the id below with the id of your warn log channel, it is suggested this chat be public but it does not have to be}
{=(warnchannel):816543621997133844}

{=(COMMENT): replace the image below with the link to the icon you want to be displayed or delete the link and leave it blank, image links can be obtained by uploading to imgur and selecting the "copy BBCode" option under get sharable links then deleting the two [img]}
{=(thumbnailurl):https://i.imgur.com/SFKTfcL.png}

{=(COMMENT): list of warning role ids and cooldowns for each their warn, Replace the role ids with the ids of your warn roles, you can also change the cooldown of each warn which is how long it will last until the role is removed}
{=(role1):816489131487133707}
{=(cooldown1):1w}
{=(role2):816562772875018291}
{=(cooldown2):1w}
{=(role3):816562947764912169}
{=(cooldown3):1w}
{=(role4):816587654413942826}
{=(cooldown4):2w}
{=(role5):816587756767674389}
{=(cooldown5):3w}

{=(COMMENT): IT IS NOT RECOMMENDED TO EDIT ANYTHING BELOW UNLESS YOU KNOW WHAT YOUR DOING}

{=(COMMENT): list of messages that the command can output for warns or errors}
{=(msg.warn1):{target(mention)} has received their **1st Warning** for **{cooldown1}** (weeks).
**Moderator:**{user(mention)}
**Reason:** {args(2+)}}
{=(msg.warn2):{target(mention)} has received their **2nd Warning** for **{cooldown2}** (weeks).
**Moderator:**{user(mention)}
**Reason:** {args(2+)}}
{=(msg.warn3):{target(mention)} has received their **3rd Warning** for **{cooldown3}** (weeks).
**Moderator:**{user(mention)}
**Reason:** {args(2+)}}
{=(msg.warn4):{target(mention)} has received their **4th Warning** for **{cooldown4}** (weeks).
**Moderator:**{user(mention)}
**Reason:** {args(2+)}}
{=(msg.warn5):{target(mention)} has received their **5th Warning** for **{cooldown5}** (weeks).
**Moderator:**{user(mention)}
**Reason:** {args(2+)}}
{=(msg.nomention): {user(mention)}You cannot warn yourself silly!
**Usage:**?warn <@user> <reason>}
{=(msg.maxwarn):{target(mention)} has reached the maximum number of warns allowed! 
**Moderation action is advised**.}
{=(msg.noreason): A reason for the warn must be given for the command to work!
**Usage:**?warn <@user> <reason>}

{=(COMMENT): checklist to determine which warn or error should be given(defines variables)}
{=(isUserTarget):{if({user(id)}=={target(id)}):true|false}}
{=(isReasonPresent):{if({args(2+)}==):false|true}}
{=(iswarn1):{contains({role1}):{target(roleids)}}}
{=(warn1):{all({isUserTarget}==false|{iswarn1}==false|{isReasonPresent}==true):true|false}}
{=(iswarn2):{contains({role2}):{target(roleids)}}}
{=(warn2):{all({isUserTarget}==false|{iswarn1}==true|{iswarn2}==false|{isReasonPresent}==true):true|false}}
{=(iswarn3):{contains({role3}):{target(roleids)}}}
{=(warn3):{all({isUserTarget}==false|{iswarn2}==true|{iswarn3}==false|{isReasonPresent}==true):true|false}}
{=(iswarn4):{contains({role4}):{target(roleids)}}}
{=(warn4):{all({isUserTarget}==false|{iswarn3}==true|{iswarn4}==false|{isReasonPresent}==true):true|false}}
{=(iswarn5):{contains({role5}):{target(roleids)}}}
{=(warn5):{all({isUserTarget}==false|{iswarn4}==true|{iswarn5}==false|{isReasonPresent}==true):true|false}}
{=(fail):{any({isUserTarget==true|{isReasonPresent}==false):true|false}}}

{=(COMMENT): executes commands to give warning role, feel free to add more commands here if your server has premium enabled or change commands to, for instance, temp ban a user on the 5th warn}
{=():}
{{if({warn1}==true):c:temprole {target(id)} {role1} {cooldown1}}}
{{if({warn2}==true):c:temprole {target(id)} {role2} {cooldown2}}}
{{if({warn3}==true):c:temprole {target(id)} {role3} {cooldown3}}}
{{if({warn4}==true):c:temprole {target(id)} {role4} {cooldown4}}}
{{if({warn5}==true):c:temprole {target(id)} {role5} {cooldown5}}}

{=(COMMENT): Decides if the command was successful and will redirect it to the warn channel if it was}
{=():}
{{if({fail}==true):|redirect:{warnchannel}}}

{=(COMMENT):Displays the warn or error message}
{=(embed.title):Warning}
{=(embed.description):{if({isUserTarget}==true):{msg.nomention}|{if({isReasonPresent}==false):{msg.noreason}|{if({warn1}==true):{msg.warn1}|{if({warn2}==true):{msg.warn2}|{if({warn3}==true):{msg.warn3}|{if({warn4}==true):{msg.warn4}|{if({warn5}==true):{msg.warn5}|{if({iswarn5}==true):{msg.maxwarn}}}}}}}}}}
{=(embed.footer):}
{embed(color):{if({isUserTarget}==true):#2364CC|{if({isReasonPresent}==false):#2364CC|{if({iswarn5}==true):#2C0C03|{if({warn5}==true):#B825FF|{if({warn4}==true):#F5065C|{if({warn3}==true):#900817|{if({warn2}==true):#E75129|{if({warn1}==true):#D4D422}}}}}}}}}
{embed(timestamp):now}

{=(COMMENT): Additional outputs and action/limit blocks}
{and({iswarn5}==true|{isReasonPresent}==true):{user(mention)}}
{if({isReasonPresent}==true):{target(mention)}}
{if({isReasonPresent}==false):{user(mention)} Critical error, warn was not given!}
{require(you do not have the required permissions!):{modroles}}
{silent}

Embed

1 line
{"color": 5198940, "author": {"name": "{embed.title}", "icon_url": "{thumbnailurl}"}, "footer": {"text": "{embed.footer}"}, "description": "{embed.description}"}
Raw JSON
{
  "id": 649013,
  "created_at": "2021-03-03T10:53:51.000Z",
  "tag_name": "warn2",
  "nsfw": false,
  "owner_id": "420710779688321035",
  "uses": 25,
  "description": null,
  "restricted": false,
  "shared": false,
  "deleted": false,
  "safe": "unrated",
  "hidden": false,
  "guild_id": "696051487134056598",
  "sharer": "420710779688321035",
  "content": "{=(COMMENT): list of mod role ids separated by comma, only roles in this list can use the command}\n{=(modroles):696051487201296562,696051487201296561}\n\n{=(COMMENT): replace the id below with the id of your warn log channel, it is suggested this chat be public but it does not have to be}\n{=(warnchannel):816543621997133844}\n\n{=(COMMENT): replace the image below with the link to the icon you want to be displayed or delete the link and leave it blank, image links can be obtained by uploading to imgur and selecting the \"copy BBCode\" option under get sharable links then deleting the two [img]}\n{=(thumbnailurl):https://i.imgur.com/SFKTfcL.png}\n\n{=(COMMENT): list of warning role ids and cooldowns for each their warn, Replace the role ids with the ids of your warn roles, you can also change the cooldown of each warn which is how long it will last until the role is removed}\n{=(role1):816489131487133707}\n{=(cooldown1):1w}\n{=(role2):816562772875018291}\n{=(cooldown2):1w}\n{=(role3):816562947764912169}\n{=(cooldown3):1w}\n{=(role4):816587654413942826}\n{=(cooldown4):2w}\n{=(role5):816587756767674389}\n{=(cooldown5):3w}\n\n{=(COMMENT): IT IS NOT RECOMMENDED TO EDIT ANYTHING BELOW UNLESS YOU KNOW WHAT YOUR DOING}\n\n{=(COMMENT): list of messages that the command can output for warns or errors}\n{=(msg.warn1):{target(mention)} has received their **1st Warning** for **{cooldown1}** (weeks).\n**Moderator:**{user(mention)}\n**Reason:** {args(2+)}}\n{=(msg.warn2):{target(mention)} has received their **2nd Warning** for **{cooldown2}** (weeks).\n**Moderator:**{user(mention)}\n**Reason:** {args(2+)}}\n{=(msg.warn3):{target(mention)} has received their **3rd Warning** for **{cooldown3}** (weeks).\n**Moderator:**{user(mention)}\n**Reason:** {args(2+)}}\n{=(msg.warn4):{target(mention)} has received their **4th Warning** for **{cooldown4}** (weeks).\n**Moderator:**{user(mention)}\n**Reason:** {args(2+)}}\n{=(msg.warn5):{target(mention)} has received their **5th Warning** for **{cooldown5}** (weeks).\n**Moderator:**{user(mention)}\n**Reason:** {args(2+)}}\n{=(msg.nomention): {user(mention)}You cannot warn yourself silly!\n**Usage:**?warn <@user> <reason>}\n{=(msg.maxwarn):{target(mention)} has reached the maximum number of warns allowed! \n**Moderation action is advised**.}\n{=(msg.noreason): A reason for the warn must be given for the command to work!\n**Usage:**?warn <@user> <reason>}\n\n{=(COMMENT): checklist to determine which warn or error should be given(defines variables)}\n{=(isUserTarget):{if({user(id)}=={target(id)}):true|false}}\n{=(isReasonPresent):{if({args(2+)}==):false|true}}\n{=(iswarn1):{contains({role1}):{target(roleids)}}}\n{=(warn1):{all({isUserTarget}==false|{iswarn1}==false|{isReasonPresent}==true):true|false}}\n{=(iswarn2):{contains({role2}):{target(roleids)}}}\n{=(warn2):{all({isUserTarget}==false|{iswarn1}==true|{iswarn2}==false|{isReasonPresent}==true):true|false}}\n{=(iswarn3):{contains({role3}):{target(roleids)}}}\n{=(warn3):{all({isUserTarget}==false|{iswarn2}==true|{iswarn3}==false|{isReasonPresent}==true):true|false}}\n{=(iswarn4):{contains({role4}):{target(roleids)}}}\n{=(warn4):{all({isUserTarget}==false|{iswarn3}==true|{iswarn4}==false|{isReasonPresent}==true):true|false}}\n{=(iswarn5):{contains({role5}):{target(roleids)}}}\n{=(warn5):{all({isUserTarget}==false|{iswarn4}==true|{iswarn5}==false|{isReasonPresent}==true):true|false}}\n{=(fail):{any({isUserTarget==true|{isReasonPresent}==false):true|false}}}\n\n{=(COMMENT): executes commands to give warning role, feel free to add more commands here if your server has premium enabled or change commands to, for instance, temp ban a user on the 5th warn}\n{=():}\n{{if({warn1}==true):c:temprole {target(id)} {role1} {cooldown1}}}\n{{if({warn2}==true):c:temprole {target(id)} {role2} {cooldown2}}}\n{{if({warn3}==true):c:temprole {target(id)} {role3} {cooldown3}}}\n{{if({warn4}==true):c:temprole {target(id)} {role4} {cooldown4}}}\n{{if({warn5}==true):c:temprole {target(id)} {role5} {cooldown5}}}\n\n{=(COMMENT): Decides if the command was successful and will redirect it to the warn channel if it was}\n{=():}\n{{if({fail}==true):|redirect:{warnchannel}}}\n\n{=(COMMENT):Displays the warn or error message}\n{=(embed.title):Warning}\n{=(embed.description):{if({isUserTarget}==true):{msg.nomention}|{if({isReasonPresent}==false):{msg.noreason}|{if({warn1}==true):{msg.warn1}|{if({warn2}==true):{msg.warn2}|{if({warn3}==true):{msg.warn3}|{if({warn4}==true):{msg.warn4}|{if({warn5}==true):{msg.warn5}|{if({iswarn5}==true):{msg.maxwarn}}}}}}}}}}\n{=(embed.footer):}\n{embed(color):{if({isUserTarget}==true):#2364CC|{if({isReasonPresent}==false):#2364CC|{if({iswarn5}==true):#2C0C03|{if({warn5}==true):#B825FF|{if({warn4}==true):#F5065C|{if({warn3}==true):#900817|{if({warn2}==true):#E75129|{if({warn1}==true):#D4D422}}}}}}}}}\n{embed(timestamp):now}\n\n{=(COMMENT): Additional outputs and action/limit blocks}\n{and({iswarn5}==true|{isReasonPresent}==true):{user(mention)}}\n{if({isReasonPresent}==true):{target(mention)}}\n{if({isReasonPresent}==false):{user(mention)} Critical error, warn was not given!}\n{require(you do not have the required permissions!):{modroles}}\n{silent}",
  "embed": "{\"color\": 5198940, \"author\": {\"name\": \"{embed.title}\", \"icon_url\": \"{thumbnailurl}\"}, \"footer\": {\"text\": \"{embed.footer}\"}, \"description\": \"{embed.description}\"}",
  "last_fetched": "2026-10-21T00:32:40.538Z"
}