Jump to content

Need help figuring out which mod adds this dialogue


Recommended Posts

Posted

Any NPC named or otherwise is able to start this dialogue and i need help figuring out which mod it is, here's the dialogue...

 

NPC: "Guards!!!!!!"

 

NPC: "You better wait here until the guard arrives"

 

NPC: "This person sat in my throne"

 

(The NPC will then follow my character around until a guard arrives)

 

If you know the mod that causes this id really appreciate letting me know, thanks.

 

(Also these are subtitles only not actually voice acted)

 

 

Posted

Here's an xEdit script, configured to find "wait here until the guard". Select any plugin in xEdit, Apply Script; it will search all loaded plugins regardless of what is selected.

{
  Find dialogue
}
unit UserScript;

function Initialize: integer;
var
  i: integer;
  j: integer;
  f: IInterface;
  e: IInterface;
  sig: string;
begin
  // iterate over loaded plugins
  for i := 0 to Pred(FileCount) do begin
    f := FileByIndex(i);
    
    for j := 0 to Pred(RecordCount(f)) do begin
        e := RecordByIndex(f, j);
        sig := Signature(e);
        if sig = 'DIAL' then SearchDial(e);
        if sig = 'INFO' then SearchInfo(e);
    end;
  end;
end;

procedure SearchDial(e: IInterface);
var
    m: string;
begin
    m := GetElementNativeValues(e, 'FULL - Name');
    
    if pos('wait here until the guard', m) > 0 then
        AddMessage(IntToHex(GetLoadOrderFormID(e), 8) + ' ' + m);
end;

procedure SearchInfo(e: IInterface);
var
    m: string;
    i: integer;
    responses, response: IInterface;
begin
    responses := ElementByName(e, 'Responses');
    
    for i := 0 to Pred(ElementCount(responses)) do begin
        response := ElementByIndex(responses, i);
        m := GetElementEditValues(response, 'NAM1');
        
        if pos('wait here until the guard', m) > 0 then
            AddMessage(IntToHex(GetLoadOrderFormID(e), 8) + ' ' + m);
    end;
end;

end.

 

Posted (edited)

@traison

 

cool script. I presume the search text can be replaced by any quoted, static dialog string and it will reveal the associated plugin source?

 

*static - doesn't contain dynamic references like player name or some side quest particular

Edited by anjenthedog
Posted

I suck at pascal, mainly because I dislike the language - it doesn't mesh with my brain. So, issue #1 is that you'll have to change the string you want to find in 2 locations (both pos() statments). Issue #2 is that the casing and spelling has to be exact: No missing capital letters, no missing sentence structure elements (commas, full stops, ...).

Posted (edited)

righto. An exact quote. understood.  Pascal was born of canon and code bureaucracy, so no surprise on the dislike.

 

Pascal is like Fortran being forced to wear both wrist AND ankle monitors ;) 

Edited by anjenthedog
Posted
On 8/13/2023 at 3:43 AM, traison said:

Here's an xEdit script, configured to find "wait here until the guard". Select any plugin in xEdit, Apply Script; it will search all loaded plugins regardless of what is selected.

{
  Find dialogue
}
unit UserScript;

function Initialize: integer;
var
  i: integer;
  j: integer;
  f: IInterface;
  e: IInterface;
  sig: string;
begin
  // iterate over loaded plugins
  for i := 0 to Pred(FileCount) do begin
    f := FileByIndex(i);
    
    for j := 0 to Pred(RecordCount(f)) do begin
        e := RecordByIndex(f, j);
        sig := Signature(e);
        if sig = 'DIAL' then SearchDial(e);
        if sig = 'INFO' then SearchInfo(e);
    end;
  end;
end;

procedure SearchDial(e: IInterface);
var
    m: string;
begin
    m := GetElementNativeValues(e, 'FULL - Name');
    
    if pos('wait here until the guard', m) > 0 then
        AddMessage(IntToHex(GetLoadOrderFormID(e), 8) + ' ' + m);
end;

procedure SearchInfo(e: IInterface);
var
    m: string;
    i: integer;
    responses, response: IInterface;
begin
    responses := ElementByName(e, 'Responses');
    
    for i := 0 to Pred(ElementCount(responses)) do begin
        response := ElementByIndex(responses, i);
        m := GetElementEditValues(response, 'NAM1');
        
        if pos('wait here until the guard', m) > 0 then
            AddMessage(IntToHex(GetLoadOrderFormID(e), 8) + ' ' + m);
    end;
end;

end.

 

thanks a lot, ill give it a shot next chance i get.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

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