置顶公告:【置顶】关于临时开启评论区所有功能的公告(2022.10.22) | 【置顶】关于本站Widget恢复使用的公告
  • 你好~!欢迎来到萌娘百科镜像站!如需查看或编辑,请联系本站管理员注册账号。
  • 本镜像站和其他萌娘百科的镜像站无关,请注意分别。

Module:Sandbox/Leranjun/signature

贴贴♀百科,万娘皆可贴的百科全书!转载请标注来源页面的网页链接,并声明引自贴贴百科。内容不可商用。
跳到导航 跳到搜索
Template-info.svg 模块文档  [创建] [刷新]
  1. local p = {}
  2. local function notempty(s)
  3. return (s and s ~= "")
  4. end
  5. function p.main(frame)
  6. if (notempty(frame.args.link)) then
  7. return "[[" ..
  8. frame.args.link .. '|' .. (notempty(frame.args.text) and frame.args.text or frame.args.link) .. "]]"
  9. end
  10. local items = {
  11. {
  12. "田中姬铃木雏",
  13. "酒姬民",
  14. },
  15. {
  16. "虚拟UP主/梗#单推",
  17. "单推人",
  18. },
  19. {
  20. "工具人",
  21. },
  22. {
  23. "OIer",
  24. },
  25. -- {
  26. -- "MGP:优质编辑者",
  27. -- "优质编辑者",
  28. -- },
  29. -- {
  30. -- "MGP:巡查姬",
  31. -- "巡查姬",
  32. -- },
  33. {
  34. "MGP:管理员",
  35. "管理员",
  36. },
  37. {
  38. "enmoe:",
  39. "EnMGP编辑者",
  40. },
  41. {
  42. "MGP:萌娘百科月报/月饼",
  43. "月饼主编",
  44. }
  45. }
  46. math.randomseed(math.floor(os.time() / 60))
  47. local rand = math.random(1, #items)
  48. return "[[" .. items[rand][1] .. '|' .. (items[rand][2] or items[rand][1]) .. "]]"
  49. end
  50. function p.randdeg(frame)
  51. math.randomseed(math.floor(os.time() / 60))
  52. return (math.random(360) + (tonumber(frame.args.offset) or 0) + 360) % 360
  53. end
  54. return p