Skip to content

[Bug] Cursed items particle effect crash #823

@SiphaTH

Description

@SiphaTH

Issue Description

A thorough description of the problem:
Expected behavior: Particles supposed to stop generate when the game is frozen due to being unfocused.
Actual behavior: Particles kept generating, overloading the game and making it crash.
Context: I tabbed into a different window, kept the game running in the background. When this happens, Terraia stops and most animations stop as well. But when in a few minutes I tabbed back in, the game crashed. This wasn't the first time, it only happens when I have my inventory open with a cursed item in it.
Error message: [19:51:38.381] [.NET TP Worker/ERROR] [tML]: Unhandled Exception
System.IndexOutOfRangeException: Index was outside the bounds of the array.
at StarlightRiver.Core.ParticleSystem.b__16_0(Int32 from, Int32 to, Object context) in StarlightRiver\Core\ParticleSystem.cs:line 77
at ReLogic.Threading.FastParallel.RangeTask.Invoke() in D:\a\tModLoader\tModLoader\src\tModLoader\ReLogic\Threading\FastParallel.cs:line 37
at System.Threading.QueueUserWorkItemCallback.Execute()
at System.Threading.ThreadPoolWorkQueue.Dispatch()
at System.Threading.PortableThreadPool.WorkerThread.WorkerThreadStart()
[19:51:38.614] [.NET TP Worker/FATAL] [tML]: Native exception has occurred, attempting to determine erroring module...
[19:51:38.632] [.NET TP Worker/FATAL] [tML]: Exception occurred in module: C:\Windows\System32\KERNELBASE.dll
[19:51:38.632] [.NET TP Worker/FATAL] [tML]: Attempting to save minidump...
[19:51:42.337] [.NET TP Worker/FATAL] [tML]: Minidump saved to: 'D:\SteamLibrary\steamapps\common\tModLoader\tModLoader-Logs\client_v2025.10.3.1_12-11-25_19-51-38-6329_18.dmp.zip'

Reproduction

1. Put any cursed item in your inventory, opened storage or equipment slots.
2. Atl+tab into a different window.
3. Wait a few minutes.
4. Alt+tab back to Terraria.
5. Game crashes.

Mod list:

Image
	Config settings: 
Image Image
	Game settings: 
Image
	Gameplay events happening: Nothing, AFKing with opened inventory.
	Your inputs: Literally nothing, AFK.
	OS: Windows 11

Additional context and log files

client_v2025.10.3.1_12-11-25_19-51-38-6329_18.dmp.zip
client.log

Metadata

Metadata

Assignees

No one assigned

    Labels

    NewNeeds tagged/assaigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions