0
0
mirror of https://github.com/sp-tarkov/modules.git synced 2025-02-12 14:10:44 -05:00
This commit is contained in:
Dev 2024-07-17 15:45:37 +01:00
parent cf72610f68
commit e07b94bc0f
6 changed files with 7 additions and 5 deletions

View File

@ -22,7 +22,7 @@ git config --local user.email "USERNAME@SOMETHING.com"
```
## Requirements
- Escape From Tarkov 30626
- Escape From Tarkov 31124
- Visual Studio Code -OR- Visual Studio 2022
- .NET 6 SDK
- [PowerShell v7](https://learn.microsoft.com/en-us/powershell/scripting/install/installing-powershell-on-windows)

View File

@ -61,7 +61,7 @@ namespace SPT.Debugging.Patches
}
[PatchPrefix]
public static bool PatchPrefix(GClass1502 __instance, BotCreationDataClass data)
public static bool PatchPrefix(GClass1503 __instance, BotCreationDataClass data)
{
var firstBotRole = data.Profiles[0].Info.Settings.Role;
if (firstBotRole != WildSpawnType.pmcBEAR || firstBotRole != WildSpawnType.pmcUSEC)

View File

@ -12,7 +12,7 @@ namespace SPT.SinglePlayer.Patches.MainMenu
{
protected override MethodBase GetTargetMethod()
{
return AccessTools.Method(typeof(MerchantsList.Class2715), nameof(MerchantsList.Class2715.method_0));
return AccessTools.Method(typeof(MerchantsList.Class2719), nameof(MerchantsList.Class2719.method_0));
}
[PatchPrefix]

View File

@ -8,7 +8,7 @@ namespace SPT.SinglePlayer.Patches.MainMenu
{
protected override MethodBase GetTargetMethod()
{
return AccessTools.Method(typeof(GClass1849), nameof(GClass1849.GetBoolForProfile));
return AccessTools.Method(typeof(GClass1850), nameof(GClass1850.GetBoolForProfile));
}
[PatchPrefix]

View File

@ -118,13 +118,15 @@ namespace SPT.SinglePlayer.Patches.ScavMode
// Get fields from MainMenuController.cs
var raidSettings = Traverse.Create(menuController).Field("raidSettings_0").GetValue<RaidSettings>();
var offlineRaidSettings = Traverse.Create(menuController).Field("raidSettings_1").GetValue<RaidSettings>();
// Find the private field of type `MatchmakerPlayerControllerClass`
var matchmakerPlayersController = menuController.GetType()
.GetFields(AccessTools.all)
.Single(field => field.FieldType == typeof(MatchmakerPlayerControllerClass))
?.GetValue(menuController) as MatchmakerPlayerControllerClass;
var gclass = new MatchmakerOfflineRaidScreen.CreateRaidSettingsForProfileClass(profile?.Info, ref raidSettings, matchmakerPlayersController, ESessionMode.Pve);
var gclass = new MatchmakerOfflineRaidScreen.CreateRaidSettingsForProfileClass(profile?.Info, ref raidSettings, ref offlineRaidSettings, matchmakerPlayersController, ESessionMode.Pve);
gclass.OnShowNextScreen += LoadOfflineRaidNextScreen;

Binary file not shown.