I’m following the Unreal Engine 4 tutorials to implement collision on my character’s hands with this video
And when I try to put in the construct script function it won't work. What can I change here to make it work like the video?your construction script is always called automatically when the actor is created. just double click the construction script on the menu to the left and you should go right in it like in the video.
EDIT: Just to expand on this, it looks like you are in “Construction Script” not “ConstructionScript” Did you make this function yourself? There should be a default construction script already there.
I actually bought the project in the marketplace, so I’m building on top of it, it was like this already. But I created another function underneath that one, named it that and I’m working on that one. Do you think that’s gonna work? I’m not a programmer, I only know what I get from videos I’ve watched hehe
Actually taking a second look it looks like you are in the correct place. Just zoom out and find the purple node.
A trick for doing this is to have nothing selected (no nodes) and hit Home on the keyboard. It should zoom out to show everything.
Nope, home brings me to the middle, but still nothing there. Like you can see here, I created another function just like that, but I don’t know if I’m just being silly thinking this will work the same way haha
Yeah, that’s not gonna be the same. When you hover over the function in the left bar it should say that it’s will run when the actor is placed or modified. any other function needs to be called directly.
An alternative would be to take your code and put it on Begin Play in the event graph (before anything else.)
I guess I’ll do that, I don’t even know what the difference is, I was just trying to follow the tutorial to the letter. Thanks for the help! ;D
Constructions scripts happen before the the begin play call and are called even in editor. Begin play is only when that actor starts play in the game.