sws2-thread-management
Keep SwiftlyS2 game operations on the game thread while coordinating async/await, Task.Run, background I/O such as HTTP and database calls, Core.Scheduler NextTick and NextWorldUpdate callbacks, delays, repeating timers and their cancellation across disconnects, map changes and hot reloads. Use whenever plugin code awaits, starts a task, schedules or delays work, uses a timer, or hits a crash or exception from calling game APIs off the game thread.
Pinned to revision b8ce269292be, so it is the text this page describes rather than whatever the author pushed since.
Files
Every link opens the file at its source, pinned to the revision this page describes.