IOCT Masters in Creative Technogies
Major Project
An augmented reality game based on "Breakout"

Saturday 14 June 2008

Collision detection: Right border

x1=maximum x - ball position x – ball radius










t=x1/velx
y1=t*vely
ball position x=previous ball position x + x1
ball position y=previous ball position y + y1
velx=-velx
ball position x=ball position x + (1-t)* velx
ball position y=ball position y + (1-t)* vely