I'd say you should not rotate the ship itself, rotate the whole world (or the coordinate system) so that the ship is again in the same orientation as in the first image. In the first image the ship points into the diretion of $a = (-1,0)^t$ (The $^t$ means just that I wrote a row vector but I mean a column vector.) In the 2nd image it is roughly in direction of $b = \frac{1}{\sqrt{2}} (-1,1)^t$. The angle between those is $\alpha = \cos^{-1}\left( \frac{\langle a,b\rangle}{\vert a \vert \cdot \vert b \vert} \right) $ where $\langle a, b \rangle = a_1b_1+a_2b_2$ is the standard scalar product of two 2-dimensional vectors, and $\vert a \vert = \sqrt{a_1^2+a_2^2}$ is the length (norm) of the vector. Now for rotating vectors we can use a rotation matrix:
$$ v_{rot} = \begin{pmatrix} \cos(\alpha) & -\sin(\alpha) \\ \sin(\alpha) & \cos(\alpha)\end{pmatrix} \cdot v = \begin{pmatrix} \cos(\alpha) v_1 - \sin(\alpha) v_2 \\ \sin(\alpha) v_1 + \cos(\alpha) v_2\end{pmatrix}$$
So in our case $$ a = \begin{pmatrix} \cos(\alpha) & -\sin(\alpha) \\ \sin(\alpha) & \cos(\alpha)\end{pmatrix} \cdot b = \begin{pmatrix} \cos(\alpha) b_1 - \sin(\alpha) b_2 \\ \sin(\alpha) b_1 + \cos(\alpha) b_2\end{pmatrix} = \begin{pmatrix} \frac{1}{\sqrt{2}} \frac{-1}{\sqrt{2}} - \frac{1}{\sqrt{2}} \frac{1}{\sqrt{2}} \\ \frac{1}{\sqrt{2}}\frac{-1}{\sqrt{2}}+\frac{1}{\sqrt{2}}\frac{1}{\sqrt{2}}\end{pmatrix} = \begin{pmatrix} -1 \\ 0 \end{pmatrix}$$
If you now have the true distance vector $d = (d_1, d_2)$ between the two ships, you can apply the same rotation to $d$ and get $d_{rot}$ and then apply your normal collision check on the vector $d_{rot}$, so:
$$ d_{rot} = \begin{pmatrix} \cos(\alpha) & -\sin(\alpha) \\ \sin(\alpha) & \cos(\alpha)\end{pmatrix} \cdot d = \begin{pmatrix} \cos(\alpha) d_1 - \sin(\alpha) d_2 \\ \sin(\alpha) d_1 + \cos(\alpha) d_2\end{pmatrix} $$
PS: If the two ships are not in a nice right angle relative to each other, I'd calculate the four corners of the box of one ship (and not the distance which is - I assume - just the distance to the center of each ship), and check whether they are within the box of the other ship using the mentioned method.
UPDATE: Ah ok, I did not know about your knowledge. I now assume that you know about basic trigonometry ($\sin \cos \tan$) You can conventionally imagine vectors in 2d ord 3d, now I simplyfy things: Lets talk about 2d: A vector is basically a point in space: A vector has 2 coordinates, one in x-direction one in y-direction, for example $a = (3,5)$. The thing is when you call something a vector, you can do things you cannot do with points: You can for example multiply a vector by a value: $5 \cdot (-1,4) = (-5,20)$ or $-0.2\cdot (20,0) = (-4,0)$ (That means you strech a vector by that amount). You can also add vectors: Like $(2,5)+(-1,2) = (1,7)$ (Make a drawing: You can interpret vectors as arows that begin in $(0,0)$ and end with the head of the arrows in the given coordinates. Adding two vectors means appending one vectors 'tail' to the others head.)
Then we can talk about the length (a.k.a. norm indicated by $||$ around the vector.) of a vector. Thats simple: You use the pythagoras theorem: so if $a = (3,4)$ then $|a| = |(3,4)| = \sqrt(3^2+4^2)$.
Now the bit more challenging part: The matrices (singular 'matrix') are in our case 2x2 tables that represent a function that maps one 2d-coordinate system to another 2d-coordinate system. But this mapping has special properties, the so called linearity for example parallel lines will be still parallel after applying that mapping. That means basically you can use matrices to stretch the coordinate system in any direction or rotate it (or combine those two). If you now have a vector in the first coordinate system, you have to multiply it with the matrix, to get the coordinates of the vector in the second coordinate system.
But how can you multiply a 2x2 table with a vector?
For this purpose we do conventionally write the vectors vertically and not horizontally: $(1,3) = \begin{pmatrix} 1 \\ 3 \end{pmatrix}$ (The horizontal way is just convenient for writing the vectors within text but the vertical way is more convenient when calculating.)
So we have a matrix (normally written in big letters) $A = \begin{pmatrix} a & b \\ c & d \end{pmatrix}$ where $a,b,c,d$ are real values (like $0.5,100,-2.1345123,\sqrt{2}$)
Now we have a vector $v = (v_1 , v_2) = \begin{pmatrix} v_1 \\ v_2 \end{pmatrix}$ that we want to map from the first oen to the second coordinate system. The mapped version of it in the second coordinate system I now call $w = (w_1 , w_2) = \begin{pmatrix} w_1 \\ w_2 \end{pmatrix}$. Now lets look how we multiply the matrix with the vector:
$$\begin{pmatrix} w_1 \\ w_2 \end{pmatrix} = w = A\cdot v = \begin{pmatrix} a & b \\ c & d \end{pmatrix} \cdot \begin{pmatrix} v_1 \\ v_2 \end{pmatrix} = \begin{pmatrix} a \cdot v_1 + b \cdot v_2 \\ c \cdot v_1 + d \cdot v_2 \end{pmatrix}$$
So now the new x-coordinate is $w_1 = a \cdot v_1 + b \cdot v_2$ and the new y-coordinate is $w_2 = c \cdot v_1 + d \cdot v_2$.
Now the last thing we need is calculating the angle between two vectors: If you have two vectors $a$ and $b$ you can construct the angle as follows: If you draw the points with the same coordinates as $a$ and $b$ and connect each point with a straight line with the point $(0,0)$ you can measure the angle between the two lines at $(0,0)$. This is the angle between the vectors. This is where the so called scalar product comes in: Thats a 'product' that 'multiplies' two vectors and returns a scalar value (sometimes also called 'dot product'. It is defined like follows: $\langle a , b \rangle = a_1\cdot b_1 + a_2 \cdot b_2$. It happens that if you divide that value by the length of both vectors, you get the cosine of the angle between those two: $\frac{\langle a , b\rangle}{|a|\cdot|b|} = \cos(\alpha)$ So if we have two vectors of the same length and want to determine how much we have to turn one (the pivot will always be $(0,0)$) to get the second one, we can solve this equation for $\alpha$. So if you now plug $\alpha$ into the rotation matrix you will get that exact mapping that rotates the whole coordinate system exactly that amount. That means if you now multiply the first vector with that matrix, you will get the rotated vector, the second one. (Thats what I have written first in the answer with the examples $a = (-1,0)$ and $b = \frac{1}{\sqrt{2}} (-1,1)$.
I know that has been a minimalist introduction to calculating with vectors. It is a pretty big topic but also a fun and useful one especially when you are into programming / games. I'd absolutely like to give you a recommendation for a book or a web resource for getting into this, but I know nothing like this in english. I hope that helped (and motivated) you.