I have a character here with a hammer in a socket.
I want to make it so that the hammer has no collisions unless he is in a swinging state. When he swings, I want the hammer to detect the surface normal of the first surface that it collides with. I’m not sure where to start with this so any help would be greatly appreciated! I’m working with blueprints.
You can set an objects collision via node. Just have it so when the player hits the swing button, it Set Collison on the hammer. To know when the swing animation is done you can setup a notify in your montage that will trigger another event that can Set the collision to None. Only thing with setting collision from nodes is you can’t set the “custom” collision so choose one that suits your needs. You can use a Line Trace by Channel or Line trace by Object and it will return the Hit Actor. If the Actor being hit has its collision set to Block (on the object type of the hammer) then the hammer shouldn’t pass through. Hope this helps