Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Code Snippets / [DBP] Check if a point is inside a box

Author
Message
Zotoaster
19
Years of Service
User Offline
Joined: 20th Dec 2004
Location: Scotland
Posted: 25th Sep 2007 18:42 Edited at: 25th Sep 2007 19:04
(Might work in DBC)




[Edit]

And in 3D:





The way this works is, it calculates a new position for the point assuming the angle of your box is 0, then does a simple "If x > something and x < something" etc.

Easy, but.. thinking outside the box

"It's like floating a boat on a liquid that I don't know, but I'm quite happy to drink it if I'm thirsty enough" - Me being a good programmer but sucking at computers

Login to post a reply

Server time is: 2024-11-22 18:28:12
Your offset time is: 2024-11-22 18:28:12