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

Unselectable Dialogue Choice when meeting random NPC #77031

Closed
Maleclypse opened this issue Oct 14, 2024 · 6 comments · Fixed by #77061
Closed

Unselectable Dialogue Choice when meeting random NPC #77031

Maleclypse opened this issue Oct 14, 2024 · 6 comments · Fixed by #77061
Labels
(S2 - Confirmed) Bug that's been confirmed to exist

Comments

@Maleclypse
Copy link
Member

Maleclypse commented Oct 14, 2024

Describe the bug

Cannot select dialogue choice A.

Attach save file

Benton Heights-trimmed.tar.gz

Steps to reproduce

Meet a scavenger who produces this dialogue choice

Expected behavior

Some kind of dialogue. It appears to have it

{
    "type": "talk_topic",
    "id": "TALK_NPC_EVAC_SURVIVOR",
    "dynamic_line": {
      "compare_string": [ "yes", { "npc_val": "dialogue_first_meeting_knows_u" } ],
      "yes": "<greet>.",
      "no": "Don't come any closer!"
    },
    "speaker_effect": { "effect": { "npc_add_var": "dialogue_first_meeting_knows_u", "value": "yes" } },
    "responses": [
      {
        "text": "What's wrong?",
        "topic": "TALK_NPC_EVAC_SURVIVOR_CALM",
        "condition": { "not": { "compare_string": [ "yes", { "npc_val": "dialogue_first_meeting_knows_u" } ] } }
      },

I'm just not receiving it.

Screenshots

unselectable dialogue

Versions and configuration

  • OS: Windows
    • OS Version: 10.0.22631.4317 (23H2)
  • Game Version: cdda-experimental-2024-10-12-0722 b2e7940 [64-bit]
  • Graphics Version: Tiles
  • Game Language: System language []
  • Mods loaded: [
    Dark Days Ahead [dda],
    Disable NPC Needs [no_npc_food],
    Portal Storms Ignore NPCs [personal_portal_storms],
    Slowdown Fungal Growth [no_fungal_growth]
    ]

Additional context

No response

@Maleclypse Maleclypse added the (S1 - Need confirmation) Report waiting on confirmation of reproducibility label Oct 14, 2024
@PatrikLundell
Copy link
Contributor

I have problems with this report:

  • I don't quite understand what the issue is. It appears to be a failure to select the highlighted response in the image, but I'm not sure.
  • The save appears to be useless for error reproduction purposes, as the conditions required for that response are that the PC hasn't spoken to the NPC previously, and that has already happened in the save (are there debug means to "reset" NPC dialog states?).
    Might of course be a case of limited comprehension on my part...

@Maleclypse
Copy link
Member Author

I have problems with this report:

  • I don't quite understand what the issue is. It appears to be a failure to select the highlighted response in the image, but I'm not sure.

  • The save appears to be useless for error reproduction purposes, as the conditions required for that response are that the PC hasn't spoken to the NPC previously, and that has already happened in the save (are there debug means to "reset" NPC dialog states?).

Might of course be a case of limited comprehension on my part...

I included the save in case anyone knew how to reset the npc vars but I don't know of a way to do so. Yes, I tried to select dialogue A repeatedly and the screen blinked but never moved to next dialogue. Selected B and dialogue ended and when I spoke to the NPC a second time it gave me dialogue similar to if not exactly what should have gone to dialogue A.

@Maleclypse
Copy link
Member Author

I think spawning overmap special guaranteed to drop an NC_SCAVENGER NPC for the first time any game should be replicable.

@PatrikLundell
Copy link
Contributor

PatrikLundell commented Oct 14, 2024

/Confirmed

I'm not sure if there's a single or multiple issues here.
I debug spawned an occupied scrap yard and teleported to it, followed by talking to the scrapper. The following dialog had a different "a" response (Nice to meet you.)", which wasn't accepted when pressing <RETURN> on the choice, but WAS accepted when I pressed "a" on the keyboard. Other choices I tried thereafter all worked with the <RETURN> key as normal.

I suspect it's something wrong with the state of dialogs, rather than something with the JSON dialogs themselves, although that's just a guess.

I then spawned an Occupied Lumbermill location, walked up to it and talked to the closest NPC, getting the same conversation options as I got for the scrapper, and again had fail to accept the "a" dialog choice, again getting it to work with the letter "a", and a second character in the same location presenting the same choices and again not accepting <RETURN> as an input.

Thus, it seems there's some kind of input option bug blocking the standard <RETURN> but accepting the letter input alternative, which thus can be used as a work around. I don't use mouse controls, and leave it to those who do to test out that, if they're interested.

@github-actions github-actions bot added (S2 - Confirmed) Bug that's been confirmed to exist and removed (S1 - Need confirmation) Report waiting on confirmation of reproducibility labels Oct 14, 2024
@ShnitzelX2
Copy link
Contributor

I would guess it's because of #76804, I'll take a look tonight. Pretty sure I encountered this bug while I was working on it, but I thought I'd fixed it.

@ShnitzelX2
Copy link
Contributor

This is indeed the case, it's two issues:

  1. TALK_NPC_EVAC_SURVIVOR has a dynamic line that changes "dialogue_first_meeting_knows_u", which determines the responses' conditionals. So in this case, the conditional was true when added, then false afterwards, which is why you can't confirm it with RETURN. However...
  2. the hotkeys don't check for conditionals, so you can select them anyways when you shouldn't be able to.

The reason I didn't catch these is because I was mostly testing in debug mode, where conditionals are ignored, but it's an easy fix.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
(S2 - Confirmed) Bug that's been confirmed to exist
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants