Skip to content

Commit

Permalink
add an xml injector
Browse files Browse the repository at this point in the history
to patch more easily whenever the game updates
  • Loading branch information
valorad committed Nov 24, 2020
1 parent bc8a93f commit 4b1ad76
Show file tree
Hide file tree
Showing 10 changed files with 334 additions and 20 deletions.
2 changes: 2 additions & 0 deletions src/data/abilities/abilities.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<!--> 附加到决定版 Data/Abilities/abilities.xml中 <!-->

<NEDAbilities>
<!--> AOE3 NativeED mod Abilities Starts <!-->
<WCBxfjsyh>
<ability>
Expand Down Expand Up @@ -166,3 +167,4 @@
</WCEVikas>

<!--> AOE3 NativeED mod Abilities Ends <!-->
</NEDAbilities>
5 changes: 4 additions & 1 deletion src/data/abilities/powers.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>

<NEDPowers>
<!--> 附加到决定版 Data/Abilities/powers.xml中 <!-->

<!--> AOE3 NativeED mod Powers Starts <!-->
Expand Down Expand Up @@ -227,4 +228,6 @@
<allowduringnorush>1</allowduringnorush>
</power>

<!--> AOE3 NativeED mod Powers Ends <!-->
<!--> AOE3 NativeED mod Powers Ends <!-->
</NEDPowers>

11 changes: 7 additions & 4 deletions src/data/stringTable/stringtabley-cn.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<!--> 附加到决定版 Data/strings/SimplifiedChinese/stringtabley.xml中 <!-->

<?xml version="1.0" encoding="utf-8"?>

<nedStrings>
<!--> 附加到决定版 Data/strings/SimplifiedChinese/stringtabley.xml中 <!-->
<!--NativeED String Starts-->
<string _locid="200000">西方军事议会</string>
<string _locid="220000">WCB 西方军事议会</string>
Expand Down Expand Up @@ -244,4 +245,6 @@
<string _locid="8000">聚合条约</string>
<string _locid="800000">签订聚合条约,取得组织的帮助</string>
<string _locid="840000">签订聚合条约,取得组织的帮助</string>
<!--NativeED String Ends-->
<!--NativeED String Ends-->
</nedStrings>

9 changes: 6 additions & 3 deletions src/data/stringTable/stringtabley-en.xml
Original file line number Diff line number Diff line change
@@ -1,5 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<!--> 附加到决定版 Data/strings/SimplifiedChinese/stringtabley.xml中 <!-->
<?xml version="1.0" encoding="utf-8"?>

<nedStrings>
<!--> 附加到决定版 Data/strings/SimplifiedChinese/stringtabley.xml中 <!-->

<!--NativeED String Starts-->
<string _locid="200000">Western Military Council</string>
Expand Down Expand Up @@ -244,4 +246,5 @@
<string _locid="8000">Ju He contract</string>
<string _locid="800000">签订聚合条约,取得组织的帮助</string>
<string _locid="840000">签订聚合条约,取得组织的帮助</string>
<!--NativeED String Ends-->
<!--NativeED String Ends-->
</nedStrings>
39 changes: 27 additions & 12 deletions src/data/techtreey.xml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@

<!--西方国家部分。 将代码添加到以下国家项的末尾-->

<!--> NativeED mod enabler EU Starts <!-->
<!-- NativeED mod enabler EU Starts-->
<effect type="TechStatus" status="active">WCTxfjsyhTech</effect>
<effect type="TechStatus" status="obtainable">WCTamyjtTech</effect>
<effect type="TechStatus" status="obtainable">WCTjhtTech</effect>
<!--> NativeED mod enabler EU Ends <!-->
<!-- NativeED mod enabler EU Ends -->

<!--西方国家有: -->
<ul>
Expand All @@ -23,6 +23,10 @@
<li>Age0SPCAct2</li>
<li>Age0SPCAct1</li>
<li>Age0SPCAct3</li>
<li>Age0SPCBandits</li>
<li>Age0XPSPCFalcon</li>

<li>DEAge0Swedish</li>
</ul>


Expand All @@ -44,11 +48,11 @@

<!--美洲国家部分。 将代码添加到以下国家项的末尾-->

