Updated setUsername and setAvatar

This commit is contained in:
Violet Millie 2020-11-01 18:40:36 +00:00
parent 4a6d82ceeb
commit 37e04cc54a
1 changed files with 8 additions and 8 deletions

View File

@ -20,22 +20,22 @@ function RoHook.new(url, username, avatar)
return self return self
end end
function RoHook:setUsername() function RoHook:setUsername(username)
-- self.username = username
end end
function RoHook:setAvatar(url) function RoHook:setAvatar(url)
self.avatarUrl = url
end end
function RoHook:send(data) function RoHook:send(data)
local request = nil local request = {
username = self.username,
if data.ClassName == "RichEmbed" then avatar_url = self.avatarUrl
request = {
embeds = {data},
} }
print("Sending RichEmbed") if data.ClassName == "RichEmbed" then
request.embeds = {data}
elseif data.ClassName == "Message" then elseif data.ClassName == "Message" then
print("Sending Message") print("Sending Message")