[UE4] How to prevent pawn/object getting physically affected by other objects?
5 replies, posted
I have the following setup:
https://files.facepunch.com/forum/upload/107290/d5b97775-aa74-48dd-8dd0-23d9ea87e1eb/image.png
It's basically a VR Movement Blueprint that I am trying to make.
VRCol is capsule that has gravity and all physics (Like dropping on ground, falling from heights, bumping into walls etc..).
I've set rotation constraints true for X and Y (So it cant tip over or fall over).
But I left Z rotation constraint as false so user can still turn around.
Problem is that user is being affected by external forces, like objects hitting them, rubbing against walls etc..
Any ideas how could I prevent by VRCol from being affected physically by physics of other objects?
Like sometimes ball will hit object and it will spin forever as if it was in space or something, here is a video:
While there are reasons for rolling your own character logic, I'd advise not doing it in blueprint because this is nigh impossible to achieve. Any reason you're not using the default Character provided by Unreal?
There are ways around this in C++ but I'm not sure you can achieve the same in blueprint.
I am not familiar with C++ unfortunately so going with BP.
Essentially what I am trying to get is pawn that is player for VR and has basic physics to it (walking into walls, bumping into objects to make them move, stepping on ground (instead of floating)).
This is for normal walking, not teleportation as its shown in sample VR project in UE4.
Adding the CharacterMovementComponent to your pawn should support this. The component has a AddMovementInput.
You can follow this tutorials step 1-3, the others are not relevant for what you're doing.
Setting Up Character Movement in Blueprints
Thanks a lot for the suggestions.
I've looked into Character blueprint parent class and reworked my character, it works now exactly as I wanted with much less hassle.
I didnt know character blueprint is default built into engine.
Just glad I could help, good luck on your VR game. Looking forward to seeing a post in WAYWO ;)
Sorry, you need to Log In to post a reply to this thread.