Skip to content

Commit

Permalink
Update workflow and update reference to MissionLibrary
Browse files Browse the repository at this point in the history
  • Loading branch information
LiZhenhuan1019 committed Aug 24, 2022
1 parent a9972a2 commit 0d10e61
Show file tree
Hide file tree
Showing 11 changed files with 45 additions and 32 deletions.
10 changes: 5 additions & 5 deletions .github/resources/FileFilters.regexp
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
bin\\Win64_Shipping_Client\\(?<=\\)[^\\]*TaleWorlds.+
Modules\\CustomBattle\\bin\\Win64_Shipping_Client\\(?<=\\)[^\\]+dll
Modules\\SandBox\\bin\\Win64_Shipping_Client\\(?<=\\)[^\\]+dll
Modules\\SandBoxCore\\bin\\Win64_Shipping_Client\\(?<=\\)[^\\]+dll
Modules\\StoryMode\\bin\\Win64_Shipping_Client\\(?<=\\)[^\\]+dll
regex:bin/Win64_Shipping_Client/(?<=/)[^/]*TaleWorlds.+
regex:Modules/CustomBattle/bin/Win64_Shipping_Client/(?<=/)[^/]+dll
regex:Modules/SandBox/bin/Win64_Shipping_Client/(?<=/)[^/]+dll
regex:Modules/SandBoxCore/bin/Win64_Shipping_Client/(?<=/)[^/]+dll
regex:Modules/StoryMode/bin/Win64_Shipping_Client/(?<=/)[^/]+dll
4 changes: 2 additions & 2 deletions .github/resources/config.env
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
GAME_VERSION=e1.6.1
GAME_VERSION=e1.7.2
GAME_BRANCH=master
MOD_VERSION=e1.0.8
MOD_VERSION=e1.0.9
22 changes: 16 additions & 6 deletions .github/workflows/Build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,13 @@ jobs:
with:
dotnet-version: '2.2.x'

# additional .net core for DepotDownloader.
- name: Setup .NET Core 6.0.x
uses: actions/setup-dotnet@master
with:
dotnet-version: '6.0.x'


- name: setup-msbuild
uses: microsoft/setup-msbuild@v1
# with:
Expand All @@ -80,21 +87,24 @@ jobs:
# uses: NuGet/setup-nuget@04b0c2b8d1b97922f67eca497d7cf0bf17b8ffe1
uses: NuGet/[email protected]

- name: Download DepotDownloader_2.3.6
- name: Download DepotDownloader_2.4.7
uses: i3h/download-release-asset@v1
with:
owner: SteamRE
repo: DepotDownloader
tag: DepotDownloader_2.3.6
file: depotdownloader-2.3.6.zip
- name: Extract DepotDownloader_2.3.6
tag: DepotDownloader_2.4.7
file: depotdownloader-2.4.7.zip
- name: Extract DepotDownloader_2.4.7
uses: DuckSoft/[email protected]
with:
pathSource: depotdownloader-2.3.6.zip
pathSource: depotdownloader-2.4.7.zip
pathTarget: depotdownloader

- name: Download Bannerlord binaries
- name: Download Bannerlord binaries 1
run: dotnet depotdownloader/DepotDownloader.dll -app 261550 -depot 261551 -beta ${{steps.dotenv.outputs.game_version}} -username ${{secrets.STEAM_LOGIN}} -password ${{secrets.STEAM_PASSWORD}} -filelist ./.github/resources/FileFilters.regexp -dir bannerlord;

- name: Download Bannerlord binaries 2
run: dotnet depotdownloader/DepotDownloader.dll -app 261550 -depot 261552 -beta ${{steps.dotenv.outputs.game_version}} -username ${{secrets.STEAM_LOGIN}} -password ${{secrets.STEAM_PASSWORD}} -filelist ./.github/resources/FileFilters.regexp -dir bannerlord;

