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"

Why is the player collision always an extra 2.15 units above the ground? Is this some sort of UE4 collision buffer?

I'm making a first person shooter. I've noticed the player's collision capsule is consistently 2.15 units higher than I'd expect it to be. I'm guessing all moveable collisions do this. But it's something I just noticed.

Is this by design on the engine side?

It's causing problems when I'm trying to get the player to a specific location with collision off, and then I reenable collision and it pops up 2.15 units.

If this is not addressable on the engine side, is there any recommendation on how to proceed? With the spots I want the player in, should I just add 2.15 to them in Z?

alt text

Product Version: UE 4.9
Tags:
more ▼

asked Sep 22 '15 at 02:18 AM in Blueprint Scripting

avatar image

jmalaska
732 41 38 60

avatar image Erasio Sep 22 '15 at 03:16 PM

I have never noticed anything similar... could you show me the viewport of your player character?

Because my first guess would be the capsule is not properly aligned with the mesh.

avatar image jmalaska Sep 22 '15 at 04:43 PM

Thanks for the reply. The image above is taken during the game running (I ejected). It's the side view in wireframe mode.

I don't think it's a mesh issue, since that'll go wherever the capsule location is.

avatar image xXHomieGXx Nov 03 '15 at 02:15 AM

I have noticed a similar problem on my Paper2D project. Have you found a solution?

avatar image Distul Nov 03 '15 at 06:18 AM

I've noticed this as well. You may just have to raise your collision slightly until/if it's resolved.

avatar image xXHomieGXx Nov 04 '15 at 10:05 PM

It's weird because at first when my character spawns in they are a few pixels above the floor, but after they land from jumping or fall onto another platform they sink to the correct height.

avatar image jmalaska Nov 21 '15 at 06:13 PM

That's interesting, maybe it has something to do with jumping/falling or the initial character spawn point.

I haven't found a solution but I'll take a look -- thank you for the heads up!

avatar image xXHomieGXx May 15 '16 at 01:15 AM

I had given up on this for a few months but here I am again. I've been working for a the last week trying to figure out a solution. It's really convoluted and still isn't satisfactory.

My game's a 2d sidescroller but I'm sure part of this solution will appy. I'm also using the "Use Flat Base For Floor Checks" in my character movement node.

Besically, I check when my character is moving on the ground then do a line trace on either side of my character to get where the ground location is (you can also use the "check floor" when you pull of from the character moevement node, then break hit result and there should be one called "floor distance.") I set my character at the floor location every frame (acounting for the capsule height/radius) There's some extra stuff you have to do to acount for hanging off ledges and for being on inclines and that's what I'm in the middle of right now.

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Digging into similar problem I stumbled upon this forum thread Still relevant on 4.12. Quote from Epic Staff:

This small gap is there to prevent collisions as you slide across the ground or over seems between geometry. The code tries to maintain a range between 1.9 and 2.4 units (usually the average 2.15). I'm not sure why you are seeing 0.15 units instead.

more ▼

answered Jun 13 '16 at 02:56 PM

avatar image

dx0ne
31 4 4

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
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