Jump to content
Search In
  • More options...
Find results that contain...
Find results in...

Simple way to remove body that are out of the world?


Recommended Posts

EntityDistance() works on the origin of the entity, so that wouldn't be accurate with such a huge plane.

Since the world is just a huge box, all you need is to check if one of the coordinates is near the size of the world in that direction.

You could also make a physics box and scale it so it is more or less a plane. Then use the collision callback to free any entity that collides with it. Do that for all 6 sides and you have it. Oh and make sure the physics boxes are inside the world, otherwise it won't work.

Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

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.

Facebook Twitter Youtube Github Steam
  • Create New...