diff options
| author | sD <stoned@derpymail.org> | 2020-08-11 19:52:48 +0200 |
|---|---|---|
| committer | sD <stoned@derpymail.org> | 2020-08-11 19:52:48 +0200 |
| commit | 5ab213af6caa0ef3e3d2b9143f00bad95510e03e (patch) | |
| tree | 50f6efbf34eaeeeb012b58abbaef6dde8ecc60d4 /webAO/client.js | |
| parent | a85a728176156342409d6283d6630e3d6075ec56 (diff) | |
apply the effects
Diffstat (limited to 'webAO/client.js')
| -rw-r--r-- | webAO/client.js | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/webAO/client.js b/webAO/client.js index 82427a5..0cefa5c 100644 --- a/webAO/client.js +++ b/webAO/client.js @@ -1787,8 +1787,13 @@ async changeBackground(position) { } // apply effects + const effectinfo = this.chatmsg.effects.split('|'); fg.style.animation = ""; - fg.src = transparentPNG; + + if (effectinfo[0]) + fg.src = `${AO_HOST}themes/default/effects/${encodeURI(effectinfo[0].toLowerCase())}.webp`; + else + fg.src = transparentPNG; this.tick(); } |
