forked from CFC-Servers/cfc_chat_transit
Logging
This commit is contained in:
parent
5b46cb7879
commit
1a55d31ad5
@ -8,15 +8,20 @@ AvatarServiceAddress = string.Replace AvatarServiceAddress, "\n", ""
|
||||
class AvatarService
|
||||
new: (logger) =>
|
||||
@Logger = logger
|
||||
@outlinerUrl = "http://#{AvatarServiceAddress}/outline"
|
||||
|
||||
processAvatar: (avatarUrl, outlineColor, success, failed) =>
|
||||
body = TableToJSON { :avatarUrl, :outlineColor }
|
||||
|
||||
@Logger\debug "Sending data to outliner: ", body
|
||||
|
||||
HTTP
|
||||
:success
|
||||
:failed
|
||||
url: "http://#{AvatarServiceAddress}/outline"
|
||||
:body
|
||||
url: @outlinerUrl
|
||||
method: "POST"
|
||||
type: "application/json"
|
||||
body: TableToJSON { :avatarUrl, :outlineColor }
|
||||
|
||||
setOutlinedAvatar: (ply, avatarUrl) =>
|
||||
data = ply.response.players[1]
|
||||
|
Loading…
Reference in New Issue
Block a user