Mar 28, 2013 at 8:43 PM
Edited Mar 28, 2013 at 9:23 PM
Thanks for reply.
Ok, I checked your advice and make up a simple test.
In PhysicsSprite object is only one event which have something in common with collisions.
It's called "Collision". This is where I fire up my pice of code.
To test it I set up a RestitutionCoefficient (bouncing) to 0.0 and do:
In your thesis this will be 0 = -1 * 0 because event is fired up after bounce and bounce makes all forces to 0. (when we're sending object only on Y axis)
But this makes object to bounce from wall with 100% strength.
Setting RestitutionCoefficient to 1.0 give the same.
I really appreciating your help but this one won't work or I am doing something wrong.
It still bugs me why after changing positions, changing LinearVelocity to old value with * -1 works and without not.
I've tried out:
var vector = new Vector2(0,0); //Takes object to center of screen.
But it do not work either.
It still sends object after teleportation in wrong direction. (no matter if i multiply LinearVelocity by -1 or not)