Raised This Month: $ Target: $400
 0% 

Math Help


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Greenberet
AMX Mod X Beta Tester
Join Date: Apr 2004
Location: Vienna
Old 06-11-2006 , 12:27  
Reply With Quote #1

atm i only know one way:

you have an triangle here.

A = Attacker
B = AIM
C = VICTIM

a = distance(aim, victim)
b = distance(attacker, victim)
c = distance(attacker, aim )

hc = distance from line to victim

so something like this could work:

s = (a+b+c)/2
area = sqrt(s *(s-a)*(s-b)*(s-c))

area = c * hc /2
hc = 2 * area / c

maybe this is not the best way, but it is a way ;)
Greenberet is offline
Send a message via ICQ to Greenberet Send a message via MSN to Greenberet
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 08:03.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode