One-shot particle lag in editor

:information_source: Attention Topic was automatically imported from the old Question2Answer platform.
:bust_in_silhouette: Asked By Inces

Did anyone experience this ?
When setting particles to one shot in editor , every time I refresh emitting , a lag spike occurs. This lag spike is long enough to severely obstruct preview of particle emission, so it is very inconvenient for workflow. I am using Godot 3.5, but opened the scene in 3.2 and lag also happens. I have read before how Godot handles shader compillation and how it may cause lags, but it shouldn’t happen in editor preview !?

Setup is : 3d particles with quad mesh set to billboard mode, with custom spatial shader provided with 2 textures. render mode blend_add unshaded. Total particles per emission - 18, but lags at any amount.

What if you preload the particles, making that version of the particles not one shot? (I got the idea from https://github.com/godotengine/godot/issues/13954). That way the material might already be loaded when you emit the one shot version of the particles and lag could be avoided?

godot_dev_ | 2022-12-13 15:00

I know this trick, but my particles freeze in the editor, not in running project. So I can’t preload them, they are supposed to already be fully loaded. And this freezeframe makes it hard for me to work with particles in editor too, I don’t even want to use them inside project yet.

Inces | 2022-12-15 11:41

Yeah, I’m having the same issue. It’s fine in the game, but the in the editor, the particles freeze and stutter. Particles2D, CPUParticles, whatever… It only processes intermittently if i’m moving the mouse. But, in the game, it renders fine.

Please, let me know if you solved this!

CassanovaWong | 2023-02-02 16:32