I am creating a Java game with collisions. I found myself stuck on the following problem.
I have got two known lines: $y$ and $i.$ $i$ is the inbound direction and $o$ the outbound direction, therefore both angles are the same. From $y$ and $i,$ I have calculated $\alpha.$ I also know the coordinates of the intersection point $(x,y).$ $y$ is not the horizontal axis. $y$ and $i$ can be any line of the format $y = ax + b.$
Could anyone help me out on getting the equation $y = ax + b$ for line $o$?


I'll use capital letters for the lines to keep the notation a bit clearer. (You used the same variable name, lowercase $y$, for one of the lines and for one of the coordinates; that's a bad idea.)
As I understand the question, you have lines $Y$ and $I$ given by $y=a_Yx+b_Y$ and $y=a_Ix+b_I$, respectively, and you want to find the line $O$ in the form $y=a_Ox+b_O$. I suspect that this is a suboptimal formulation of the problem in two respects: You can't represent vertical lines this way, and you can't reconstruct a direction from a line. (I take the arrows in the diagram and your mention of "inbound direction" and "outbound direction" as indications that what you're actually interested in is a direction and not just a line; that would make sense if you're writing a game with collisions.)
So I'll answer a different question instead, which is likely to be of more use to you; it's straightforward to transform the answer to the $y=ax+b$ format if that really is what you want. Suppose you have unit vectors $\vec r$ and $\vec s$ specifying the directions of $Y$ and $I$, respectively, and you want to find the unit vector $\vec t$ specifying the direction of $O$. Then
$$\vec t=2(\vec s\cdot \vec y)\vec y-\vec s\;.$$