x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

What is the correct way setting collisions for non-human Characters with Blueprints?

Hello Everyone,

i was following the UE4 Tutorial for the 3rd Person Game blueprints. It was really nice (thanks Zack!) but i have a problem with the character collision since i am using a non-human character.

So i get this effect now: alt text

I know i can change the capsule in the Blueprint itself but the only way it would work, would be a very spherical capsule that adds too much collision left and right to the character (marked Red): alt text

So i tried to add an additional collision capsule but the world objects don't seem to care: alt text

Player collision view with added collision capsule: alt text

So, what i would like to know is, where am i going wrong? What did i miss?

Oh btw, the added collision sphere do work on Actors that have physics enabled though.

I did read that it is somewhat possible to use a Pawn as the parent class but that would kinda make the character blueprint obsolete and that couldn't be right, i guess ...

So where to start, what to read, how to proceed?

Product Version: UE 4.10
Tags:
more ▼

asked Feb 04 '16 at 11:21 PM in Using UE4

avatar image

FuzzyPones
66 4 6 8

(comments are locked)
10|2000 characters needed characters left

2 answers: sort voted first

You still have old capsule component on, disable "Auto Activate" on it so engine will ignore it or disable any collision in it, you won't be able to deleted because capsule component is hard coded in to ACharacter class. Did you also tried to move it actully?

more ▼

answered Feb 05 '16 at 12:00 AM

avatar image

Shadowriver
34.6k 917 164 1095

avatar image FuzzyPones Feb 05 '16 at 12:29 AM

Hello Shadowriver, thanks for your Answer.

The only "Auto Activate" options i have inside the Character Blueprint is "Mesh (inherited)" and "CharacterMovement (inherited)". Untick either of them does not help, When i untick on the Character Movement i can't move the character anymore.

Disabling the Collision on the Capsule lets me clip through the level (even when an other collision capsule is inside the Blueprint)

Well you can't move the inherited capsule inside a Character Blueprint, the only thing movable is the Mesh.

Any other ideas?

avatar image Shadowriver Feb 05 '16 at 12:57 AM

Then apply collion to the new capsule component same as you have in default one

avatar image FuzzyPones Feb 05 '16 at 01:04 AM

I did, did not work unfortunately.

avatar image Shadowriver Feb 05 '16 at 03:13 AM

Did you check if collision channels are good? Alternativly you could try using Pawn class insted of Character

for got to say btw this is nice Guilmon ;3

avatar image FuzzyPones Feb 05 '16 at 03:32 AM

Both, the static object and the collision capsule is set to "BlockAll" so that channeling should work correctly, right?

Yeah i read that you could use a Pawn class but it has less stuff wired in which makes the Character Blueprint Class very convenient.

Thanks! Though it was a mesh i found online so cred goes firstly to anon who did that, i just set up rigging and modified it a bit ;]

avatar image Shadowriver Feb 05 '16 at 03:35 AM

Well as you can see it does not make convenient to you. MAke it Block on everything. Can you show screen of settings of both capsules

avatar image FuzzyPones Feb 05 '16 at 03:52 AM

Well it is very convenient on all the other parts except for that collision problem :D Isn't the Character Class not derived from Pawn anyway?

Character Blueprint: So here is the Main: alt text

And the additional Collision Capsule: alt text

Level: And here the world Static: alt text

I did not change any of the presets so they are how you get them from a fresh editor installation.

avatar image Shadowriver Feb 05 '16 at 04:37 AM

I lookup the Character code and defult capsule component is refrenced a lot including setting it in updated component inside movment component (not usre if you can even do that in Blueprints). I think character can't hold up without that component. Thats why i proposed Pawn as Pawn don't have default physics (aka Capsule Component).

So i got diffrent idea, leave capsule component, change it hight or scale it so it's enouth to make character walk yet overlap with things. Then place 2nd capsule component and set up chanells in both in the way that other stuff in your game will interact with new component not the old one

avatar image FuzzyPones Feb 05 '16 at 05:06 AM

Well i guess it would be unwise to use a pawn instead of a character. From the documentation it says:

