UE4 Cube Mesh Not Colliding using SetRelativeLoc
I switched a few of my meshes to UE4 cubes and the collision stopped working. I made several changes during this process. So I wasn't able to identify the root cause. I decided to create an empty project for debugging. I have a timeline which sets the object location. I have tried the following.
Is this an issue with driving an actor/mesh with SetRelativeLocation? I expect it is a simple setting, but I haven't found it after rooting around. I found this related question but there was no answer.
I have attached the entire basic debugging project (2.5 MB).Collision Debuging Project UE4.9
Please note that the extra timeline in bpPlayer was for testing the blueprint directly within the map instead of as a child.
I forgot to mention that I enabled physics on the top cube and removed the SetRelativeLocation timeline. The top cube drops and correctly collides with the bottom cubes. However, it doesn't work with either set location or transform. I also tried explicitly enabling collision in the constructor (see below). This didn't work either.
I found the following post in the forums. Zak Middleton (Unreal Engine Developer) responded as follows to a similar question.
I found this to be an interesting tid bit about the RootComponent. However, it didn't help me.
I used the blueprint to test collision. I tried various versions of the SetLocation (Actor etc...) and Transforms as well. I tried it with and without sweep enabled.
It's possible that my simple debugging project was corrupted. I tried to delete one of the blueprints to start over and it said that there were 99 references in memory.
I created a new project using the information I found in my Update 2 and the collisions are now working.
I have attached a simple working project with the collision working using SetRelativeLocation. I hope this helps somebody else because I wasted 1/2 a day researching this topic and experimenting.
answered Sep 08 '15 at 01:38 PM
Follow this question
Once you sign in you will be able to subscribe for any updates here