You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This is a bit of an odd issue, with somewhat complex behavior, but I've done enough fiddling to pin down a pattern, and hopefully it can be reproduced. Excuse the long read, this is gonna take a while.
For reference on the environment in which this bug seems to occur: I'm working with a custom Fabric modpack. The pack runs on Minecraft ver. 1.19.2, Fabric mod loader ver. 0.15.7, and it includes the most recent compatible versions of Origins (ver. 1.7.1), Tinker's Statures (ver. 1.1.0+1.19), and Switchy (ver. 2.9.0+1.19). In addition, Switchy's plugins for Inventory (ver. 1.8.2+1.19) and Teleport (ver. 1.2.5+1.19.2) are also present, as well as Fabric Tailor (ver. 2.0.1), though these last three seem to be unrelated to the issue. The bug behaves identically in single- and multi-player (multiplayer tests took place on a personally-hosted server, running the same modlist). In all tests, config/switchy/apoli.toml has "switchCommandPowers" set to "true", and "exceptionPowerIds" set to an empty array. Furthermore, all modules listed in config/switchy/config.toml are set to "ALLOWED" (except Fabric Tailor, which is set to "ALWAYS_ALLOWED"). The settings in config/switchy/pehkui.toml have no apparent effect on this behavior, and all other configs for the mods previously mentioned were left unchanged.
As for the issue itself: Essentially, when swapping between Switchy profiles, certain powers that have been granted via Apoli's /power grant command will seem to lag behind, and only have their effects kick in on the next profile the player changes to, even if that next profile isn't meant to have the power. It's a bit hard to explain the details without an example, so here's one from my own testing:
A player has three Switchy profiles: A,B, and C. All available Switchy modules are enabled, and the player has swapped to each profile at least once, providing all three profiles with the Human origin and the Sized stature.
Starting out on profile A, the player uses the /power grant command a couple times to give themselves two powers: origins:sprint_jump, and origins:fragile. Playing as profile A for a while afterwards, both powers work as intended.
The player then uses Switchy to swap to profile B. They quickly find that, although the effects of the fragile power have stopped, the effects of sprint_jump are still active. They use the /power list command to figure out if the power has carried over, but it states that the only power they have enabled is tinkerer:sized, as given by their stature layer.
Still on profile B, the player uses the /power grant command again, this time giving themselves origins:climbing. Immediately, the effects of sprint_jump vanish, and origins:climbing kicks in. They use /power list to confirm, and it states they currently possess tinkerer:sized and origins:climbing, as well as climbing's sub-powers, origins:climbing_climbing and origins:climbing_toggle.
The player then swaps to profile C. This time, the effects of climbing and its sub-powers copy over, but again, when using /power list, the only power reported to the player is tinkerer:sized.
Without any further commands, the player swaps back to profile B. Now, no power effects seem to be active at all, but /power list still reports origins:climbing and its sub-powers to be in the player's possession, in addition to tinkerer:sized.
The player swaps one more time, to profile A. There, they experience the effects of fragile and climbing, while /power list reports fragile and sprint_jump.
It took some time, but through this and other tests, I've boiled this strange behavior down to a set of rules which it follows reliably.
Each power that can be granted by the /power grant command falls into one of two categories: Those that switch out properly as expected, and those that lag behind (which I'll just call "laggards" for short).
Swapping to a profile which has been given a laggard power via Apoli command (such that the laggard's only source is apoli:command) will register the player as owning the laggard, but will not apply the laggard's gameplay effects (unless the laggard is also owned by other means, or if the player is swapping in from a profile which also owned the laggard via command).
Swapping from a profile which has been given a laggard power via Apoli command (even if the laggard is sourced from apoli_commandin addition to other sources, such as an origin layer) will apply the laggard's gameplay effects for the profile the player has swapped into, but will not register the player as owning the laggard (unless the second profile also owns the laggard via command).
Certain actions can "reboot" a specific player's powers, clearing out any laggard effects that shouldn't be active and properly applying the effects of any laggards which should be active. These actions don't stop laggards from misbehaving in the long term, but they will fix any issues that are happening at the moment when they occur. Ways to "reboot" a player's power list include exiting and re-opening a world in singleplayer, logging out of and back into a multiplayer server, giving the player a new power via command, removing one of the player's currently-owned powers via command, and changing the player's origin or stature.
Whether or not a specific power is a laggard is seemingly locked on a per-power basis, independent from any environmental factors that I've been able to test. As examples, origins:sprint_jump and origins:climbingalways behave as laggards no matter what, and origins:fragile and all of the size-related powers from Tinker's Statures are never laggards. As of yet, each and every power I've tested has either always been a laggard in every situation, or never been a laggard in any situation. As for what makes a given power a laggard and what makes one work as expected, though, I can't yet tell.
From what I can discern, the powers are being saved to their respective switchy accounts properly, it's just the activation and deactivation of powers when switching between accounts that goes wrong. Maybe it's something along the lines of Switchy's Apoli module feeding some of the powers into the system at a time when Apoli isn't ready to implement the effects, and it just slaps them into some sort of buffer for later - I don't know all that's going on under the hood, but that's the best guess I've got.
Whatever the case may be: If I can provide any other information which might be useful, just let me know. This mod's been great to me, and a wonderful aid for some close friends of mine, and I'd be happy to do whatever I can to help. Best regards, and thank you all for your time.
The text was updated successfully, but these errors were encountered:
This is a bit of an odd issue, with somewhat complex behavior, but I've done enough fiddling to pin down a pattern, and hopefully it can be reproduced. Excuse the long read, this is gonna take a while.
For reference on the environment in which this bug seems to occur: I'm working with a custom Fabric modpack. The pack runs on Minecraft ver. 1.19.2, Fabric mod loader ver. 0.15.7, and it includes the most recent compatible versions of Origins (ver. 1.7.1), Tinker's Statures (ver. 1.1.0+1.19), and Switchy (ver. 2.9.0+1.19). In addition, Switchy's plugins for Inventory (ver. 1.8.2+1.19) and Teleport (ver. 1.2.5+1.19.2) are also present, as well as Fabric Tailor (ver. 2.0.1), though these last three seem to be unrelated to the issue. The bug behaves identically in single- and multi-player (multiplayer tests took place on a personally-hosted server, running the same modlist). In all tests, config/switchy/apoli.toml has "switchCommandPowers" set to "true", and "exceptionPowerIds" set to an empty array. Furthermore, all modules listed in config/switchy/config.toml are set to "ALLOWED" (except Fabric Tailor, which is set to "ALWAYS_ALLOWED"). The settings in config/switchy/pehkui.toml have no apparent effect on this behavior, and all other configs for the mods previously mentioned were left unchanged.
As for the issue itself: Essentially, when swapping between Switchy profiles, certain powers that have been granted via Apoli's /power grant command will seem to lag behind, and only have their effects kick in on the next profile the player changes to, even if that next profile isn't meant to have the power. It's a bit hard to explain the details without an example, so here's one from my own testing:
It took some time, but through this and other tests, I've boiled this strange behavior down to a set of rules which it follows reliably.
From what I can discern, the powers are being saved to their respective switchy accounts properly, it's just the activation and deactivation of powers when switching between accounts that goes wrong. Maybe it's something along the lines of Switchy's Apoli module feeding some of the powers into the system at a time when Apoli isn't ready to implement the effects, and it just slaps them into some sort of buffer for later - I don't know all that's going on under the hood, but that's the best guess I've got.
Whatever the case may be: If I can provide any other information which might be useful, just let me know. This mod's been great to me, and a wonderful aid for some close friends of mine, and I'd be happy to do whatever I can to help. Best regards, and thank you all for your time.
The text was updated successfully, but these errors were encountered: