Jump to content

Recommended Posts

Posted

Could it be possible and how in LE3 :

The player could make appear some basic physic shape like box, sphere,cylinder in front of him in the scene, it is possible to detect if it is not enought room to create the physic shape ?

Like near a wall you can't create it, on in a small room if it is not enought space ?

Stop toying and make games

Posted
If you know the AABB dimensions of the shape you want to make, then you can easily do some basic math to see if it would fit.

The problem how can you calculate AABB oriented box collision against a complex model collision that could be the level ?

You would have to go throught all polygons of level and check if one or none intersect the AABB box.

 

Ok i found something perhaps simple and effective : RAYCASTING

-Just calculate 8 cube points non oriented bounding box of geometry to create (cube,cylinder, any shape)

- Scale a bit the cube more bigger (security safe collision)

- call raycasting on each edges of that bounding cube

If something collides with one or more edgeof the bounding cube , you can't create your geometry caus there is collision.

 

Sometimes asking brings the response.

Stop toying and make games

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.

×
×
  • Create New...