I using this battle animation schematic to get an ability to:
1) spawn a vfx projectile from the caster
2) move toward the ability (moving) target
3) despawn the vfx projectile on arrival
4) spawn an explosion vfx on target destination
5) apply the ability effect to the target

The ability seems to always skip 1-3 but I can't figure out why :(

image
  • Are you sure the Vector3 Check Distance Node is correct? Use a Unity Log Node to check if the loop is being skipped. If it's not being skipped then confirm if the vfx projectile is even being spawned, then confirm if it's position is being changed. You can confirm all this by storing the position data into a variable and displaying it in a Unity Log Node. You should find your answer once you have all that information.
  • The Move and Rotate nodes are used for per-frame changes, e.g. as part of a Tick Machine running each frame.
    E.g. use a Change Position or Move Into Direction node instead.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • Thank you @Dre788 for the tip, it helped isolate the issue :)

    @gamingislove I was able to spawn the prefab but it looks like it lives only one frame before being destroyed. I tried playing with the Move Into Direction node parameters but I can't seem to get it to work.

    I am a bit confused by the Movement Settings parameters:
    I can set Time(s) and Speed but if want my prefab to reach a moving object, only one of the 2 values can remain constant, while the other will have to adjust dynamically.
    Is the Time Between (s) the time before I start moving the object toward the target?

    This is how my schematic looks like with the Move Into Direction node:
    image
  • The Move Into Direction node moves a game object, as the name suggests, into a direction. I.e. the position of the starting object will be interpreted as movement direction and it'll move into that direction for the defined time using the defined speed.

    If you want to move to a position, use a Change Position node. Time Between (available in most time-based nodes) is used in case more than 1 game object is moved, e.g. if you have multiple spawned prefabs, each would move one by one with the time between used to wait between starting movement on each of them.
    Please consider rating/reviewing my products on the Asset Store (hopefully positively), as that helps tremendously with getting found.
    If you're enjoying my products, updates and support, please consider supporting me on patreon.com!
  • I was finally able to get it working, thank you so much for the support Nicholas!
Sign In or Register to comment.