How to make a point-reflection ?

Hi,

i don’t know if this is the correct forum for my question, so i excuse in advance.

i do a little adroid-2D-game, where i have some random points generated first, then the user can touch one and while holding, can “draw it like a bow” and by releasing touch, shoot it around.

now when a user grabs such a point, lets call it point A, and draws back the finger, I have a nice line drawn by LineRenderer from A to the touched position (lets call it point P)… but I also want a line beeing drawn like a targeting-line, where the point A will be shot after releasing touch…

how would I calculate this point?? -.-

sorry I am a total looser @ math :confused:

two examples… first the simlier one:

… so lets say, the user touches point A at … A(0/0)
… and draws back the finger to point P(3/3)
… then the reflected point where to draw the targeting-line would be at P’(-3/-3)

… now a other one:

… so lets say, the user touches point A at … A(-2/1)
… and draws back the finger to point P(-1/-2)
… then the reflected point where to draw the targeting-line would be at P’(-3/4)

I hope you understand what I mean because I also suck @ explaining stuff -.-

please I beg for help, I struggle with this for weeks now.

just multiply the point p by -1 ig, im not the best in math

-1 * -1 is not -3 … this does not work

I think you are looking for 2A - P

The logic to this is to get from P to A is: A - P
Then add that vector to A as your starting position gives you: A - P + A

Which tidies up to 2A - P

Sounds like all you need is the opposite of the offset from the original position to the points current position(where the user drags it), do you need to apply gravity to the projectile path or something?