Advertisement
BDFD_Berk

[3/5] !ticket-stats | Ticket System BDFD

Jan 3rd, 2023
447
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. $nomention
  2. $if[$isSlash==true] $defer $endif
  3. $onlyIf[$guildID!=;You can't use this in DMs!]
  4. $c[ Naturally everyone is able to use this command since it doesn't suppose any risk, but feel free to add an onlyAdmin, onlyPerms or anything you want below this line if you want to restrict it. ]
  5.  
  6. $textSplit[$getServerVar[tickets2;$guildID];--]
  7. $enableDecimals[yes]
  8. $if[$isNumber[$splitText[2]]==true]
  9. $var[a;$splitText[1]]
  10. $var[b;$splitText[2]]
  11. $var[c;$splitText[3]]
  12. $var[d;$splitText[4]]
  13. $var[e;$splitText[5]]
  14. $else
  15. $var[a;0] $var[b;0] $var[c;0] $var[d;0] $var[e;0]
  16. $endif
  17. $var[sum;$sum[$var[a];$var[b];$var[c];$var[d];$var[e]]]
  18. $try $var[p_verybad;$round[$multi[$divide[$var[a];$var[sum]];100]]] $catch $var[p_verybad;0] $endtry
  19. $try $var[p_bad;$round[$multi[$divide[$var[b];$var[sum]];100]]] $catch $var[p_bad;0] $endtry
  20. $try $var[p_regular;$round[$multi[$divide[$var[c];$var[sum]];100]]] $catch $var[p_regular;0] $endtry
  21. $try $var[p_good;$round[$multi[$divide[$var[d];$var[sum]];100]]] $catch $var[p_good;0] $endtry
  22. $try $var[p_verygood;$round[$multi[$divide[$var[e];$var[sum]];100]]] $catch $var[p_verygood;0] $endtry
  23.  
  24. $var[negative;:red_square:]
  25. $var[regular;:blue_square:]
  26. $var[positive;:green_square:]
  27. $var[white;:white_large_square:]
  28.  
  29. $try $var[pl_verybad;$round[$multi[$divide[$var[a];$var[sum]];10]]] $catch $var[pl_verybad;0] $endtry
  30. $try $var[pl_bad;$round[$multi[$divide[$var[b];$var[sum]];10]]] $catch $var[pl_bad;0] $endtry
  31. $try $var[pl_regular;$round[$multi[$divide[$var[c];$var[sum]];10]]] $catch $var[pl_regular;0] $endtry
  32. $try $var[pl_good;$round[$multi[$divide[$var[d];$var[sum]];10]]] $catch $var[pl_good;0] $endtry
  33. $try $var[pl_verygood;$round[$multi[$divide[$var[e];$var[sum]];10]]] $catch $var[pl_verygood;0] $endtry
  34.  
  35. $if[$sum[$var[a];$var[b]]>$sum[$var[d];$var[e]]]
  36. $color[#dd2e44]
  37. $else
  38. $color[#78b159]
  39. $endif
  40.  
  41. $author[$serverName[$guildID]]
  42. $authorIcon[$serverIcon[$guildID]]
  43. $description[
  44. > **$numberSeparator[$getServerVar[tickets]]** tickets has been created on this server!
  45. > **$numberSeparator[$sum[$var[a];$var[b];$var[c];$var[d];$var[e]]]** total reviews! **$numberSeparator[$sum[$var[c];$var[d];$var[e]]]** positives, **$numberSeparator[$sum[$var[a];$var[b]]]** negatives!
  46. $addField[Very bad — $numberSeparator[$var[a]];$repeatMessage[$var[pl_verybad];$var[negative]]$repeatMessage[$sub[10;$var[pl_verybad]];$var[white]] **$var[p_verybad]%**;no]
  47. $addField[Bad — $numberSeparator[$var[b]];$repeatMessage[$var[pl_bad];$var[negative]]$repeatMessage[$sub[10;$var[pl_bad]];$var[white]] **$var[p_bad]%**;no]
  48. $addField[Regular — $numberSeparator[$var[c]];$repeatMessage[$var[pl_regular];$var[regular]]$repeatMessage[$sub[10;$var[pl_regular]];$var[white]] **$var[p_regular]%**;no]
  49. $addField[Good — $numberSeparator[$var[d]];$repeatMessage[$var[pl_good];$var[positive]]$repeatMessage[$sub[10;$var[pl_good]];$var[white]] **$var[p_good]%**;no]
  50. $addField[Very good — $numberSeparator[$var[e]];$repeatMessage[$var[pl_verygood];$var[positive]]$repeatMessage[$sub[10;$var[pl_verygood]];$var[white]] **$var[p_verygood]%**;no]
  51. ]
  52. $footer[Req by $username[$authorID]#$discriminator[$authorID]]
  53. $suppressErrors
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement