box2d and reflection from a wall

Hi!
I am leaning box2d ver 2.1a for as3
How to simulate the movement of reflection from the wall ?

Some code definitions:
Code:
//---WIDTH 640  HEIGHT 480
//---ball definition-----------------
var ballFd:b2FixtureDef = new b2FixtureDef();     
var ballBd:b2BodyDef = new b2BodyDef();
ballBd.type = b2Body.b2_dynamicBody;//b2Body.b2_kinematicBody;
ballFd.density = 1.0;
ballFd.restitution = 1;
ballFd.shape =  new b2CircleShape(5);   
ballbody = world.CreateBody(ballBd);   
ballbody.SetPosition(new b2Vec2(WIDTH/2,HEIGHT/5));

//----- left wall define-------------
var wallFd:b2FixtureDef = new b2FixtureDef();
var wallSd:b2PolygonShape = new b2PolygonShape();
var wallBd:b2BodyDef = new b2BodyDef();
           
wallSd.SetAsBox(10,WIDTH);
wallBd.position.Set(0, 0);
wallBd.type = b2Body.b2_staticBody;
wallFd.density = 1.0;
wallFd.restitution = 0;
wallFd.shape = wallSd;
wallleft = world.CreateBody(wallBd);
wallleft.SetPosition(new b2Vec2(0,0));

addEventListener(MouseEvent.CLICK, onClick);
private function onClick(e:Event):void
{      
//----ball moves to left wall----
ballbody.ApplyImpulse(new b2Vec2(-100,400), ballbody.GetPosition());
}

My questions are:
1) Why the ball don't reflect from a wall ?
2) How to organize the rebound that the angle of incidence was equal to the angle of reflection?
3) How to give the ball movement just knowing the angle?
applayImpulse requires the coordinates for the vector, which is inconvenient

Who can help me?
No any answers
Can forum dead?
Maybe the Box2d system dead ?
Set restitution of wall to 1 and let box2d handle the rest?
That's what the physics engine is for. You shoot a ball at a bouncy wall, and it'll bounce.
Could you look at the code of my as3-file attachment?
I set restitution value to 1 but ball fly through the wall
I can't understand why
this is part of your code...

Code:
wallFd.restitution = 0;
Your scales are messed up too. You're blasting the ball at the wall with the force of an atomic powered rubber band gun and it's tunneling straight through the wall. Read up on isBullet, that should help you.
John H. Uckele wrote:
Your scales are messed up too. You're blasting the ball at the wall with the force of an atomic powered rubber band gun and it's tunneling straight through the wall. Read up on isBullet, that should help you.



Ha ha ha ha ha! nice explanation 😀

Original thread: https://box2d.org/forum/viewtopic.php?t=5493