Heroicphoenix000 Posted June 8, 2017 Share Posted June 8, 2017 I've learned a lot about scripting dialogue since my last post and now, one of my companions for TTW is starting to take great shape. However, there is one thing I want to do for her. I want her to have specific dialogue when I get to a certain level. Say, level 20. Is there a specific way I can script her dialogue to say some certain lines only when I level up to that level? Link to comment Share on other sites More sharing options...
dubiousintent Posted June 8, 2017 Share Posted June 8, 2017 Put a conditional "level check" in the script just as you would a "quest stage check", with your "restricted" dialog only available when the check is passed. Same basic process. It could appear when the level is reached, or only when the level has been reached and a specific quest stage has as well, depending upon how you structure the checks. -Dubious- Link to comment Share on other sites More sharing options...
Heroicphoenix000 Posted June 9, 2017 Author Share Posted June 9, 2017 Put a conditional "level check" in the script just as you would a "quest stage check", with your "restricted" dialog only available when the check is passed. Same basic process. It could appear when the level is reached, or only when the level has been reached and a specific quest stage has as well, depending upon how you structure the checks. -Dubious-Thank you very much, Dubious. :D Link to comment Share on other sites More sharing options...
Heroicphoenix000 Posted June 9, 2017 Author Share Posted June 9, 2017 Err, I apologize Dubious. I got excited, so I forgot to ask HOW exactly to do that. LOL Link to comment Share on other sites More sharing options...
dubiousintent Posted June 9, 2017 Share Posted June 9, 2017 What are you asking how to do? Determine the player level? See the "GetLevel" page of the Community GECK site. But you might want to read this post in the "Returning player current health" thread regarding the use of "player" and "PlayerRef" immediately after before trying to implement. If you are asking how to construct the conditional check, it's basically just an "IF ... THEN ... ELSE" structure: IF < condition (i.e. "PlayerRef.GetLevel > 19") is true > [THEN is implied] < do something, i.e. say your restricted dialog > ELSE < alternative something to do when false, i.e. say some ordinary dialog > ENDIF See the "Conditional Statements" section of the GECK "Scripting for Beginners" article. There are also numerous examples in the tutorials listed in the "Scripting" and "Dialog & Lip-synch" sections of the wiki "Getting started creating mods using GECK" article. If you want to have two conditions, such as level and quest stage, with one dependent upon the other occurring, then you have the secondary conditional test "nested" inside the "true" section of the primary condition. This keeps the secondary condition from unnecessarily being tested, making your script more efficient. IF < condition-1 test > IF <condition-2 test > < do something restricted to only when both tests are true > ELSE < do something not restricted to condition-2 being true > ELSE < do something not restricted to condition-1 being true > ENDIF Indentation is an important habit to get into so you keep the "nesting" organized and not lose track of the required matching IF/ELSE/ENDIF statements. You can get nesting quite deep and without indentation it is easy get lost. I am deliberately pointing you to where to find the answers instead of just writing the code for you so you can learn. But feel free to return with your code if it doesn't behave properly. We learn more from our mistakes than when the answer comes too easily. -Dubious- Link to comment Share on other sites More sharing options...
Heroicphoenix000 Posted June 9, 2017 Author Share Posted June 9, 2017 What are you asking how to do? Determine the player level? See the "GetLevel" page of the Community GECK site. But you might want to read this post in the "Returning player current health" thread regarding the use of "player" and "PlayerRef" immediately after before trying to implement. If you are asking how to construct the conditional check, it's basically just an "IF ... THEN ... ELSE" structure: IF < condition (i.e. "PlayerRef.GetLevel > 19") is true > [THEN is implied] < do something, i.e. say your restricted dialog > ELSE < alternative something to do when false, i.e. say some ordinary dialog > ENDIF See the "Conditional Statements" section of the GECK "Scripting for Beginners" article. There are also numerous examples in the tutorials listed in the "Scripting" and "Dialog & Lip-synch" sections of the wiki "Getting started creating mods using GECK" article. If you want to have two conditions, such as level and quest stage, with one dependent upon the other occurring, then you have the secondary conditional test "nested" inside the "true" section of the primary condition. This keeps the secondary condition from unnecessarily being tested, making your script more efficient. IF < condition-1 test > IF <condition-2 test > < do something restricted to only when both tests are true > ELSE < do something not restricted to condition-2 being true > ELSE < do something not restricted to condition-1 being true > ENDIF Indentation is an important habit to get into so you keep the "nesting" organized and not lose track of the required matching IF/ELSE/ENDIF statements. You can get nesting quite deep and without indentation it is easy get lost. I am deliberately pointing you to where to find the answers instead of just writing the code for you so you can learn. But feel free to return with your code if it doesn't behave properly. We learn more from our mistakes than when the answer comes too easily. -Dubious-Yeah, I should've asked for this detail in the first place. My bad. But thank you very much, this will make it much easier to figure out. TBH, your work on the nexus wiki is so detailed in of itself. I'm surprised you didn't make detailed videos on Youtube showing all of this, cause that would also help. Link to comment Share on other sites More sharing options...
dubiousintent Posted June 9, 2017 Share Posted June 9, 2017 Making videos is not in my current skill set, and frankly not something I am interested in learning. Considering that Gamerpoets and Gopher take a week or more per tutorial style video, I feel my time is better spent working on wiki pages. The level of detail I generally feel the subjects need would either make for several videos or such a long one the details would get blurred in everyone's mind unless they constantly replayed things. That is usually the reason I write the articles in the first place: more detail is needed. Maybe if I run out of subject matter. At least that is my feeling. There is nothing to prevent someone else from making videos based upon those articles. I would just have to caution them that I am constantly refining my articles; either with new information or rephrasing for better clarity in response to questions. I usually edit at least one (and often more) every day. -Dubious- Link to comment Share on other sites More sharing options...
Heroicphoenix000 Posted June 9, 2017 Author Share Posted June 9, 2017 Well, Dubious, your attention to detail is VERY amazing. How you constantly refine or update them says a lot about your devotion to the community. And I for one thank you for your efforts. It's not everyday you see someone such as yourself in a community always trying to get as much information out there so that newbie modders can make stuff for either the community or themselves personally. Link to comment Share on other sites More sharing options...
Jokerine Posted June 10, 2017 Share Posted June 10, 2017 Alternatively, you can make it a bit easier on yourself if you use GetLevel on the dialogue topic conditions. Setting it up like this will make the dialogue option only show up when the player is level 20 or higher. http://i.imgur.com/u3Uvyo4.png Hope that helps :) Link to comment Share on other sites More sharing options...
Heroicphoenix000 Posted June 10, 2017 Author Share Posted June 10, 2017 Alternatively, you can make it a bit easier on yourself if you use GetLevel on the dialogue topic conditions. Setting it up like this will make the dialogue option only show up when the player is level 20 or higher. http://i.imgur.com/u3Uvyo4.png Hope that helps :smile:That's also appreciated. Thank you very much. :D Link to comment Share on other sites More sharing options...
Recommended Posts