Jump to content

Help: distance from Xmarker for ambient banter


McFearo

Recommended Posts

I'm using Budong's script for getting a companion to say location-based ambient chatter at random intervals. One line of dialogue is meant to play in Jacobstown, so instead of setting the condition for this line to "GetIsInCell" because that only allows for interior cells like the lodge, I'm using "GetDistance" paired with an XMarker. Hopefully this will work, but I'm wondering what distance from the XMarker I should set for the condition, so that he has a chance of saying his line anywhere inside that exterior cell. I don't want to make it too small, so that there's a higher likelihood that when the script's random chance for a dialogue line pops he's not near enough to the marker to generate his line so that it's harder to get it, but I don't want to make the distance so big that it can pop too far away from Jacobstown. About how big is an average exterior cell? If I set the distance to that amount and place the Xmarker roughly in the middle of the Jacobstown cell would that do the trick do you think?

Link to comment
Share on other sites

As an additional question, is there such a thing as too many conditions? I have another dialogue I just set up that checks GetDeadCount on each of the crucified survivors in Nipton to see if it's >= 1, in addition to the usual GetIsID MyCharacterREF and GetDistance to NiptonXmarker < 5000

 

So the idea is that the companion will check if he's within that distance of his Nipton X marker, and if each of the crucified survivors returns a dead count of at least 1, and then he will produce a dialogue acknowledging that the player mercy killed all of the crucified survivors. But that seems like a lot of conditions to put on one dialogue. Is there another way I should do this?

Link to comment
Share on other sites

Re: distance. 128 game units is the equivalent of the default 6 foot tall NPC actor. With the default "GetDistance" function: "If a null reference - or a reference to an object not in the current cell - is passed, the script crashes". Consider the JIP function "GetDistance2D" which can also be used as a condition.

 

I don't recall having seen anything about a specific interior cell size, but please see the issue "Issue - Entering an Interior spawns the player in a huge ball of items and NPCs aka junkado or junknado" under the "Solutions to Graphics problems" section of the wiki "Fallout NV Mod Conflict Troubleshooting" article about using an excessive z-axis value.

 

As for "too many conditions", I would consider splitting the dialog up into several "clone" lines with different conditions on each to distinguish them from each other. Remember that a given line of dialog will not "fire" unless all the conditions are met, and too many conditions can quickly become problematic to debug.

 

-Dubious-

Link to comment
Share on other sites

Re: distance. 128 game units is the equivalent of the default 6 foot tall NPC actor. With the default "GetDistance" function: "If a null reference - or a reference to an object not in the current cell - is passed, the script crashes". Consider the JIP function "GetDistance2D" which can also be used as a condition.

 

I don't recall having seen anything about a specific interior cell size, but please see the issue "Issue - Entering an Interior spawns the player in a huge ball of items and NPCs aka junkado or junknado" under the "Solutions to Graphics problems" section of the wiki "Fallout NV Mod Conflict Troubleshooting" article about using an excessive z-axis value.

 

As for "too many conditions", I would consider splitting the dialog up into several "clone" lines with different conditions on each to distinguish them from each other. Remember that a given line of dialog will not "fire" unless all the conditions are met, and too many conditions can quickly become problematic to debug.

 

-Dubious-

Thank you for the resources! I've set GetDistance to no more than 1000 for some of the exterior cells in which he has a location dialogue that depends on an X marker, and usually around 800, which is about the distance I have him set for longer follow distance. For interior cells he instead uses GetInCell to generate his location dialogues, which hopefully will cause fewer problems. I'll playtest it as I go to see if the distance on his exterior markers is causing any problems.

 

Edit to say: I ended up getting rid of his ambient dialogue about killing the crucifixion victims and making it a greeting he says instead, and I trimmed down the conditions on it. I added an OnDeath script for each of the crucifixion victims to set MercyKill to 1 in his companion quest script, and his dialogue only checks if that's at 1, so that he'll say the line if any of the victims has been mercy killed. So it has fewer conditions on it. Might be a bit wonky because he says "I'm glad you killed those men on the crosses" even if the player only killed one of them but it's good enough.

Edited by McFearo
Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...