app.rb 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. def new_app_embed(user_name, color)
  2. desc = "Hi, #{user_name},\nI see you'd like to start a new character" +
  3. " application!\nI'll send you instructions in a dm!"
  4. Embed.new(
  5. title: "New Application!",
  6. description: desc,
  7. color: color
  8. )
  9. end
  10. def new_app_dm(user_name, color, code)
  11. Embed.new(
  12. title: "Hi, #{user_name}",
  13. description: "If you have any questions, feel free to ask a Guildmaster!",
  14. color: color,
  15. footer: {
  16. text: "If you cannot copy your key, press the #{Emoji::PHONE}"
  17. },
  18. fields: [
  19. { name: "Please start your application here:", value: Url::CHAR },
  20. { name: "Your key is:", value: code }
  21. ]
  22. )
  23. end
  24. def edit_app_embed(user_name, char_name, color)
  25. Embed.new(
  26. title: "You want to edit #{char_name}?",
  27. description: "Good news, #{user_name}! I'll dm you a link",
  28. color: color
  29. )
  30. end
  31. def edit_app_dm(char_name, edit_url, color)
  32. Embed.new(
  33. title: "You may edit #{char_name} here:",
  34. description: edit_url,
  35. color: color
  36. )
  37. end
  38. def app_not_found_embed(user_name, char_name)
  39. Embed.new(
  40. title: "I'm sorry, #{user_name}",
  41. description: "I can't seem to find your character named, #{char_name}",
  42. color: Color::ERROR,
  43. fields: [
  44. {
  45. name: "Want to start a new application?",
  46. value: "You can start one with this command:\n```pkmn-app```"
  47. }
  48. ]
  49. )
  50. end