Playmaker Forum

PlayMaker Help & Tips => PlayMaker Help => Topic started by: westingtyler on August 27, 2018, 06:20:49 PM

Title: How to Detect When a UI Input Field is Active and Freeze Controls?
Post by: westingtyler on August 27, 2018, 06:20:49 PM
When players click on the input field and start typing, the key-based controls still go wacky and operate normally, when they should be frozen.

I've just started trying the UGUI, so I am curious how to have something that checks if the field is active each frame, and keep other controls disabled during this time.

Here is a video of the problem. Check at the 8:17 mark.


Title: Re: How to Detect When a UI Input Field is Active and Freeze Controls?
Post by: westingtyler on August 27, 2018, 10:21:13 PM
I've solved it! it turns out there's a Set and Get Property feature for Input Field objects: IsFocused. Just get that bool, and prevent other commands that attempt to execute, until IsFocused bool is false. Get/Set Property is super powerful. So much to learn!
Title: Re: How to Detect When a UI Input Field is Active and Freeze Controls?
Post by: jeanfabre on August 28, 2018, 12:51:55 AM
Hi,

Cool, it's good that you found your way out of this, but be aware there is a dedicated action for this: UiInputFieldGetIsFocused

 Bye,

 Jean