Floating enemies

Hi, I’m trying to make the enemies in my game “float”, like going up and down. But when I add an interp mouvment, my ennemies doesn’t move forward anymore, they just “float” in place. I can’t figure out how to fix thix, I’ve tried to separate the two motions in a parent and a child. I’ve created a parent that has the forward motion, and its child that has the interp mouvment, but it still does not work. Is there an easier way? Thx

Hi, I’m not too familiar with working with flying enemies, but I think I know something that might help, but won’t solve all the issues you may be experiencing. If you set your enemy’s movement mode to flying they will be able to move while in the air. (You can find this setting in the Character Movement Component). Setting your enemy’s movement mode to flying will allow the enemies to move in the air and stay in the constant Z axis.

Now I’m not sure how to move the enemies up or down while in the flying state. That may be something you might want to look further into yourself, but if I come across anything that might help, I’ll let you know!

Hope This Helps & Good Luck! :+1::pray:

Hi, doing so make my ennemies (who are character Blue prints) float up and right correctly, but they don’t go forward, the interp to movement is taking over my code to get to a goal

There was old , but simple and great tutorial about “Hoover component”. However i cannot find it now on YT.

You can add this yourself:
add thruster (physics), enable physics for your bluepritnt. Then line trace down from center of blueprint mesh. and add impulese (straight up) when its closer than some distance from ground.

Whole thing will balance itself.

When you have floating physics based actor, you can add some sine component to impulse strength based on time. This way it will move ump and down.

And because it is physics based you can push it around.

If you have trouble doing it i can make small example project.

Care to show us the interp code? you might be overriding the X and Y axis as well.

This is my code to make ennemies move forward


And this is what I put in the interp to movement

I’m new to coding so I’d really appreciate if you could show me how to do, thank you so much