Skip to content

Fix/UI blocking pass #578

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
Mar 29, 2022
Merged

Fix/UI blocking pass #578

merged 6 commits into from
Mar 29, 2022

Conversation

jilfranco-unity
Copy link
Contributor

Description (*)

This PR is for a fix for the HUD UI buttons letting movement input through on mobile. After doing a bunch of looking through our settings, building, and testing, the one thing that works is a simple code fix. In fixed update, right before our movement input logic, I use the Event System to check if the pointer is over a game object or if there is currently a selected game object. If there is, we just return. If not, we do the movement logic.

I've also done a bit of clean up on our lobby UI, applying any overrides in the scene to the prefabs, unchecking the raycast target option on some of our graphics, and deleting some unneeded vars in the Lobby and IP UI Mediators leftover from the old lobby UI

Fixes issue(s):
Here's the Jira ticket

@jilfranco-unity jilfranco-unity added 2-Easy This PR is trivial and can be reviewed quickly 1-Needs Review PR needs attention from the assignee and reviewers priority:high type:bug Bug Report labels Mar 23, 2022
…to check if something is currently selected instead
@jilfranco-unity
Copy link
Contributor Author

Made a tiny change per some feedback from LP, instead of checking the event system to see the pointer is over a game object and if something is currently selected, now it only checks for if something is currently selected. The pointer check was a bit redundant.

A question tho, should this logic happen on all platforms? Or just mobile since the problem only seems to happen on mobile?

LPLafontaineB
LPLafontaineB previously approved these changes Mar 24, 2022
@jilfranco-unity jilfranco-unity added the 2-One More Review One review in, one to go label Mar 28, 2022
Copy link
Collaborator

@fernando-cortez fernando-cortez left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The last thing I'd add to this PR is modifying the popup window (I believe it is PopupPrefab). I can hit through the black background and hit the "Start IP" button.

Also, I don't think I was able to test, but also look into the two buttons on the top right (the exit button and the volume/quality button). There could be a scenario where you could hit through the black background and hit a lobby listed for instance.

@fernando-cortez fernando-cortez added 2-Reviewed with Comments PR requires owner's attention and removed 2-One More Review One review in, one to go labels Mar 28, 2022
@jilfranco-unity
Copy link
Contributor Author

jilfranco-unity commented Mar 29, 2022

The last thing I'd add to this PR is modifying the popup window (I believe it is PopupPrefab). I can hit through the black background and hit the "Start IP" button.

This ended up being a really simple fix, just needed to make the background of the pop up panel a raycast target so that it blocks input to other ui elements! This fixes the issue on both desktop and android--I think because it's not a physics raycast.

@fernando-cortez fernando-cortez added 3-Good to Merge and removed 1-Needs Review PR needs attention from the assignee and reviewers labels Mar 29, 2022
@jilfranco-unity jilfranco-unity merged commit 990398b into develop Mar 29, 2022
@jilfranco-unity jilfranco-unity deleted the fix/ui-blocking-pass branch March 29, 2022 17:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
2-Easy This PR is trivial and can be reviewed quickly 3-Good to Merge priority:high type:bug Bug Report
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants