Switch SkyBlock profiles in place - #880
Merged
Merged
Conversation
Server side redis handlers always published their response back to the proxy channel, so a request issued by another game server was answered into the void. The response now goes to the envelope origin, which is still the proxy for proxy issued requests and is the requesting server otherwise.
An island stayed in the loaded map forever once it had been created, so the proxy kept routing everyone who owned it back to a server that no longer hosted it. The vacancy check now drops the entry along with the instance, and a reload re-claims it. The vacancy check also refused to look at islands that were still being created, where the instance exists but the minion and jerry data has not been read yet. Running the save steps at that point threw and left the island half loaded.
Callers outside the module need to run a save, unload and reload of a single domain without interleaving with the disconnect save or the autosave. They can now ask for the registered domain by key and run the work under the same per uuid striped lock, with queued datapoint writes drained first.
Selecting another profile persisted the selection and then asked the proxy to transfer the player to a SkyBlock island server. The proxy resolved that to the server the player was already on, velocity answered with its already connected message and nothing happened, leaving the account pointing at a profile the session had not loaded. The switcher now saves the current profile through the domain save path, tears down the live state that belongs to it, unloads it, persists the new selection only once the old one is safely gone, then loads, attaches and applies the new profile. All of it runs under the striped lifecycle lock so it cannot interleave with the disconnect save or the autosave. On an island server the player leaves the old island, the island runs its normal save steps through the vacancy check, and the new island is loaded through the same lifecycle entry points a fresh arrival uses. If another server already hosts the new island the switch becomes a real transfer to that server, which the existing handoff already resolves to the newly selected profile.
…he switcher Creating a profile, accepting or confirming a coop invite and leaving a coop all set the selected profile and then kicked or transferred the player so the destination would reload their data. They now mint the profile, persist the profile list and hand over to the profile switcher, which moves the session across without a reconnect. Leaving a coop no longer waits for the player to unload before deleting the profile, because the switch has already saved and unloaded it by the time the deletion runs. Deleting a profile removed it from the in memory list but never wrote that list back, so the profile reappeared on the next join with its document already gone.
Nothing kicks players to apply a coop profile any more.
Swofty-Developments
force-pushed
the
fix/profile-switch-in-place
branch
from
August 14, 2026 13:53
4ebb1b2 to
2cc15fc
Compare
Swofty-Developments
marked this pull request as ready for review
August 14, 2026 13:53
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.