-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
0 parents
commit c431611
Showing
5 changed files
with
186 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
################################################################################ | ||
# 此 .gitignore 文件已由 Microsoft(R) Visual Studio 自动创建。 | ||
################################################################################ | ||
|
||
/.vs | ||
/LKXModsGongFaGridCost/bin | ||
/LKXModsGongFaGridCost/obj |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
|
||
Microsoft Visual Studio Solution File, Format Version 12.00 | ||
# Visual Studio Version 17 | ||
VisualStudioVersion = 17.3.32901.215 | ||
MinimumVisualStudioVersion = 10.0.40219.1 | ||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "LKXModsGongFaGridCost", "LKXModsGongFaGridCost\LKXModsGongFaGridCost.csproj", "{CBB708F7-9C6A-42FB-9C0F-DDE2BACEFA9E}" | ||
EndProject | ||
Global | ||
GlobalSection(SolutionConfigurationPlatforms) = preSolution | ||
Debug|Any CPU = Debug|Any CPU | ||
Release|Any CPU = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(ProjectConfigurationPlatforms) = postSolution | ||
{CBB708F7-9C6A-42FB-9C0F-DDE2BACEFA9E}.Debug|Any CPU.ActiveCfg = Debug|Any CPU | ||
{CBB708F7-9C6A-42FB-9C0F-DDE2BACEFA9E}.Debug|Any CPU.Build.0 = Debug|Any CPU | ||
{CBB708F7-9C6A-42FB-9C0F-DDE2BACEFA9E}.Release|Any CPU.ActiveCfg = Release|Any CPU | ||
{CBB708F7-9C6A-42FB-9C0F-DDE2BACEFA9E}.Release|Any CPU.Build.0 = Release|Any CPU | ||
EndGlobalSection | ||
GlobalSection(SolutionProperties) = preSolution | ||
HideSolutionNode = FALSE | ||
EndGlobalSection | ||
GlobalSection(ExtensibilityGlobals) = postSolution | ||
SolutionGuid = {31436120-B318-4A9F-80DF-CBC1CE83650C} | ||
EndGlobalSection | ||
EndGlobal |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" /> | ||
<PropertyGroup> | ||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration> | ||
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform> | ||
<ProjectGuid>{CBB708F7-9C6A-42FB-9C0F-DDE2BACEFA9E}</ProjectGuid> | ||
<OutputType>Library</OutputType> | ||
<AppDesignerFolder>Properties</AppDesignerFolder> | ||
<RootNamespace>LKXModsGongFaGridCost</RootNamespace> | ||
<AssemblyName>LKXModsGongFaGridCost</AssemblyName> | ||
<TargetFrameworkVersion>v4.8</TargetFrameworkVersion> | ||
<FileAlignment>512</FileAlignment> | ||
<Deterministic>true</Deterministic> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Debug|AnyCPU' "> | ||
<DebugSymbols>true</DebugSymbols> | ||
<DebugType>full</DebugType> | ||
<Optimize>false</Optimize> | ||
<OutputPath>bin\Debug\</OutputPath> | ||
<DefineConstants>DEBUG;TRACE</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
</PropertyGroup> | ||
<PropertyGroup Condition=" '$(Configuration)|$(Platform)' == 'Release|AnyCPU' "> | ||
<DebugType>pdbonly</DebugType> | ||
<Optimize>true</Optimize> | ||
<OutputPath>bin\Release\</OutputPath> | ||
<DefineConstants>TRACE</DefineConstants> | ||
<ErrorReport>prompt</ErrorReport> | ||
<WarningLevel>4</WarningLevel> | ||
</PropertyGroup> | ||
<ItemGroup> | ||
<Compile Include="Main.cs" /> | ||
<Compile Include="Properties\AssemblyInfo.cs" /> | ||
</ItemGroup> | ||
<ItemGroup> | ||
<Reference Include="0Harmony"> | ||
<HintPath>E:\SteamLibrary\steamapps\common\The Scroll Of Taiwu\The Scroll of Taiwu_Data\Managed\0Harmony.dll</HintPath> | ||
<Private>False</Private> | ||
</Reference> | ||
<Reference Include="Assembly-CSharp"> | ||
<HintPath>E:\SteamLibrary\steamapps\common\The Scroll Of Taiwu\The Scroll of Taiwu_Data\Managed\Assembly-CSharp.dll</HintPath> | ||
<Private>False</Private> | ||
</Reference> | ||
<Reference Include="TaiwuModdingLib"> | ||
<HintPath>E:\SteamLibrary\steamapps\common\The Scroll Of Taiwu\The Scroll of Taiwu_Data\Managed\TaiwuModdingLib.dll</HintPath> | ||
<Private>False</Private> | ||
</Reference> | ||
</ItemGroup> | ||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" /> | ||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,66 @@ | ||
using Config; | ||
using HarmonyLib; | ||
using System.Collections.Generic; | ||
using TaiwuModdingLib.Core.Plugin; | ||
|
||
namespace LKXModsGongFaGridCost | ||
{ | ||
[PluginConfig("LKXModsGongFaGridCost", "LKX", "0.0.1")] | ||
public class Run : TaiwuRemakePlugin | ||
{ | ||
private Harmony harmony; | ||
|
||
/// <summary> | ||
/// 避免多次处理 | ||
/// </summary> | ||
public static bool Loaded = false; | ||
|
||
/// <summary> | ||
/// Mod被关闭 | ||
/// </summary> | ||
public override void Dispose() | ||
{ | ||
// Mod被关闭时 | ||
if (harmony != null) | ||
{ | ||
harmony.UnpatchSelf(); | ||
Loaded = false; | ||
harmony = null; | ||
} | ||
} | ||
|
||
/// <summary> | ||
/// Mod初始化 | ||
/// </summary> | ||
public override void Initialize() | ||
{ | ||
harmony = Harmony.CreateAndPatchAll(typeof(Run)); | ||
//执行 | ||
CombatSkill.Instance.GetAllKeys(); | ||
|
||
} | ||
|
||
/// <summary> | ||
/// 执行 | ||
/// </summary> | ||
/// <param name="____dataArray"></param> | ||
[HarmonyPostfix, HarmonyPatch(typeof(CombatSkill), "GetAllKeys")] | ||
public static void PatchSkill(ref List<CombatSkillItem> ____dataArray) | ||
{ | ||
if (Loaded) | ||
{ | ||
return; | ||
} | ||
foreach (CombatSkillItem item in ____dataArray) | ||
{ | ||
typeof(CombatSkillItem).GetField("GridCost").SetValue(item, (sbyte)1); | ||
if (item.Type == GameData.Domains.CombatSkill.CombatSkillType.Neigong) | ||
{ | ||
typeof(CombatSkillItem).GetField("GenericGrid").SetValue(item, (sbyte)12); | ||
} | ||
} | ||
|
||
Loaded = true; | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
using System.Reflection; | ||
using System.Runtime.CompilerServices; | ||
using System.Runtime.InteropServices; | ||
|
||
// 有关程序集的一般信息由以下 | ||
// 控制。更改这些特性值可修改 | ||
// 与程序集关联的信息。 | ||
[assembly: AssemblyTitle("LKXModsGongFaGridCost")] | ||
[assembly: AssemblyDescription("")] | ||
[assembly: AssemblyConfiguration("")] | ||
[assembly: AssemblyCompany("")] | ||
[assembly: AssemblyProduct("LKXModsGongFaGridCost")] | ||
[assembly: AssemblyCopyright("Copyright © 2022")] | ||
[assembly: AssemblyTrademark("")] | ||
[assembly: AssemblyCulture("")] | ||
|
||
// 将 ComVisible 设置为 false 会使此程序集中的类型 | ||
//对 COM 组件不可见。如果需要从 COM 访问此程序集中的类型 | ||
//请将此类型的 ComVisible 特性设置为 true。 | ||
[assembly: ComVisible(false)] | ||
|
||
// 如果此项目向 COM 公开,则下列 GUID 用于类型库的 ID | ||
[assembly: Guid("cbb708f7-9c6a-42fb-9c0f-dde2bacefa9e")] | ||
|
||
// 程序集的版本信息由下列四个值组成: | ||
// | ||
// 主版本 | ||
// 次版本 | ||
// 生成号 | ||
// 修订号 | ||
// | ||
//可以指定所有这些值,也可以使用“生成号”和“修订号”的默认值 | ||
//通过使用 "*",如下所示: | ||
// [assembly: AssemblyVersion("1.0.*")] | ||
[assembly: AssemblyVersion("1.0.0.0")] | ||
[assembly: AssemblyFileVersion("1.0.0.0")] |