Jump to content

UI.Set, .Invoke (and other UI functions), how does it work?


Recommended Posts

Is anyone here familiar with UI Script (the bridge interface between papyrus and AS3, Flash, actionscript)? Is there some general utility to it or is there no point messing with those functions unless you're building an entire Custom Menu or revamping one?

 

Say you want to smash a string of text into the console at some point in a utility quest script featuring miscellaneous low-level script tools. Just some text in-between and at the end of operations, no ambition to create an entire subsystem.

Is it then possible to do something like this, but with proper formatting (which I'm currently not familiar with):

UI.Set("Console", "root1", {__string__}: "Hello!")

 

Or

 

UI.Invoke("Console", "root<some other path index>", {__string__}: "Hellno!")

(The curly brackets and stuff is the notation F4SE uses)

The wiki says literally nothing and the F4SE script comments probably make sense but it's over my head for sure. I could get into it but not if there's no point. If I've misunderstood the entire thing I'd rather not wade into eternal hopelessness.

 

The source code for the bottom function reads "Var Function Invoke(string menu, string path, Var[] args = None) native global"

Any info or pointers will be much appreciated.

Link to comment
Share on other sites

I suppose something like this is closer to how it should look.

 

String[] FUNCTION cInvList()
String invArray = new String [0]
UI.Invoke("ContainerMenu", "_global.playerListArray", invArray.Add())
RETURN invArray
ENDFUNCTION
String[] FUNCTION pbInvList()
String invArray = new String [0]
UI.Invoke("PipboyMenu", "_global.InvItems", invArray.Add())
RETURN invArray
ENDFUNCTION
Link to comment
Share on other sites

  • Recently Browsing   0 members

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