Skip to content
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

Log Viewer doesn't work with input system #53

Open
Jacko123490 opened this issue Jul 28, 2021 · 3 comments
Open

Log Viewer doesn't work with input system #53

Jacko123490 opened this issue Jul 28, 2021 · 3 comments

Comments

@Jacko123490
Copy link

I have imported the file into my project but the calls using the 'Input' namespace isn't supported with the Unity input system. I have implemented my own fixes to the code for my personal use fine but as I am just using PC this won't work for touch-based systems and my modified version won't detect if the game is using the input system. Despite this here are the steps I took to fix it for you to get started with:

All work is done in the Reporter.cs file.
Added 'using UnityEngine.InputSystem;' to the start of the file.
Modified the isGestureDone(), isDoubleClickDone(), getDownPos(), and getDrag() functions:
- Swapped, Input.GetMouseButtonDown/Up(0) with Mouse.current.leftButton.wasPressed/RelesedThisFrame
- Swapped, Input.GetMouseButton(0) with Mouse.current.leftButton.isPressed
- Swapped, all mose position calls with Mouse.current.position.ReadValue() (using .x and .y for float outputs)
- Deleted all the if IOS or Android platform calls in these functions to remove the conflicting function calls.

Let me know if you want to see the code.

@NDark
Copy link

NDark commented Aug 6, 2021

Hi, I'm not sure I faced the same problem.
What I encountered is Input of LogViewer is mal-function on both android/ios platforms , but fine on editor/WebGL . So I can open interface (by circle gesture), i can scroll upper bar (to rightest), but un-able to tap any button or row of log .

My unity is 2018.

@Jacko123490
Copy link
Author

I feel like you might have misinterpreted my post, first of all, I am talking purely about windows/WebGL as that is what my project is on. Secondly, my issue is relating to the conflict with the default Unity Input management interface and any project using the special 'Input System'. (https://docs.unity3d.com/Packages/com.unity.inputsystem@1.0/manual/QuickStartGuide.html) If you are having a different issue maybe try posting a new issue separately instead.

@NDark
Copy link

NDark commented Aug 7, 2021

@Jacko123490 , you are correct. Will do as you said.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants