Dialogue.ecf question

Discussion in 'General Discussion' started by Alhira_K, Oct 18, 2020.

  1. Alhira_K

    Alhira_K Captain

    Joined:
    Jan 16, 2017
    Messages:
    287
    Likes Received:
    379
    Hello.

    I´m currently tinkering around with the dialogue system. So far i got most stuff. I´m running into two little issues though.

    First off, i would like to have a dialogue option only be available after another dialogue with another npc has been finished.

    Second off, i would like to remove "old" dialogue so once i am further into a quest line i do not have to read the stuff from earlier before.

    For Example. I want to have "Dialogue A" with "Npc A" who sends me to have a "Dialogue B" with "Npc B" who sends me eventually back to have "Dialogue C" with "Npc A". And the first conversation with "Npc A" should not be seen when coming for the second conversation.

    I have looked through the dialogue.ecf and .csv of both vanilla and project eden but i haven´t found what i was looking for. Most likely because i don´t know what to look for. Only other thing coming to my mind would be accomplishing it via the PDA system but i haven´t touched it yet.

    EDIT: And lol?
    [​IMG]
     
    #1
  2. krosbonez

    krosbonez Lieutenant

    Joined:
    Sep 30, 2020
    Messages:
    62
    Likes Received:
    91
    I have not tried this with 2 NPCs but I have done it with one. Get misssion (dialog1) do mission and return (dialog2). Dialog 1 is only available the first time and does not repeat. I am using a combination of the eWCCT (dialog and token setup) and eWPDA (PDA setup) though. But what you are explaining sounds doable. I will try to set that up and test it.
     
    #2
    Alhira_K likes this.
  3. ravien_ff

    ravien_ff Rear Admiral

    Joined:
    Oct 22, 2017
    Messages:
    6,274
    Likes Received:
    11,936
    Yes you can do this using variables. Check the example file or the hints in the web tool. Just set a variable then use nextif or optionif to control what dialog and options players see based on who they have talked to previously.
    Remember to use the correct variable types so they can be read by other dialog start states.
     
    #3
    Alhira_K likes this.
  4. Alhira_K

    Alhira_K Captain

    Joined:
    Jan 16, 2017
    Messages:
    287
    Likes Received:
    379
    Awesome, thx. I haven´t really touched eWCCT as i just started writing the dialogues by myself and have not touched WPDA as i have not tinkered with the pda system yet. Everything for now is config based. Should do it though for hints on how to use stuff.

    I initially tried using TalkCount for that but as i have no programming experience i am sure i am failing at syntax. I tried to look more at the example in the config file but i guess i still do something wrong.

    Code:
    { +Dialogue Name: Terminal_2
      NPCName: dialogue_ALb03
      Variable_1: "TalkCount", param1: dbplayerpoi_int
      Output: dialogue_ALb04
      Option_1: dialogue_ALb05
      OptionNext_1: Terminal_3
      OptionIf_1: "HasItem('Token', 1, 4101)"
      Option_2: dialogue_ALb06
      OptionNext_2: Terminal_5
      OptionIf_2: "HasItem('Token', 1, 4103) && HasItem('Token', 1, 4104)"
      Option_3: dialogue_ALb07
      OptionNext_3: Terminal_7
      OptionIf_3: "HasItem('Token', 1, 4105)"
      Option_4: dialogue_ALb12
      OptionNext_4: Terminal_9
      NextIf_4: "TalkCount = 3"
      Option_5: dialogue_ALb29
      OptionNext_5: Terminal_17
      OptionIf_5: "HasItem('Token', 1, 4106)"
      Option_6: dialogue_ALb13
      OptionNext_6: End
    }
    And i use execute in the respective dialogues to raise TalkCount just like in the config example.

    Execute_1: "TalkCount = TalkCount + 1"

    My intention is to build up a TalkCount of 3 with the 3 options before. But option 4 is visible right from the beginning and the dialogue can be continued this tree down.
     
    #4
  5. RexXxuS

    RexXxuS Rear Admiral

    Joined:
    Jan 31, 2016
    Messages:
    859
    Likes Received:
    1,434
    Hello,
    first of all, if you want to compare something, you have to use 2 equal signs. Example:
    NextIf_4: "TalkCount = 3" (throws an exception)
    needs to be
    NextIf_4: "TalkCount == 3"


    I created a Tutorial video series from very beginning, from scratch to the end. PDA + Dialogue + POI + Mission + Universe. In case you are interested, here is at least the Dialogue part:


    It is not exactly your use case but after watching, I think you will see how you can achieve your task easily.
     
    #5
    krosbonez, Alhira_K and ravien_ff like this.
  6. ravien_ff

    ravien_ff Rear Admiral

    Joined:
    Oct 22, 2017
    Messages:
    6,274
    Likes Received:
    11,936
    In your example you need an OptionIf_4 instead of a NextIf_4. That should then work.
    Also keep in mind that the dbplayerpoi variables are specific to that specific POI. If that is what you want then that works, but if you want the variable to be accessible by any dialog no matter which POI the player is at, then use:
    dbplayer_int: this var holds the same amount for this player in all dialogues
     
    #6
    Alhira_K and RexXxuS like this.
  7. Alhira_K

    Alhira_K Captain

    Joined:
    Jan 16, 2017
    Messages:
    287
    Likes Received:
    379
    I already tried that. Same result, it makes no difference.

    OptionIf_4 makes the dialogue option disappear but it doesn´t appear when i turn in the other three tasks.
    In this case dbplayerpoi is alright.
     
    #7
    Last edited: Oct 21, 2020

Share This Page