Now that UE4 has been out for a few weeks, it seemed a good time to do another round of quick Blueprint tutorials! I want to try and address some common difficulties, and introduce a couple of handy features. Let’s go!
Adding Interaction
Once you have a player moving around, you often want them to “reach out and touch something.” Giving the player to power to interact can be done in a few ways – this video shows how to do a trace to see what is in front of you, and then either Cast it to a particular type and manipulate it, or use a ‘Blueprint Interface’, which allows simple interaction with lots of kinds of objects.
Getting Class Blueprints To Talk
Once you start building interesting Blueprints, the next step is often to get them to team up and work together. There are several ways that instances of Class Blueprints can know about each other; this video shows two – explicitly telling one about the other, and using the ‘Find All Actors Of Class’ node.
Using 3D Widgets
This is a feature that our designers have found really powerful, and used for all kinds of madness! It lets you visualize a Vector or Transform variable as a little blue diamond in the level, which you can manipulate using the regular transform controls, and use as part of your Construction Script.
Using RandomStreams
When you use random numbers to create procedural content in a Construction Script, one annoyance you quickly run into is that things are different every time. But there is a solution – RandomStreams! These give you a random but repeatable sequence of values, and this video shows how to use them.
Exposing Parameters On Spawn
This is super handy for making a Blueprint easily configurable as you spawn it.
Hope you guys are finding these helpful! Reach me on Twitter at @EpicJamesG or post your questions and comments over in our forums.