Make an empty actor blueprint, and put this code in it
Then, you can create a child from this
Put some meshes in it, and, voila
If you want to try this behavior on one of your other blueprints, just reparent it