0
0
Fork 0
mirror of https://github.com/Sanae6/SmoOnlineServer.git synced 2024-11-24 20:25:18 +00:00

Delay fm sync by 15s

This commit is contained in:
Sanae 2022-03-31 13:56:48 -06:00
parent 4dee13a9d7
commit b3686e8197

View file

@ -85,9 +85,14 @@ server.PacketHandler = (c, p) => {
ConcurrentBag<int> clientBag = (ConcurrentBag<int>) (c.Metadata["shineSync"] ??= new ConcurrentBag<int>());
clientBag.Clear();
break;
case "WaterfallWorldHomeStage" when gamePacket.ScenarioNum > 0:
case "WaterfallWorldHomeStage" when gamePacket.ScenarioNum >= 0:
bool wasSpeedrun = (bool) c.Metadata["speedrun"]!;
c.Metadata["speedrun"] = false;
ClientSyncShineBag(c);
if (wasSpeedrun)
Task.Run(async () => {
await Task.Delay(15000);
await ClientSyncShineBag(c);
});
break;
}
break;