Arma Reforger Explorer 1.7.0.54
Arma Reforger Code Explorer by Zeroy - Thanks to MisterOutofTime
Loading...
Searching...
No Matches
SCR_LocParserPlugin.c
Go to the documentation of this file.
1#ifdef WORKBENCH
2[WorkbenchPluginAttribute(name: "Localise Selected Files", shortcut: "Ctrl+Alt+L", wbModules: { "ResourceManager" }, awesomeFontCode: 0xF1AB)]
3class SCR_LocParserPlugin : WorkbenchPlugin
4{
5 [Attribute(defvalue: "{D3EAEB413B6F0AA3}Configs/Workbench/LocParser/Default.conf")]
6 protected ResourceName m_sConfigPath;
7
8 [Attribute(defvalue: "", params: "st")]
9 protected ResourceName m_sStringTableOverride;
10
11 [Attribute(defvalue: "")]
12 protected string m_sPrefixOverride;
13
14 protected bool m_bLogOnly;
15
16 //------------------------------------------------------------------------------------------------
17 override void Run()
18 {
19 string header = "Localise strings in selected files." +
20 "\nNot all strings will be affected, e.g., texture paths will be omitted." +
21 "\nOpen the config to review processing rules." +
22 "\n\nPress [Log] to find and log all strings which can be localized." +
23 "\n\nPress [Localise] to add the strings to the string table." +
24 "\nWARNING: THIS ACTION WILL MODIFY FILES!";
25
26 if (Workbench.ScriptDialog("Localise Selected", header, this))
27 LocParserManager.Run(m_sConfigPath, m_bLogOnly, m_sStringTableOverride, m_sPrefixOverride);
28 }
29
30 //------------------------------------------------------------------------------------------------
31 [ButtonAttribute("Log", focused: true)]
32 protected void ButtonLog()
33 {
34 m_bLogOnly = true;
35 }
36
37 //------------------------------------------------------------------------------------------------
38 [ButtonAttribute("Localise")]
39 protected void ButtonLocalise()
40 {
41 m_bLogOnly = false;
42 }
43
44 //------------------------------------------------------------------------------------------------
45 [ButtonAttribute("Cancel")]
46 protected bool ButtonCancel()
47 {
48 return false;
49 }
50}
51#endif // WORKBENCH
GenerateFlowMaps WorkbenchPlugin WorkbenchPluginAttribute("Regenerate river flow-maps", "Generate and save/overwrite river flow-maps", "", "", {"WorldEditor"}, "", 0xf773)
Definition FlowmapTool.c:59
override void Run()
bool ButtonCancel()
class WorkbenchDialog_AbortRetryIgnore ButtonAttribute("OK", true)
void Run(BaseContainer source, bool logOnly, ResourceName stringTableOverride, string prefixOverride)
SCR_FieldOfViewSettings Attribute