It was not until I saw the itween plugin that I realized that I really didn’t know a simple way to move a static mesh actor to a location. I make it moveable, and when I open the blueprint to have it move to a location, it needs an AI controller. Is there a simple way to do this without tweens, and graphs, and matinees etc. I feel like I’m missing something basic.
Well, to move something you’ll have to use blueprints at least. If you don’t care about obstacle avoidance, paths, all this kind of things you don’t need an AI Controller though. There’s some (very) basic movement tools in blueprints with Set Location, Add Local Location etc.
-Tick to set an actor’s location over time and add delta time to a float variable divided by number of seconds plugged into a lerp or interp node. This is how iTween does it under the hood. It spawns an empty actor, takes a start and end value, plugs them into lerp, adds delta time (whether that be from tick or an interval) and adds it to a float variable then modulates that variable by an easetype equation. Then the empty actor transforms the other actor based on this information. This is how to do it in C++.
-Use timelines. Generally timelines are tied to specific number of seconds and specific positions, but you can have a timeline just output a value of 0-1 over 1 second then divide by the number of seconds you want and plug it into a lerp node. I may be wrong, but I think this requires blueprints. I’m not sure if timelines can be created in C++, but I’d like if someone corrected me.
-Use sequencer, but it’s not available yet for the engine at large, only UMG and it only works on a per-object basis, so you can’t reuse animations or change time/easetype after without altering the animation curves.
iTween doesn’t do anything you can’t do in the engine already, it just offers an easier way to do it all. Set and forget. I’m glad you’re enjoying the system!
Check out the tank tutorial on twitchtv (soon on youtube…) for simple movement, i think it can’t be simpler than that…
Thanks for the info, I’ll try those methods. My question is, why doesn’t unreal include those functions to help users simplify the process? If they do things like this, man they would destroy the competition and any need to go to unity or other engines like that IMHO.
fred, what channel on youtube will that be on?
You can watch the infinite runner (or something like that). If I remember correctly, it uses simple movements.
It’d be nice, but Unity doesn’t do it either. In fact, iTween was a Unity plugin before we ported it to Unreal.
Jared, its pretty close because you can use the object.translate function for almost everything and it makes basic moving a breeze. in blueprints, it gets confusing because of having to have a controller, an ai controller , and im not sure how to move objects that aren’t in the main player controller, and not sure what i would need to add in the blueprints if i added another controller for the object…