Most performant way to set world location of several (20-50) actors on a timeline for vehicle movement?
Put them all in a blueprint and move the blueprint
Seriously though, if you try and keep them as separate actors, it will run slowly…
I guess this only works if they are moved with the same speed and direction? Or do you mean that there is a performance gain to move them relative to the blueprint?
Sorry, not really clear on what you’re trying to do.
If this mixture of actors, the vehicle? Then I would say put them in a blueprint.
Or, are you trying to move the background, or…?
Im trying to move vehicles such as trains, boats etc indepentent of each other, by setting their position often enough for it to run smoothly. If this is not the way to go, do you have other movement methods that might work better for vehicles such as these?
Ok, so they’re all separate objects, and you want to set the location of many of them runtime.
You can either set their location from the level blueprint, if they are just a mesh, or independently for each one, if they’re blueprints.
I don’t think there would be any difference here. There’s no trick, really
Making each one a BP is the most elegant method, for sure. You also get to configure one central BP as the parent, and then each vehicle can’t inherit the methods from that one.
I see, thanks So none of the movement components or other systems that might make vehicle movement more performant? I dont want to use physics, as it is so unpredictable…
It really depends on what you want.
If they are going to be real vehicles, and you might want control them, then you need to probably go down the standard route and use a vehicle blueprint.
If they just objects moving around to give the impression of realism, then you can cut some corners, although having a parent blueprint is still a good idea. Especially if you want them to follow splines etc.
Yeah I have already created a movement system for boats, trains and wagons using set location, but I am looking for ways to optimise this movement. If anyone have suggestions for parameters that can be tweeked or ways to update the location that might improve performance, I would be very happy to hear them
If you were to rely on ticks for movement (like trains on splines) then you could consider aggregating the tick of all railway wagon’s to their driving train, or to a single controller.
The recent unreal talk mentions this at around 24:24
Thankyou! Any tips is very appreciated