x

Search in
Sort by:

Question Status:

Search help

  • Simple searches use one or more words. Separate the words with spaces (cat dog) to search cat,dog or both. Separate the words with plus signs (cat +dog) to search for items that may contain cat but must contain dog.
  • You can further refine your search on the search results page, where you can search by keywords, author, topic. These can be combined with each other. Examples
    • cat dog --matches anything with cat,dog or both
    • cat +dog --searches for cat +dog where dog is a mandatory term
    • cat -dog -- searches for cat excluding any result containing dog
    • [cats] —will restrict your search to results with topic named "cats"
    • [cats] [dogs] —will restrict your search to results with both topics, "cats", and "dogs"

Right Click Camera Control and Alt Tab

My goal is to let player control the camera when right click is held down (similar to World of Warcraft) and when right click is released, mouse cursor will show. Everything works correctly until I alt tab, after that I can only move my camera abit because my mouse hits the edge of the viewport. Any ideas how to make refocus viewport and capture mouse properly after alt tabbing?

I tried:
1. Set Focus to Game Viewport when right mouse button is pressed. It doesn't seem to work.
2. Set Input Mode Game And UI (Lock Always/Lock on Capture). I can no longer move my camera.

===================================================================

ThirdPersonCharacter has modified blueprint nodes categorized with blue highlight.
To reproduce:
1. Run the project file
2. Press play
3. Hold right click to move camera, your camera should be able to rotate more than 360 degrees and will not get blocked by viewport's edge.
4. Alt tab
5. Alt tab back to the game
6. Hold right click to move camera again, your camera will stop when cursor hits the edge of viewport.

===========================================================

Download Project: https://drive.google.com/open?id=0BxA-6ZVRJ-z1VWI5R3B0VXlobGs

Product Version: UE 4.15
Tags:
more ▼

asked Apr 24 '17 at 05:30 AM in Using UE4

avatar image

SmileyJeff
136 13 21 30

(comments are locked)
10|2000 characters needed characters left
Viewable by all users

1 answer: sort voted first

Hey SmileyJeff,

On your right mouse down you need to "set input mode game only" and the part you were missing was that the target MUST be the player controller.

Note you must also "set input mode game and ui" after you release the mouse or you wont be able to click on things once again after you get your mouse back.

Below is the screen shot:

alt text

more ▼

answered Apr 24 '17 at 08:40 AM

avatar image

Miroac
728 20 25 108

avatar image SmileyJeff Apr 24 '17 at 12:16 PM

Thank you, that worked flawlessly!

(comments are locked)
10|2000 characters needed characters left
Viewable by all users
Your answer
toggle preview:

Up to 5 attachments (including images) can be used with a maximum of 5.2 MB each and 5.2 MB total.

Follow this question

Once you sign in you will be able to subscribe for any updates here

Answers to this question