This is more of a general math question than a BYOND-related one, so I felt that it belonged in the Off-Topic area.
Here is the situation:
There is a character at the coordinates (50,50), facing 0 degrees (due north). There is an object on the map at (60,40). How can I calculate if the object is within the character's line-of-sight (90 degrees). I've illustrated this problem at: www.geocities.com/serminacle/problem.bmp (Geocities doesn't seem to like direct links :-x).
My question is: what equation can get me the angle that the object is at in relation to the character?
If any clarification is needed, be sure to ask. I know that I'm not the best at explaining things. :)
Apr 18 2003, 4:18 pm