This is easy to obtain because it does not matter much how the opponent moves.
If you are playing as White, the King is on e1 and the Rook is on a1, these 2 pieces will be the ones that take part in the castling. (same applies for Black just with e8 and a8 respectively)
The rules of castling are as follows: You cannot castle if your king is in check
You must not have moved the king and rook from their starting positions.
You cannot move the king through squares which are under attack from enemy pieces.
You cannot move the king into check.
You must have no pieces in between the king and rook.
That being said, you must move the Queen on d1, the bishop on c1, the knight on b1.
Then you move the king to c1 then the rook will automatically to d1.
(for Black, move the Queen on d8, the bishop on c8, the knight on b8. Move king to c8)
The trophy will then unlock.
I did this trophy in a tournament game but it should work in an exhibition game aswell.