Jump to content

Character pass throught geometry


YouGroove
 Share

Recommended Posts

The nil entity bug made i couldn't have a map, but i made a new one :

 

Just go forward and backward with the character against the wall and the cube, when you reach the wall quickly press backward to go bacl to the cube in the center , when you collide with it again press quickly the key to go forward to the wall.

 

Repaeating that you will have the character going throught cube or wall.

collision.jpg

 

 

How to test :

- Create a new level

- dezip Collision.map on your map folder

- move 3Dperson.lua to Scripts/Objects/Player

Run the game.

Maps.zip

Stop toying and make games

Link to comment
Share on other sites

In the same map i made the center cube lot more bigger ,and going backward full speed with the character and also turning a little at same time i got it going throught all geometry.

collision3.jpg

 

Once it get throught geometry, it seems it don't collide anymore with walls also.

Stop toying and make games

Link to comment
Share on other sites

That's not surprising. He's moving very fast, so fast that he passes through the wall in one physics frame.

sc1.png

 

Also, you should not multiply the walk speed by Time:GetSpeed(), as the physics simulation runs at a constant framerate.

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

In this situation I would do the following:

  • When the power slide move starts, hide the character controller and unhide a sphere, or a box with zero friction. Make sure swept collision is enabled for this.
  • Push this object with forces or SetVelocity().
  • Once the slide is over, hide the object and unhide the character controller, repositioning it to be where the swept body stopped at.

  • Upvote 1

My job is to make tools you love, with the features you want, and performance you can't live without.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...