The CharacterMovementComponent allows avatars not using rigid body physics to move by walking, running, jumping, flying, falling, and swimming. It is specific to Characters, and cannot be implemented by any other class. Properties that can be set in the CharacterMovementComponent include values for falling and walking friction, speeds for travel through air and water and across land, buoyancy, gravity scale, and the physics forces the Character can exert on Physics objects. The CharacterMovementComponent also includes root motion parameters that come from the animation and are already transformed in world space, ready for use by physics.

So i would like to keep sticking to the CharacterBlueprint.

Then place 2nd capsule component and set up chanells in both in the way that other stuff in your game will interact with new component not the old one.

Made a new Object Channel and set it to Block. Set the type on the WorldStatic mesh to that Channel and changed the collision behavior on the 2nd capsule to block that channel. Does not work.

avatar image Shadowriver Feb 06 '16 at 12:40 AM

It not unwise and aspecially not impossible but it would simply require more work, but ok :p And what i said the original capsule make so it very little yet enouth for walking to work then make 2nd capsule to work. Hmm you really can't editor original capsule?

Hmmm maybe check if movment component dont have some settings, it seems it kind of tied to it and ïn codeCharacter class sets capsule component as "UpdatedComponent", if there nothing then i guess this can be solved only via C++, which won't be that hard actually i can even give you code (if we asume that this ÜpdatedComponent has something to do with this)

avatar image FuzzyPones Feb 06 '16 at 04:21 AM

Yeah i am sure i would be able to get a Pawn Blueprint working to behave like a Character Blueprint but i usually don't wanna mess so much with wired in relations.

You are free to create a simple 3rd person project in your editor and mess around with the capsule yourself. I didn't see anything interesting but maybe you have more experience and find something that actually works.

Yeah sure i can edit the C++ classes and are also capable of doing so but maybe there is an editor-based way of solving this without messing with the engine.

For example, maybe code afterwards relies on the main collision object to be a capsule, changing it into a box might break things.

avatar image Shadowriver Feb 06 '16 at 04:53 PM

You dont need to mess with engine, all you need is to make node that changes one variable in given CharacterMovmentComponent

avatar image Shadowriver Feb 06 '16 at 04:58 PM
avatar image FuzzyPones Feb 06 '16 at 06:19 PM

I guess you wanted me to set this in the Construction Script Panel from the CharacterBlueprintClass, the only target that this node accepts is though a "Movement Component Reference" so you can't update the Collision Capsule Component with it.

avatar image Shadowriver Feb 07 '16 at 12:06 AM

You don't know what Target pin is for? That pin is to point on what object function will be called, this is case "Character Movement Component" because obviously we setting Updated Component there, you should connect Capsule to other pin.

Construction build should be the best, but if it's not working try also Begin Play event

avatar image FuzzyPones Feb 07 '16 at 12:32 AM

It isn't working for me, looks like i made something wrong. How did you set it up yourself so that it works?

I did it this way and it doesn't: alt text

newcollision.png (85.1 kB)
avatar image Shadowriver Feb 07 '16 at 12:47 AM

Then i have no idea what to do if this does not work

avatar image FuzzyPones Feb 07 '16 at 01:15 AM

Aww bummer. Thanks for your effort though! At least it helped me understand these things a bit better ;]

(comments are locked)
10|2000 characters needed characters left

OMG, I have read so many threads just like this one and they all go through the same stuff and then at the end there is no answer. Did you ever figure out how to get the character BP to work with animals or did you end up creating a custom pawn?

more ▼

answered Dec 17 '18 at 08:42 PM

avatar image

JohnADaniels
60 4 6 7

avatar image FuzzyPones Dec 24 '18 at 07:42 AM

Yeah there is no "real" answer to this. You can create your own pawn with collisions that works very good or move the capsule so it capsures the "front" part of the mesh with the back side still clipping through objects though.

It was once a FR on trello to be able to change the capsule collision but never got into any version sadly.

We are just not enough people with that problem I guess.

Creating a pwan with custom collisions will give you additional knowledge though so it's not just tedious stuff.

Good luck m8 and merry xmas!

(comments are locked)
10|2000 characters needed characters left
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question