Advertisement
DefeatedPurpose

[IY] Plugin Library Test

Apr 17th, 2020
334
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Lua 1.58 KB | None | 0 0
  1. --  _____  _____   ____ _______ ____ _________     _______  ______
  2. -- |  __ \|  __ \ / __ \__   __/ __ \__   __\ \   / /  __ \|  ____|
  3. -- | |__) | |__) | |  | | | | | |  | | | |   \ \_/ /| |__) | |__  
  4. -- |  ___/|  _  /| |  | | | | | |  | | | |    \   / |  ___/|  __|  
  5. -- | |    | | \ \| |__| | | | | |__| | | |     | |  | |    | |____
  6. -- |_|    |_|  \_\\____/  |_|  \____/  |_|     |_|  |_|    |______|
  7.  
  8. -- \\Tohru\\PneumaOffical\\Luminous
  9.  
  10. Library = loadstring(game:HttpGet("https://pastebin.com/raw/xAF8tVui", true))()
  11. prefix = ';'
  12. function has(sample, text)
  13.   sample = sample or "Sample Text"
  14.   text = text or "Sample"
  15.   if (string.match(sample, text) and true or false) then
  16.     return true
  17.   else
  18.     return false
  19.   end
  20. end
  21. function cmdcheck(input, cmd, checktype)
  22.   if checktype == "multiple" or checktype == "m" then
  23.     if has(input:lower(), prefix..""..cmd.." ") and input:sub(1,1) == prefix and input:sub(2, (cmd):len() + 1) == cmd then
  24.       return true
  25.     else
  26.       return false
  27.     end
  28.     elseif checktype == "single" or checktype == "s" then
  29.     if input == prefix..""..cmd then
  30.       return true else return false
  31.     end
  32.   end
  33. end
  34. function getstring(input, cmd)
  35.   return input:sub(prefix:len() + cmd:len() + 2 )
  36. end
  37. game:GetService("Players").LocalPlayer.Chatted:Connect(function(msg)
  38.   if cmdcheck(msg, "download", "m") then
  39.     msg = getstring(msg, "download")
  40.     Library["Functions"].AddPlugin(msg)
  41.   end
  42.   if cmdcheck(msg, "list", "s") then
  43.     Library["Functions"].ListPlugins()
  44.   end
  45. end)
  46. Library["Functions"].Notify("Plugin Library loaded!")
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement