mirror of
https://github.com/sp-tarkov/assembly-tool.git
synced 2025-02-13 09:50:44 -05:00
Merge remote-tracking branch 'origin/master'
This commit is contained in:
commit
817fe28c1e
@ -2684,18 +2684,25 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"NewTypeName": "DamageInfo",
|
"NewTypeName": "DamageInfoStruct",
|
||||||
"OriginalTypeName": "GStruct394",
|
"OriginalTypeName": "GStruct421",
|
||||||
"UseForceRename": false,
|
"UseForceRename": false,
|
||||||
"SearchParams": {
|
"SearchParams": {
|
||||||
"IsPublic": true,
|
"IsPublic": true,
|
||||||
"IncludeMethods": [],
|
"IncludeMethods": [],
|
||||||
"ExcludeMethods": [],
|
"ExcludeMethods": [],
|
||||||
"IncludeFields": [
|
"IncludeFields": [
|
||||||
"OverDamageFrom"
|
"OverDamageFrom",
|
||||||
|
"Player",
|
||||||
|
"BodyPartColliderType",
|
||||||
|
"HittedBallisticColliders"
|
||||||
],
|
],
|
||||||
"ExcludeFields": [],
|
"ExcludeFields": [],
|
||||||
"IncludeProperties": [],
|
"IncludeProperties": [
|
||||||
|
"Penetrated",
|
||||||
|
"HaveOwner",
|
||||||
|
"Blunt"
|
||||||
|
],
|
||||||
"ExcludeProperties": [],
|
"ExcludeProperties": [],
|
||||||
"IncludeNestedTypes": [],
|
"IncludeNestedTypes": [],
|
||||||
"ExcludeNestedTypes": []
|
"ExcludeNestedTypes": []
|
||||||
@ -5278,25 +5285,25 @@
|
|||||||
"ExcludeNestedTypes": []
|
"ExcludeNestedTypes": []
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
{
|
// {
|
||||||
"NewTypeName": "SwapOperationClass",
|
// "NewTypeName": "SwapOperationClass",
|
||||||
"OriginalTypeName": "GClass3090",
|
// "OriginalTypeName": "GClass3090",
|
||||||
"UseForceRename": false,
|
// "UseForceRename": false,
|
||||||
"SearchParams": {
|
// "SearchParams": {
|
||||||
"IsPublic": true,
|
// "IsPublic": true,
|
||||||
"ConstructorParameterCount": 7,
|
// "ConstructorParameterCount": 7,
|
||||||
"IncludeMethods": [],
|
// "IncludeMethods": [],
|
||||||
"ExcludeMethods": [],
|
// "ExcludeMethods": [],
|
||||||
"IncludeFields": [],
|
// "IncludeFields": [],
|
||||||
"ExcludeFields": [],
|
// "ExcludeFields": [],
|
||||||
"IncludeProperties": [
|
// "IncludeProperties": [
|
||||||
"DestroysMainItem"
|
// "DestroysMainItem"
|
||||||
],
|
// ],
|
||||||
"ExcludeProperties": [],
|
// "ExcludeProperties": [],
|
||||||
"IncludeNestedTypes": [],
|
// "IncludeNestedTypes": [],
|
||||||
"ExcludeNestedTypes": []
|
// "ExcludeNestedTypes": []
|
||||||
}
|
// }
|
||||||
},
|
// },
|
||||||
{
|
{
|
||||||
"NewTypeName": "ThrowOperationClass",
|
"NewTypeName": "ThrowOperationClass",
|
||||||
"OriginalTypeName": "GClass3091",
|
"OriginalTypeName": "GClass3091",
|
||||||
@ -6310,17 +6317,21 @@
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
"NewTypeName": "TimeHasComeScreenClass",
|
"NewTypeName": "TimeHasComeScreenClass",
|
||||||
"OriginalTypeName": "GClass3436",
|
"OriginalTypeName": "GClass3563",
|
||||||
"UseForceRename": false,
|
"UseForceRename": false,
|
||||||
"SearchParams": {
|
"SearchParams": {
|
||||||
|
"ConstructorParameterCount": 3,
|
||||||
"IsPublic": true,
|
"IsPublic": true,
|
||||||
"IsNested": true,
|
"IsNested": true,
|
||||||
"IsSealed": true,
|
"IsSealed": false,
|
||||||
"NTParentName": "MatchmakerTimeHasCome",
|
"NTParentName": "MatchmakerTimeHasCome",
|
||||||
"IncludeMethods": [],
|
"IncludeMethods": [],
|
||||||
"ExcludeMethods": [],
|
"ExcludeMethods": [],
|
||||||
"IncludeFields": [
|
"IncludeFields": [
|
||||||
"SearchingForServer"
|
"ScreenType",
|
||||||
|
"IsReconnecting",
|
||||||
|
"SwitchTaskBarButtonsAvailability",
|
||||||
|
"LimitedServersAvailability"
|
||||||
],
|
],
|
||||||
"ExcludeFields": [],
|
"ExcludeFields": [],
|
||||||
"IncludeProperties": [],
|
"IncludeProperties": [],
|
||||||
@ -7667,7 +7678,8 @@
|
|||||||
"FieldCount": 1,
|
"FieldCount": 1,
|
||||||
"IncludeMethods": [
|
"IncludeMethods": [
|
||||||
"Enter",
|
"Enter",
|
||||||
"Exit"
|
"Exit",
|
||||||
|
"ManualAnimatorMoveUpdate"
|
||||||
],
|
],
|
||||||
"ExcludeMethods": [
|
"ExcludeMethods": [
|
||||||
"ProcessAnimatorMovement",
|
"ProcessAnimatorMovement",
|
||||||
|
@ -35,5 +35,9 @@
|
|||||||
{"Role":"followerKojaniy","Limit":2,"Difficulty":"normal"},
|
{"Role":"followerKojaniy","Limit":2,"Difficulty":"normal"},
|
||||||
{"Role":"skier","Limit":2,"Difficulty":"normal"},
|
{"Role":"skier","Limit":2,"Difficulty":"normal"},
|
||||||
{"Role":"peacemaker","Limit":2,"Difficulty":"normal"},
|
{"Role":"peacemaker","Limit":2,"Difficulty":"normal"},
|
||||||
{"Role":"bossPartisan","Limit":2,"Difficulty":"normal"}
|
{"Role":"infectedAssault","Limit":2,"Difficulty":"normal"},
|
||||||
|
{"Role":"infectedPmc","Limit":2,"Difficulty":"normal"},
|
||||||
|
{"Role":"infectedCivil","Limit":2,"Difficulty":"normal"},
|
||||||
|
{"Role":"infectedLaborant","Limit":2,"Difficulty":"normal"},
|
||||||
|
{"Role":"infectedTagilla","Limit":2,"Difficulty":"normal"}
|
||||||
]
|
]
|
@ -168,7 +168,7 @@ namespace DumpLib
|
|||||||
// get End raid class from json
|
// get End raid class from json
|
||||||
DataHelper.EndRaidClass = DataHelper.GetEndRaidClass();
|
DataHelper.EndRaidClass = DataHelper.GetEndRaidClass();
|
||||||
// get player profile
|
// get player profile
|
||||||
DataHelper.PlayerProfile = ReflectionHelper.GetPlayerProfile();
|
DataHelper.PlayerProfile = ReflectionHelper.GetProfileCompleteData();
|
||||||
// Set up end raid class
|
// Set up end raid class
|
||||||
DataHelper.EndRaidClass.GetType().GetField("profile").SetValue(DataHelper.EndRaidClass, DataHelper.PlayerProfile);
|
DataHelper.EndRaidClass.GetType().GetField("profile").SetValue(DataHelper.EndRaidClass, DataHelper.PlayerProfile);
|
||||||
|
|
||||||
|
@ -32,7 +32,7 @@ public class MethodHelper
|
|||||||
}
|
}
|
||||||
|
|
||||||
/// <summary>
|
/// <summary>
|
||||||
/// Method to get Quit method from EFT (as of 20/05/2024 - GClass1955)
|
/// Method to get Quit method from EFT (as of 02/11/2024 - GClass2193)
|
||||||
/// </summary>
|
/// </summary>
|
||||||
/// <returns>MethodInfo</returns>
|
/// <returns>MethodInfo</returns>
|
||||||
public static MethodInfo GetApplicationQuitMethod()
|
public static MethodInfo GetApplicationQuitMethod()
|
||||||
@ -40,8 +40,11 @@ public class MethodHelper
|
|||||||
try
|
try
|
||||||
{
|
{
|
||||||
return DataHelper._eftAssembly.GetTypes().First(x =>
|
return DataHelper._eftAssembly.GetTypes().First(x =>
|
||||||
x.GetMethods().Any(y =>
|
{
|
||||||
y.Name == "Quit")
|
var methods = x.GetMethods();
|
||||||
|
|
||||||
|
return methods.Any(m => m.Name == "Quit") && methods.Any(m => m.Name == "QuitWithCode");
|
||||||
|
}
|
||||||
).GetMethod("Quit");
|
).GetMethod("Quit");
|
||||||
}
|
}
|
||||||
catch (Exception e)
|
catch (Exception e)
|
||||||
|
@ -220,6 +220,9 @@ namespace DumpLib.Helpers
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// DONT USE ANYMORE, USE GETPROFILECOMPLETEDATA()
|
||||||
|
/// </summary>
|
||||||
public static object GetPlayerProfile()
|
public static object GetPlayerProfile()
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
@ -235,5 +238,47 @@ namespace DumpLib.Helpers
|
|||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// <summary>
|
||||||
|
/// TODO: Rename as its not an actual shim
|
||||||
|
///
|
||||||
|
/// </summary>
|
||||||
|
/// <returns></returns>
|
||||||
|
public static object GetProfileShim()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var typeToUse = TypeHelper.GetProfileShimType();
|
||||||
|
var instance = Activator.CreateInstance(typeToUse,
|
||||||
|
new object[]
|
||||||
|
{
|
||||||
|
DataHelper.Session.GetType().GetProperty("Profile").GetValue(DataHelper.Session),
|
||||||
|
TypeHelper.GetProfileSearchControllerType().GetField("Instance").GetValue(null)
|
||||||
|
});
|
||||||
|
return instance;
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Utils.LogError("GetProfileShim");
|
||||||
|
Utils.LogError(e);
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static object GetProfileCompleteData()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
var completeData = ReflectionHelper.GetProfileShim();
|
||||||
|
var converterMethod = CreateGenericMethod(MethodHelper.GetToUnparsedDataMethod(), TypeHelper.GetProfileShimType());
|
||||||
|
return converterMethod.Invoke(null, new[] { completeData, Array.Empty<JsonConverter>() });
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Utils.LogError("GetProfileCompleteData");
|
||||||
|
Utils.LogError(e);
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
@ -253,4 +253,56 @@ public static class TypeHelper
|
|||||||
throw;
|
throw;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static Type GetProfileShimType()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
return DataHelper._eftAssembly.GetTypes().First(x =>
|
||||||
|
{
|
||||||
|
var fields = x.GetFields();
|
||||||
|
var constructors = x.GetConstructors();
|
||||||
|
var properties = x.GetProperties();
|
||||||
|
var methods = x.GetMethods();
|
||||||
|
|
||||||
|
return fields.Length == 25 && constructors.Length == 2 &&
|
||||||
|
properties.Length == 0 && methods.Length == 4 &&
|
||||||
|
fields.Any(f => f.Name == "KarmaValue") &&
|
||||||
|
fields.Any(f => f.Name == "Encyclopedia") &&
|
||||||
|
fields.Any(f => f.Name == "Id") &&
|
||||||
|
fields.Any(f => f.Name == "AccountId") &&
|
||||||
|
fields.Any(f => f.Name == "PetId") &&
|
||||||
|
fields.Any(f => f.Name == "Customization");
|
||||||
|
});
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Utils.LogError("GetProfileShimType");
|
||||||
|
Utils.LogError(e);
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static Type GetProfileSearchControllerType()
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
return DataHelper._eftAssembly.GetTypes().First(x =>
|
||||||
|
{
|
||||||
|
var fields = x.GetFields();
|
||||||
|
var methods = x.GetMethods();
|
||||||
|
|
||||||
|
return fields.Length == 1 && methods.Length == 17 &&
|
||||||
|
!x.IsInterface && methods.Any(m => m.Name == "IsItemKnown") &&
|
||||||
|
methods.Any(m => m.Name == "TryFindChangedContainer") &&
|
||||||
|
methods.Any(m => m.Name == "GetObserverItemState");
|
||||||
|
});
|
||||||
|
}
|
||||||
|
catch (Exception e)
|
||||||
|
{
|
||||||
|
Utils.LogError("GetProfileSearchControllerType");
|
||||||
|
Utils.LogError(e);
|
||||||
|
throw;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
@ -222,7 +222,8 @@ public class DumperClass
|
|||||||
var firstMethod = methods.FirstOrDefault(m => m.Parameters.Any(p => p.Name == "certificate"));
|
var firstMethod = methods.FirstOrDefault(m => m.Parameters.Any(p => p.Name == "certificate"));
|
||||||
var secondMethod = methods.FirstOrDefault(m => m.Parameters.Any(p => p.Name == "certificateData"));
|
var secondMethod = methods.FirstOrDefault(m => m.Parameters.Any(p => p.Name == "certificateData"));
|
||||||
|
|
||||||
if (firstMethod?.Body.Instructions.Count != 55 || secondMethod?.Body.Instructions.Count != 14)
|
// as of 01/11/24 firstMethod returns true, so its now only 2 instructions, was 55 (this may change, BSG have byppassed their own SSL checks atm)
|
||||||
|
if (firstMethod?.Body.Instructions.Count != 2 || secondMethod?.Body.Instructions.Count != 14)
|
||||||
{
|
{
|
||||||
Logger.Log($"Instruction count has changed, method with 'certificate' as a param - before: 51, now: {firstMethod.Body.Instructions.Count}, " +
|
Logger.Log($"Instruction count has changed, method with 'certificate' as a param - before: 51, now: {firstMethod.Body.Instructions.Count}, " +
|
||||||
$"method with 'certificateData' as a param - before: 14, now: {secondMethod.Body.Instructions.Count}", ConsoleColor.Red);
|
$"method with 'certificateData' as a param - before: 14, now: {secondMethod.Body.Instructions.Count}", ConsoleColor.Red);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user