<!--> NativeED mod enabler NA Starts <!-->
<effect type="TechStatus" status="active">WCTamyjtTech</effect>
<effect type="TechStatus" status="obtainable">WCTxfjsyhTech</effect>
<effect type="TechStatus" status="obtainable">WCTjhtTech</effect>
<!--> NativeED mod enabler NA Ends <!-->
<!-- NativeED mod enabler NA Starts -->
<effect type="TechStatus" status="active">WCTamyjtTech</effect>
<effect type="TechStatus" status="obtainable">WCTxfjsyhTech</effect>
<effect type="TechStatus" status="obtainable">WCTjhtTech</effect>
<!-- NativeED mod enabler NA Ends -->

<!--美洲国家有: -->
<ul>
Expand All @@ -58,6 +62,8 @@
<li>Age0XPSPC</li>
<li>XPSPCAct1Age0</li>
<li>XPSPCAct2Age0</li>
<li>Age0XPSPCLakota</li>
<li>DEAge0Inca</li>
</ul>

<!--示例:-->
Expand All @@ -80,11 +86,11 @@

<!--亚洲国家部分。 将代码添加到以下国家项的末尾-->

<!--> NativeED mod enabler AS Starts <!-->
<effect type="TechStatus" status="active">WCTjhtTech</effect>
<effect type="TechStatus" status="obtainable">WCTxfjsyhTech</effect>
<effect type="TechStatus" status="obtainable">WCTamyjtTech</effect>
<!--> NativeED mod enabler AS Ends <!-->
<!-- NativeED mod enabler AS Starts -->
<effect type="TechStatus" status="active">WCTjhtTech</effect>
<effect type="TechStatus" status="obtainable">WCTxfjsyhTech</effect>
<effect type="TechStatus" status="obtainable">WCTamyjtTech</effect>
<!-- NativeED mod enabler AS Ends -->

<!--亚洲国家有: -->
<ul>
Expand Down Expand Up @@ -115,6 +121,15 @@
</effects>
</tech>


<!--未探明的国家有: -->
<ul>
<li>DEAge0BarbarySPC</li>
<li>DEAge0AmericansSPC</li>
<li>DEAge0TatarsSPC</li>
<li>DEAge0EthiopiansSPC</li>
</ul>

<!-- 科技部分。 将代码添加到techtreeY文件末尾-->

<!-- AOE3 NativeED mod Tech Starts -->
Expand Down
27 changes: 27 additions & 0 deletions tools/xml-inject/.vscode/launch.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
{
// Use IntelliSense to find out which attributes exist for C# debugging
// Use hover for the description of the existing attributes
// For further information visit https://github.com/OmniSharp/omnisharp-vscode/blob/master/debugger-launchjson.md
"version": "0.2.0",
"configurations": [
{
"name": ".NET Core Launch (console)",
"type": "coreclr",
"request": "launch",
"preLaunchTask": "build",
// If you have changed target frameworks, make sure to update the program path.
"program": "${workspaceFolder}/App/bin/Debug/net5.0/XMLInject.dll",
"args": [],
"cwd": "${workspaceFolder}/App",
// For more information about the 'console' field, see https://aka.ms/VSCode-CS-LaunchJson-Console
"console": "internalConsole",
"stopAtEntry": false
},
{
"name": ".NET Core Attach",
"type": "coreclr",
"request": "attach",
"processId": "${command:pickProcess}"
}
]
}
42 changes: 42 additions & 0 deletions tools/xml-inject/.vscode/tasks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
{
"version": "2.0.0",
"tasks": [
{
"label": "build",
"command": "dotnet",
"type": "process",
"args": [
"build",
"${workspaceFolder}/App/App.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
},
{
"label": "publish",
"command": "dotnet",
"type": "process",
"args": [
"publish",
"${workspaceFolder}/App/App.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
},
{
"label": "watch",
"command": "dotnet",
"type": "process",
"args": [
"watch",
"run",
"${workspaceFolder}/App/App.csproj",
"/property:GenerateFullPaths=true",
"/consoleloggerparameters:NoSummary"
],
"problemMatcher": "$msCompile"
}
]
}
9 changes: 9 additions & 0 deletions tools/xml-inject/App/App.csproj
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<Project Sdk="Microsoft.NET.Sdk">

<PropertyGroup>
<OutputType>Exe</OutputType>
<TargetFramework>net5.0</TargetFramework>
<AssemblyName>XMLInject</AssemblyName>
</PropertyGroup>

</Project>
Loading

0 comments on commit 4b1ad76

Please # to comment.