- name: Build Cinematic Camera
run: >-
Expand Down
3 changes: 3 additions & 0 deletions source/CinematicCamera/CinematicCamera.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,9 @@
<Reference Include="TaleWorlds.ObjectSystem">
<HintPath>$(GamePath)bin\Win64_Shipping_Client\TaleWorlds.ObjectSystem.dll</HintPath>
</Reference>
<Reference Include="TaleWorlds.ScreenSystem">
<HintPath>$(GamePath)bin\Win64_Shipping_Client\TaleWorlds.ScreenSystem.dll</HintPath>
</Reference>
<Reference Include="TaleWorlds.TwoDimension">
<HintPath>$(GamePath)bin\Win64_Shipping_Client\TaleWorlds.TwoDimension.dll</HintPath>
</Reference>
Expand Down
14 changes: 7 additions & 7 deletions source/CinematicCamera/Modules/CinematicCamera/SubModule.xml
Original file line number Diff line number Diff line change
Expand Up @@ -2,16 +2,16 @@
<Module>
<Name value="Cinematic Camera"/>
<Id value="CinematicCamera"/>
<Version value="e1.0.8"/>
<Version value="e1.0.9"/>
<SingleplayerModule value="true"/>
<MultiplayerModule value="false"/>
<DependedModules>
<DependedModule Id="Native" DependentVersion="e1.6.1" />
<DependedModule Id="SandBoxCore" DependentVersion="e1.6.1" />
<DependedModule Id="Sandbox" DependentVersion="e1.6.1" />
<DependedModule Id="CustomBattle" DependentVersion="e1.6.1"/>
<DependedModule Id="StoryMode" DependentVersion="e1.6.1" />
<DependedModule Id="RTSCamera" DependentVersion="e3.10.0" />
<DependedModule Id="Native" DependentVersion="e1.7.2" />
<DependedModule Id="SandBoxCore" DependentVersion="e1.7.2" />
<DependedModule Id="Sandbox" DependentVersion="e1.7.2" />
<DependedModule Id="CustomBattle" DependentVersion="e1.7.2"/>
<DependedModule Id="StoryMode" DependentVersion="e1.7.2" />
<DependedModule Id="RTSCamera" DependentVersion="e4.0.0" />
</DependedModules>
<SubModules>
<SubModule>
Expand Down
4 changes: 2 additions & 2 deletions source/CinematicCamera/src/CinematicCameraSubModule.cs
Original file line number Diff line number Diff line change
Expand Up @@ -58,9 +58,9 @@ private bool SecondInitialize()
return true;
}

public override void OnMissionBehaviourInitialize(Mission mission)
public override void OnMissionBehaviorInitialize(Mission mission)
{
base.OnMissionBehaviourInitialize(mission);
base.OnMissionBehaviorInitialize(mission);

ModifyCameraHelper.OnBehaviourInitialize();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@ public static IIdProvider<AOptionClass> CreateOptionClassProvider(IMenuClassColl
cameraOptionCategory.AddOption(new ActionOptionViewModel(GameTexts.FindText("str_cinematic_camera_open_menu"), null,
() =>
{
Mission.Current.GetMissionBehaviour<CinematicCameraMenuView>()?.ActivateMenu();
Mission.Current.GetMissionBehavior<CinematicCameraMenuView>()?.ActivateMenu();
}));
optionClass.AddOptionCategory(0, cameraOptionCategory);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9,17 +9,17 @@ public class SetPlayerHealthLogic : MissionLogic
{
private readonly CinematicCameraConfig _config = CinematicCameraConfig.Get();

public override void OnBehaviourInitialize()
public override void OnBehaviorInitialize()
{
base.OnBehaviourInitialize();
base.OnBehaviorInitialize();

Mission.OnMainAgentChanged += Mission_OnMainAgentChanged;
MissionEvent.MainAgentWillBeChangedToAnotherOne += MainAgentWillBeChangedToAnotherOne;
}

public override void OnRemoveBehaviour()
public override void OnRemoveBehavior()
{
base.OnRemoveBehaviour();
base.OnRemoveBehavior();

Mission.OnMainAgentChanged -= Mission_OnMainAgentChanged;
MissionEvent.MainAgentWillBeChangedToAnotherOne -= MainAgentWillBeChangedToAnotherOne;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ public class CinematicCameraMenuVM : MissionMenuVMBase
private readonly CinematicCameraConfig _config = CinematicCameraConfig.Get();

private readonly SetPlayerHealthLogic _setPlayerHealthLogic =
Mission.Current.GetMissionBehaviour<SetPlayerHealthLogic>();
Mission.Current.GetMissionBehavior<SetPlayerHealthLogic>();

private NumericVM _verticalFov;
//private NumericVM _zoom;
Expand Down
6 changes: 3 additions & 3 deletions source/CinematicCamera/src/MissionStartingHandler.cs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
using CinematicCamera.MissionBehaviors;
using System.Collections.Generic;
using MissionLibrary.Controller;
using MissionSharedLibrary.Controller;
using System.Collections.Generic;
using TaleWorlds.MountAndBlade;
using TaleWorlds.MountAndBlade.View.Missions;

Expand All @@ -11,7 +11,7 @@ public class MissionStartingHandler : AMissionStartingHandler
{
public override void OnCreated(MissionView entranceView)
{
List<MissionBehaviour> list = new List<MissionBehaviour>
List<MissionBehavior> list = new List<MissionBehavior>
{
new SetPlayerHealthLogic(),
new CinematicCameraMenuView()
Expand All @@ -20,7 +20,7 @@ public override void OnCreated(MissionView entranceView)

foreach (var missionBehaviour in list)
{
MissionStartingManager.AddMissionBehaviour(entranceView, missionBehaviour);
MissionStartingManager.AddMissionBehavior(entranceView, missionBehaviour);
}
}

Expand Down

0 comments on commit 0d10e61

Please sign in to comment.