mirror of
https://github.com/Dingo-Shenanigans/ReSkate.git
synced 2026-10-17 15:07:06 +02:00
Music: Spotify, YouTube Music and External Audio through the in-game player
Three outside sources can now be played through the game's own music
player. Each has its own row in the music screen, shown only when it is
set up, with tiles that behave like the game's playlists: track name,
cover, pause, next, and pressing a row to start that track.
How the sound gets in
- The game's song decoder is hooked. While one of these tiles is on, the
audio of the game song behind it (its "carrier") is replaced, block by
block, with the outside source's audio. The game's volume, fades and
pausing still apply.
- Rows are songs of our own registered with the game's music registry
(copies of a real song's asset with their own artist and title), so no
game song is borrowed or renamed to list a track.
Spotify
- The game is a Spotify Connect device ("ReSkate"), built on librespot
and linked into ReSkate.dll (SpotifyHelper/, Rust). Audio, track info
and controls come straight from Spotify. Needs Premium.
- Optional sign-in through the Web API lists the player's playlists and
Liked Songs as tiles with their tracks.
- librespot can no longer end the process (it does so on a free account
and on playback errors); only its thread is stopped.
YouTube Music
- Videos and playlists added by link. yt-dlp is fetched on request into
<Local AppData>\ReSkate\bin and checked against its published sums;
decoding is done in the DLL, so no ffmpeg.
- Private and age-restricted songs: cookies.txt or a browser's sign-in,
with QuickJS fetched as the JavaScript runtime yt-dlp then needs
(Node.js is used instead when installed).
External Audio
- Any app's sound, captured per process from Windows, with the app's own
output turned down while it plays through the game.
Setup page
- "spotify setup" opens http://127.0.0.1:8421/: device status, sign-ins,
YouTube links and tools, the external app, loudness. Loopback only;
changes are accepted from its own page only.
Also
- Speakers in the world play the tile's audio; grabbing one keeps the
player on their tile.
- Playlists added while the game runs are sent to the music screen live.
- MUSIC-SETUP.md: setup guide for players.
Building the Spotify device and the YouTube decoder needs cargo; without
it ReSkate.dll builds without them.
This commit is contained in:
1 parent
1c5da074cc
commit
48a9cb8f5b
48 files changed
+9031
-70
No files matched your search
@@ -9,6 +9,12 @@
|
||||
#include "Extension/World/load_error_guard.h"
|
||||
#include "Extension/World/mesh_unload_guard.h"
|
||||
#include "Extension/World/stack_check_report.h"
|
||||
#include "Extension/Music/music_inject.h"
|
||||
#include "Extension/Music/spotify_web.h"
|
||||
#include "Extension/Music/spotify_device.h"
|
||||
#include "Extension/Music/spotify_dashboard.h"
|
||||
#include "Extension/Music/youtube_music.h"
|
||||
#include "Extension/Music/spotify_rows.h"
|
||||
#include "Extension/World/texture_handle_limit.h"
|
||||
#include "Extension/Console/commands.h"
|
||||
#include "Extension/UI/ui_pointer_skip.h"
|
||||
@@ -323,6 +329,12 @@ extern "C" __declspec(dllexport) BOOL WINAPI DingoSDKDebugInitialize() {
|
||||
(void)dingosdk::load_error_guard::install(r.base);
|
||||
(void)dingosdk::texture_handle_limit::install(r.base);
|
||||
(void)dingosdk::stack_check_report::install(r.base);
|
||||
(void)dingosdk::music_inject::install(r.base);
|
||||
(void)dingosdk::spotify_rows::install(r.base);
|
||||
dingosdk::spotify_device::start(); // (the game as a device in the player's Spotify app)
|
||||
dingosdk::spotify_web::start();
|
||||
dingosdk::youtube_music::start(); // (the player's YouTube playlists, read before the music screen is built)
|
||||
dingosdk::spotify_dashboard::start(); // (the page in the browser that sets Spotify up) // (the player's playlists, fetched before the music screen is built)
|
||||
dingosdk::console::start_memory_trace_from_environment();
|
||||
const bool fixed_stop_provider = (global_offline_hook && progression_guard_armed) &&
|
||||
dingosdk::prepare_fixed_stop_entitlement_provider(r.base);
|
||||
|
||||
Reference in new issue
Block a user