Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

2D Vector bullshit

Name: Anonymous 2008-11-14 6:04

I've got 2 points (ie. X,Y vectors), and I need to find out the angle (degrees°) between them, so I can move an object which is at one of the points towards the other point.

How do I calculate the degrees plz???

Name: Anonymous 2008-11-14 6:10

lrn2math

Name: Anonymous 2008-11-14 6:15

Degrees suck balls anyway, everyone uses radians.

Name: Anonymous 2008-11-14 6:23

HINT: Angular coefficients are given by the quotient y/x, where x is the horizontal coordinate and y is the vertical one.

Next step to you, anon.

Name: Anonymous 2008-11-14 6:54

theta = |arctan(x0) - arctan(x1)|

Name: Anonymous 2008-11-14 7:14

USE THE POWER OF MIGHTY SINE

Name: Anonymous 2008-11-14 7:31

There is no angle "between" two arbitrary points.  There can always be a straight line segment connecting them.

Name: Anonymous 2008-11-14 7:33

>>7
I've got 2 points (ie. X,Y vectors)

You are as dumb as OP, congratulations

Name: Anonymous 2008-11-14 7:36

>>8
fuuuuu

Name: Anonymous 2008-11-14 7:45

USE THE FUCKING DOT PRODUCT

Name: Anonymous 2008-11-14 10:31

USE THE FUCKING CROSS PRODUCT

Name: Anonymous 2008-11-14 10:36

USE THE FUCKING PROJECTION

Name: Anonymous 2008-11-14 10:36

USE THE FUCKING MATRIX MULTIPLY

Name: Anonymous 2008-11-14 10:38

USE THE FUCKING DETERMINANT

Name: Anonymous 2008-11-14 10:39

USE THE FUCKING EIGENVALUES

Name: Anonymous 2008-11-14 10:39

USE THE FUCKING TRANSPOSE

Name: Anonymous 2008-11-14 10:40

USE THE FUCKING ROW REDUCTION

Name: Anonymous 2008-11-14 10:51

USE THE FUCKING TENSOR PRODUCT

Name: Anonymous 2008-11-14 11:09

USE THE FUCKING DIRECTION COSINES

Name: Anonymous 2008-11-14 11:11

USE THE FUCKING addition

Name: Anonymous 2008-11-14 11:19

USE THE FUCKING QUATERNION NORM

Name: Anonymous 2008-11-14 13:30

USE THE FUCKING FORCE LUkE

Name: Anonymous 2008-11-14 14:59

USE THE FUCKING QUADRATIC FORMULA

Name: Anonymous 2008-11-14 16:20


the proper way to do it isa*b=|a||b|cos(YOURFUCKINGANGLEHERE)to move away from vector a in every direction till it equals b

Name: Anonymous 2008-11-14 19:07

USE THE FUCKING FORCED INDENTATION

Name: Anonymous 2008-11-14 19:18

USE THE FUCKING

Name: Anonymous 2008-11-14 20:07

FUCK THE USING

Name: Anonymous 2008-11-14 22:29

THE USING, FUCK

Name: Anonymous 2008-11-14 23:47

STOP USING DRUGS

Name: Anonymous 2008-11-14 23:54

USE THE FUCKING POLAR COORDINATES

Name: Anonymous 2008-11-15 2:01

USE THE FUCKING LAGRANGE POLYNOMINALS

Name: Anonymous 2008-11-15 3:34

USE THE FUCKING HAMILTONIAN

Name: Anonymous 2008-11-15 7:05

USE THE FUCKING GNIKCUF ETH ESU

Name: HMA MEME FAN 2008-11-15 7:27

HAX MY FUCKING ANUS

Name: Anonymous 2008-11-15 8:36

READ THE FUCKING SICP

Name: Anonymous 2008-11-15 8:40

'hax my anus' has never been a meme.

Name: noobular 2008-11-15 11:57

>>7
fuck.  ok so this is some of my codez:


void Object_t::Move()
{
     Accel.x = thrust * cos(DEG2RAD(headingDegs));
     Accel.y = thrust * sin(DEG2RAD(headingDegs));

     Vector += Velocity;
}


This will move the object's position (ie. Object_t.Vector) towards another 2D Vector, and the direction is based on headingDegs.  If headingDegs=0 it will go straight right, if headingDegs=90 it goes 90° from that point (ie. straight down) etc.

I just need to figure out what headingDegs should be based on my current location (Vector) and my target vector.

Name: Anonymous 2008-11-15 12:21

>>10-23,25-27,29-35
same person.

Name: Anonymous 2008-11-15 14:00

Name: Anonymous 2008-11-15 14:03

>>40
same person.

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List