Closed Lastorder-DC closed 2 years ago
Did a try but it doesnt seem to work for me.
@iamisti It's still WIP. emotesets=
should be replaced together(from emotesets=0,1,2,3
to emote_set_id=0&emote_set_id=1&emote_set_id=2&emote_set_id=3
)
I'm currently looking for better way to build such query. If have any idea feel free to share here.
@iamisti It should be working now (unless api contents are also changed - in that case further update will be needed)
The emote data in the Helix API is very different. Please look at the API response and compare with how it's used in tmi.js. The data would need to be transformed to the old format to be compatible with previous versions of the library.
The old endpoint https://api.twitch.tv/kraken/chat/emoticon_images?emotesets=0,1,...
looked like this:
{
"emoticon_sets": {
"0": [
{ "code": "JKanStyle", "id": 15 },
{ "code": "Kappa", "id": 25 }
],
"1": [ { "code": "...", "id": 0 } ]
}
}
(Old reference cache)
Leave the id value as a string. The Helix data is at data
instead of Kraken's emoticon_sets
which you didn't update. Please validate the code is actually working as intended.
I would personally prefer to not make any API requests (apart from maybe OAuth), remove api.js
because it's a mess, and remove the node-fetch dependency. This library only needs to connect to the chat sockets.
https://discuss.dev.twitch.tv/t/legacy-twitch-api-v5-i-e-kraken-shutdown-reminder-february-28-2022/36589
Since Twitch API v5 no longer works(and only api tmijs uses are emote set api) I replaced with new twitch api.
Still very WIP (emote list is not set yet)