How can I get real-time bullet location with blueprint?

I’m sorry, I’m beginner in Unreal Engine, It can be easy to someone… but I really want to know.

I just used getworldlocation function to get my bullet(sphere) location with blueprint, but it happend(when I using print string than it just displayed only one time.) just once.

Somebody help me plz.

p.s I’m also sorry that my English is turly bad.

Are you calling the function multiple times?

So do you want the location to be printed just when it hits something or every tick it is alive? I am using the first person template in this, it is working fine. I think you might have scripted wrong.

Here is a hasty framework that might help you.

Thank you everybody, I"m really appreciate that you guys answered my question quickly.

But I need to talk clearly.

I want to know when ‘Bullet is flying’ and get that location x,y,z. real time.

For example when I shoot the bullet on the x=0,y=0,z=0. then bullet location will be x=1, y=0, z= 0,
x=2,y=0,z=0,
x=3,y=0,z=0 …
x= n, y=0,z=0 . get the location like this.

But I thank you for all of your guys reply.

Just hook it in to the tick, it updates the actors location (or in your case the world location) based out of delta seconds. Just hook a tick up to my picture and see what you get.

It would still be the same thing. You have to plug the print string with “get actor location” as others pointed out in the Event Tick.

If you want integer values you would have to convert vector to int by using “truncate” and then use them in whatever you want.

To check when the projectile is not flying just create a boolean to control when it hit something.