Closed QuiCM closed 4 years ago
This is currently a really controversial topic, making it to the top of r/Games today with developer response. Probably a very high priority feature request.
Looking at the packets, while we can send updated metrics to affect luck, I am concerned the client recalculates luck on the fly resulting in us flooding packets to resync. OnUpdate() calles UpdateBiome() which checks for a gnome on screen.
Player player19 = Main.player[index37];
player19.ladyBugLuckTimeLeft = num134;
player19.torchLuck = num135;
player19.luckPotion = num136;
player19.HasGardenGnomeNearby = flag10;
player19.RecalculateLuck();
if (this.HasGardenGnomeNearby != Main.SceneMetrics.HasGardenGnome)
{
this.luckNeedsSync = true;
this.HasGardenGnomeNearby = Main.SceneMetrics.HasGardenGnome;
}
This may be better suited to a plugin then perhaps. I imagine you could simply hook retain a list of players with modified luck and reset their luckNeedsSync value every update, but I'd rather not bake that into TShock's spaghetti
We can now modify luck on clients. We should have a command for this