Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time [RESOLVED]

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time [RESOLVED]

Post by Interkarma »

This is a very minor issue. Sometimes when initiating dialog with an NPC, they will start on the "where is" option and dump some dialog about the top option several times in a row.

I didn't click on anything other than NPC, the talk window opened in the following way. The game otherwise keeps running normally.

There are no exceptions in the output log. A save game is attached that will hopefully help reproduce. I just need to keep opening dialog several times with different NPCs before it happens.

chatty-guy.jpg
chatty-guy.jpg (113.09 KiB) Viewed 6257 times
Attachments
SAVE377.zip
(231.34 KiB) Downloaded 237 times

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by Interkarma »

Update: I'm now unable to reproduce after closing and reopening game. I'll let you know if I can get any more detail on this one later. It's otherwise a very minor thing, just adding bug report for completeness.

User avatar
Nystul
Posts: 1501
Joined: Mon Mar 23, 2015 8:31 am

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by Nystul »

I think there is still a issue with clicks resulting in more than one click event. You remember the window close/reopen issue. I know you implemented a fix. But I still get this issue every now and then.
It might be related to this issue if it selects entries in the list. But it also could be something else.

Regarding the doubled click registration: I used the function Input.ResetInpuAxis with success earlier which also resets mouse clicks

I don't understand why it starts in the where is section though

User avatar
pango
Posts: 3347
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by pango »

This sometimes happens with inventory window when clicking on corpses too.
From time to time I loot corpses that have one of my objects (usually my lamp... or maybe that's when I notice it, because I'm suddenly out of light!)
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by Interkarma »

Yep, likely another case of input fall-through from world to UI.

I did not create a good design for cleanly separating input handling between world and UI. What I thought was adequate at the time turned out to have some failings. Will fix this over time. It's also one of those lessons learned to take into my next project.

User avatar
pango
Posts: 3347
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by pango »

I haven't checked the code so it may be easier said than done but, could interface elements be triggered on "mouse up" events rather than "mouse down" events?
From the little GUI work I did (in Windows 3.x days :lol: ) that was the behavior of buttons, and barely anybody notices...
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
pango
Posts: 3347
Joined: Wed Jul 18, 2018 6:14 pm
Location: France
Contact:

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by pango »

Code: Select all

diff --git a/Assets/Scripts/Game/PlayerActivate.cs b/Assets/Scripts/Game/PlayerActivate.cs
index 20679db2..ee61a512 100644
--- a/Assets/Scripts/Game/PlayerActivate.cs
+++ b/Assets/Scripts/Game/PlayerActivate.cs
@@ -128,7 +128,7 @@ namespace DaggerfallWorkshop.Game
             }
 
             // Fire ray into scene
-            if (InputManager.Instance.ActionStarted(InputManager.Actions.ActivateCenterObject))
+            if (InputManager.Instance.ActionComplete(InputManager.Actions.ActivateCenterObject))
             {
                 // TODO: Clean all this up
 
or something like that. It doesn't closely emulate classic, but seems very effective
Mastodon: @pango@fosstodon.org
When a measure becomes a target, it ceases to be a good measure.
-- Charles Goodhart

User avatar
Interkarma
Posts: 7236
Joined: Sun Mar 22, 2015 1:51 am

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by Interkarma »

Thank you, but I'd rather resolve this a different way than invert the input sampling for button presses. I'll loop back to this bug report later now it's been identified as input fall-through. Cheers. :)

User avatar
mikeprichard
Posts: 1037
Joined: Sun Feb 19, 2017 6:49 pm

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by mikeprichard »

Although the same random wandering NPC ("Rodyctor Ashham") as appears in the top screenshot didn't show up for me when I loaded the attached save, I can't reproduce this with any other NPC in Win 7 as of latest build 0.8.6. Has the underlying input fall-through issue been resolved?

User avatar
Jay_H
Posts: 4061
Joined: Tue Aug 25, 2015 1:54 am
Contact:

Re: Live Code as of 25-June-18 - Talk Window > Where Is Directions Repeating Several Time

Post by Jay_H »

This still happens to me (Linux 64bit 0.8.6).

Locked