Tutorial:Context Viewer (Warhammer 3): Difference between revisions

From Total War Modding
No edit summary
(Gathering UI Paths/GUID)
Line 1: Line 1:
== UNDER CONSTRUCTION - APPROVE MY IMAGES VANDY PLS ==


The context viewer is a CA hack that can be activated in the settings menu in Total War: Warhammer 3.  
The context viewer is a CA hack that can be activated in the settings menu in Total War: Warhammer 3.  
Line 10: Line 8:


== Enabling the Context Viewer ==
== Enabling the Context Viewer ==
[[File:Enable ui context viewer.png|alt=options > settings > Modding > enable context viewer|left|thumb]]
[[File:Enable ui context viewer.png|alt=options > settings > Modding > enable context viewer|left|thumb]]To enable the context viewer, simply open the settings menu, hit the gear icon (fourth down on the left side menu), and then check the box under Modding.
 
 
You can now open the context viewer in game using your ` key. That's right above tab, to the left of 1, on a standard keyboard.
 
 
 
 
== Using the Context Viewer ==
Some stuff about the different panels and the expression tester
 
== Example Usages ==
Here are some common tasks the UI Context Viewer can help with.
 
=== Gathering UI Path/GUIDs for Scripting/XML Editing ===
[[File:Context viewer copy 2.jpg|left|thumb]]
When you are scripting using UI elements you often require the path from the root component to a given component you want to work with.
 
To use the context viewer to make this easier, use the component tree to navigate to the component that you are looking for.
 
Then use CopyFullPathToClipboard() in the expression tester box. You can now paste this into your scripts.
 
You can also use the related CopyStringToClipboard(GuidOriginal()) to copy the GUID - this can be used to find the component with the twui.xml files.

Revision as of 09:07, 30 March 2022

The context viewer is a CA hack that can be activated in the settings menu in Total War: Warhammer 3.


You already knew that, of course, because you've been using it to cheat in your single player games.

But what you might not know is you can also use it to make UI mod creation easier. This guide is intended to teach you how to use the viewer and outline some places it can make the UI Modding workflow easier.

Enabling the Context Viewer

options > settings > Modding > enable context viewer

To enable the context viewer, simply open the settings menu, hit the gear icon (fourth down on the left side menu), and then check the box under Modding.


You can now open the context viewer in game using your ` key. That's right above tab, to the left of 1, on a standard keyboard.



Using the Context Viewer

Some stuff about the different panels and the expression tester

Example Usages

Here are some common tasks the UI Context Viewer can help with.

Gathering UI Path/GUIDs for Scripting/XML Editing

Context viewer copy 2.jpg

When you are scripting using UI elements you often require the path from the root component to a given component you want to work with.

To use the context viewer to make this easier, use the component tree to navigate to the component that you are looking for.

Then use CopyFullPathToClipboard() in the expression tester box. You can now paste this into your scripts.

You can also use the related CopyStringToClipboard(GuidOriginal()) to copy the GUID - this can be used to find the component with the twui.xml files.