Inside3D!
     

Distance formula and measurement calculations

 
Post new topic   Reply to topic    Inside3d Forums Forum Index -> QuakeC Programming
View previous topic :: View next topic  
Author Message
Chris



Joined: 05 Aug 2006
Posts: 78

PostPosted: Mon Oct 09, 2006 5:22 am    Post subject: Distance formula and measurement calculations Reply with quote

http://ru1337.com/forums/viewtopic.php?t=17

Has a few measurement types. May or may not be useful.
Back to top
View user's profile Send private message MSN Messenger
Sajt



Joined: 16 Oct 2004
Posts: 1026

PostPosted: Mon Oct 09, 2006 10:16 pm    Post subject: Reply with quote

That's a lot of lines of code for just doing 'result = vlen(trace_endpos - self.origin) Surprised

Also your scale seems to be odd. The accepted scale is 8 quake units = 12 inches, yours seems to be 6 inches.

Other than that it's nifty I guess Smile
_________________
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
Back to top
View user's profile Send private message
Chris



Joined: 05 Aug 2006
Posts: 78

PostPosted: Mon Oct 09, 2006 11:21 pm    Post subject: Reply with quote

First site i saw it said 16 qu = 1ft, i guess its actually closer to 8. Also for mathematical history purposes i used the real 3d distance formula. So ya I'll change it from devinding by 16 to 8. Also changed the inches from 1 1/3 to 2/3.

Number wise it looked better by 16, mainly because the quake guy hauls ass from 0-60mph when running and by 16 the numbers look more realistic in terms of distance.

Back to top
View user's profile Send private message MSN Messenger
Urre



Joined: 05 Nov 2004
Posts: 1073
Location: Sweden

PostPosted: Tue Oct 10, 2006 11:50 am    Post subject: Reply with quote

Correct measurements are 8 qu = 1 foot, or 12 inch. 1 qu is 1.5 inches. Ask feh in #darkplaces, he knows Wink
_________________
Look out for Twigboy
Back to top
View user's profile Send private message Visit poster's website
Sajt



Joined: 16 Oct 2004
Posts: 1026

PostPosted: Tue Oct 10, 2006 7:17 pm    Post subject: Reply with quote

Well, feh's 8 qu = 12 inches is the most accepted one when you're forced to accept a scale, but usually people just leave them at quake units because Quake has no consistent scale anyway.

The 'real' distance stuff you use is the same as vlen(trace_endpos - self.origin).
_________________
F. A. Špork, an enlightened nobleman and a great patron of art, had a stately Baroque spa complex built on the banks of the River Labe.
Back to top
View user's profile Send private message
Spike



Joined: 05 Nov 2004
Posts: 944
Location: UK

PostPosted: Wed Oct 11, 2006 5:26 pm    Post subject: Reply with quote

I demand leagues!

But yeah, quakeguy is 32 qu wide and 52 high, so he's pretty fat. quakeunits clearly have a different scale in different axis...


Oh, and regarding that rotating doors tut, I think you have to use self.ltime rather than time if you want velocity / avelocity to work as predicted. Something about movetype_push being absurd...
_________________
What's a signature?
Back to top
View user's profile Send private message Visit poster's website
FrikaC
Site Admin


Joined: 08 Oct 2004
Posts: 947

PostPosted: Wed Oct 11, 2006 7:27 pm    Post subject: Reply with quote

Must have cubits.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic    Inside3d Forums Forum Index -> QuakeC Programming All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2004 phpBB Group