I'm programming a game, in which you move the rocket with the mouse up and down, that means the x-coordinate is always the same. When you press space a laser shot should come out of the rocket. How can I get the y-coordinate of the rocket in the laser shot class?
