Kawelo
(Kawelo.)
September 27, 2023, 4:28am
1
Reference ID
bc9ebf57-4c53-56ca-53eb-8f8f1c5b854b
Please select what you are reporting on:
Creative
What Type of Bug are you experiencing?
Devices
Summary
Since the latest update v26.20, vfx spawners don’t spawn when triggered and not work properly.
Steps to Reproduce
For a started game
Launch the game and select the fire class.
Use your sword and swing it.
A custom Niagara effect should appear in the front of you.
Expected Result
There should be a custom flame Niagara effect spawning in the front of you as you swing the sword.
Observed Result
Nothing appears in the front of you when you swing the sword.
Platform(s)
windows pc
Island Code
4583-8797-6699
Additional Notes
This was working fine yesterday (September 25) and today (September 26) it’s not.
Same. I logged this issue yesterday as well:
I’ve also tested that setting VFX Spawner Devices “Enabled on Phase” to “Always” does not help. I’m also listening to EffectEnabledEvent() with a print log message, but it never fires when .Enable() is called.
1 Like
@Kawelo I found a workaround:
I found a workaround that enables VFX Spawner Devices:
Use TeleportTo to move your VFX spawner some nominal distance.
Then, call Enable(). Your spawner should work as normal.
You only need to do the first step once. You can Enable() and Disable() as much as you want from there.
Hope this helps others!
1 Like
Kawelo
(Kawelo.)
September 28, 2023, 3:43am
4
Thank you, I will try this today and give an update if this is a fix!
Kawelo
(Kawelo.)
October 2, 2023, 3:17am
5
How exactly did you do this? sorry I’m kind of new to verse.
In the verse file of your device, add a reference to the VFX spawner:
@editable VFXDevice : vfx_spawner_device = vfx_spawner_device{}
In the editor, be sure to add the VFX spawner to this property.
Back in the verse file, do the following in OnBegin():
Pos := VFXDevice.GetTransform().Translation
Rot := VFXDevice.GetTransform().Rotation
if:
VFXDevice.TeleportTo[Pos, Rot]
This will simply teleport the VFX spawner to the same position, which somehow enables it properly so that your effect works.
robc
(robc_)
October 4, 2023, 1:29am
7
Works for me too, here’s what I added to the code.
if (Vfx.TeleportTo[Vfx.GetTransform().Translation, Vfx.GetTransform().Rotation]):
block:
1 Like
Kawelo
(Kawelo.)
October 5, 2023, 1:43pm
8
Thank you! It works good for some of the effects, but I also have effects that should activate at a position offset a player. And I’m sure you need a lot more coding for that, but thanks again for letting me know the work around.
robc
(robc_)
October 15, 2023, 1:30pm
9
An offset position may not be too much harder.
Here’s an example.
# The 'translation' is the position/location.
CurTranslation := Vfx.GetTransform().Translation
# This example should put it 100 units (cm) further on the X axis.
NewTranslation := vector3{X := CurTranslation.X + 100.0, Y := CurTranslation.Y, Z := CurTranslation.Z}
if (Vfx.TeleportTo[NewTranslation, Vfx.GetTransform().Rotation]):
block:
1 Like