verse SpawnParticleSystem to spawn vfx freezes game

Summary

I never used SpawnParticleSystem. I just tried it out and it is unusable. It sometimes freezes all the players game when spawning the vfx for the first time. I can confirm this happens with any vfx, I created the most basic vfx using the template and it happens. I think it also has to do with how far from 0,0,0 the vfx spawns in the world and where the players are. But this is speculation. On lower end devices like the switch it may cause a crash.

It the clip I started the game and pressed the button, that time it did not happpen. Then I played 5m on the main island and after that teleported back to spawn. I pressed the button again and the lag happened.

I have other vfx in my map but those I do not spawn with verse, for example I have a siphon vfx that I play using a vfx powerup device. This has no issue. It is just the verse part here.

Please select what you are reporting on:

Creative

What Type of Bug are you experiencing?

Verse

Steps to Reproduce

Not sure, I think it is map specific.

Expected Result

There is no freeze when spawning vfx through verse

Observed Result

A freeze

Platform(s)

Any

Island Code

6570-5231-1418

Upload an image

Additional Notes

Relevant code:
SpawnVFX(VFX:particle_system,Pos:vector3,TimeAlive:float,?Rotation:rotation=IdentityRotation()):void={
ActiveVFX := SpawnParticleSystem(VFX,Pos,?Rotation:=Rotation)
Sleep(Abs(TimeAlive))
ActiveVFX.Cancel()
}
OnButtonPressed(Agent:agent):void={
spawn{SpawnVFX(PanelVFX, B1.GetTransform().Translation, 2.0, ?Rotation := B1.GetTransform().Rotation)}
}

FORT-1023310 changed to ‘Needs More Info’. We’re missing information that would help us determine the source of the issue.

1 Like

Any updates? This issue is still happening.

Hi, are you able to elaborate on what information you need? We will provide.

Hey folks, looking into this issue. A couple of questions

Does this occur in a blank project? Or is this solely project specific?

Is this a looping VFX or a oneshot? It sounds like it’s likely a oneshot and not looping

From the post it sounds like there is severe hitching when spawning the VFX for the first time within a session or that it might have to do with how far from the world origin the VFX is spawned compared to the players location.

The repro from the orignal post appears to be:
Start a game

Call SpawnParticleSystem to spawn a particle_system near the player

Move some far distance away from the spawned particle_system

Teleport or move back to the location of the previously spawned particle_system

Attempt to call SpawnParticleSystem to spawn a particle_system near the player again

Result

A severe server hitch occurs and the particle_system spawns

1 Like

Hi, we are currently working on full repro steps for you, we will get back to you shortly

1 Like