Back to articles
Simulated Touch With Input Swapping In Unreal Engine
NewsTools

Simulated Touch With Input Swapping In Unreal Engine

via Dev.toHaris

Problem So swapping keyboard with touch input is quite easy by default in unreal engine all you need is one function which is called ActivateTouchInterface . PlayerController->ActivateTouchInterface(TouchInterface); If you provide no touch interface it will switch your input from touch to mouse and keyboard, but our problem is that our project has pixel streaming enabled which means it always run on a remote PC. To support touch even in that scenario we have to simulate mouse as touch input, this can be done in project settings: Use Mouse for Touch You can find this setting in Engine→Input inside your project settings. With this option enabled there is now another issue at hand upon switching to keyboard at runtime will mess up your camera controls even if you turn this option off in Input Settings. We noticed this bug in our testing phase and found out that this maybe happening because of the DefaultInput Config is still set to false even if you change your bUseMouseForTouch inside th

Continue reading on Dev.to

Opens in a new tab

Read Full Article
2 views

Related Articles