So I am making a 3D game using Java 8.

The question I am to ask will not concern any of the features specific to JAva 8 though.
But if any of you have played a shooter game or simply minecraft. How do I mimic the mouse free look behavior present in all of those games? Where the mouse dissapears and its a crosshair and when you move ur mouse up, the user rotates upward to a certain point or indefintly relatively speaking.

Re: How do I do freeMouseLook in Java 80 80

1 Create a crosshair cursor
2 Set that cursor as the cursor for the component (JPanel?) that is your game's main content area
3 Use a MouseMotionListener to track the mouse movements in that component
4 Keep updating your game view to match the latest mouse position

Be a part of the DaniWeb community

We're a friendly, industry-focused community of 1.19 million developers, IT pros, digital marketers, and technology enthusiasts learning and sharing knowledge.