Tutorials_for_BDFD

Vorschlagssystem V2

Oct 3rd, 2022
121
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 2.29 KB | None | 0 0
  1. ------------
  2. Variable: suggchannel
  3. Value : 0
  4. -------------
  5. Code 1 : suggest
  6. -------------
  7.  
  8. $nomention
  9. $sendMessage[🟢 | **vorschlagen**, *Vorschläge erfolgreich gesendet!*]
  10.  
  11. $if[$getServerVar[suggchannel]!=]
  12.  
  13. $useChannel[$getServerVar[suggchannel]]
  14. $color[00ff00]
  15. $title[Vorschlag von $username]
  16. $description[
  17. **Vorschlag:**
  18. ```
  19. $message[1;msg]
  20. ```
  21. **Reagiere:**
  22. 🟢 Ja/dafür
  23. 🟠 Vieleicht/wieso auch nicht
  24. 🔴 Nein/dagegen]
  25. $addReactions[🟢;🟠;🔴]
  26. $addButton[yes;answer;Antworten;primary;no;;]
  27. $addButton[no;thread;Thread erstell;secondary;no;;]
  28. $else
  29. $ephemeral
  30. $description[🔴 | **Fehler**, *Auf dem Server ist kein Vorschlagskanal definiert*]
  31. $color[00ff00]
  32. $endif
  33.  
  34. -----------
  35.  
  36. Code 2 : $onInteraction[theard]
  37. ------------
  38. $nomention
  39. $title[$getEmbedData[$channelID;$messageID;1;title]]
  40. $description[$getEmbedData[$channelID;$messageID;1;description]]
  41. $var[id;$startThread[Suggestion Comments;$channelID;$messageID;10080;yes]]
  42. $removeComponent[$customID]
  43.  
  44. --------------
  45.  
  46. Code 3 : $onInteraction[answer]
  47. --------------
  48.  
  49. $nomention
  50.  
  51. $if[$isAdmin[$authorID]]
  52. $newModal[ansed@$messageID;Title]
  53. $addTextInput[ans;paragraph;Antwort hier;1;2000;yes;;]
  54. $else
  55. $ephemeral
  56. $color[00ffff]
  57. $description[🔴 | **Fehler**, *Sie haben keine Administratorrechte !*]
  58. $removeButtons
  59. $endif
  60. -----------------
  61.  
  62. Code 4 : setchannel
  63. -------------
  64. $nomention
  65. $deletecommand
  66. $if[$and[$isAdmin[$authorID]==true;$mentionedChannels[1]==]==true]
  67. $description[🔴 |**Fehler**, *kein Kanal angegeben.*]
  68. $color[2F3136]
  69. $elseif[$and[$isAdmin[$authorID]==true;$mentionedChannels[1]!=]==true]
  70. $description[*🟢 |Vorschläge werden in gepostet <#$mentionedChannels[1]> !*]
  71. $color[2F3136]
  72. $setServerVar[suggchannel;$mentionedChannels[1]]
  73. $endif
  74. $if[$isAdmin[$authorID]==false]
  75. $color[2F3136]
  76. $ephemeral
  77. $description[🔴 | **Fehler**, *Sie haben keine Administratorrechte!*]
  78. $endif
  79.  
  80. ----------------
  81.  
  82. Code 5 : $onInteraction
  83. --------------
  84.  
  85. $onlyIf[$checkContains[$customID;ansed]==true;]
  86. $textSplit[$customID;@]
  87.  
  88. $editMessage[$channelID;$splitText[2];;$getEmbedData[$channelID;$splitText[2];1;title];$getEmbedData[$channelID;$splitText[2];1;description]
  89.  
  90. **Antwort von $username**
  91. $input[ans];ff8888;]
  92. $editButton[answer;Answered;primary;yes;;$splitText[2]]
Advertisement
Add Comment
Please, Sign In to add comment