@@ -23,15 +23,7 @@ public class PolyTechMain : PolyTechMod
23
23
public new const string
24
24
PluginGuid = "polytech.polytechframework" ,
25
25
PluginName = "PolyTech Framework" ,
26
- < << << << HEAD
27
- << << << < HEAD
28
- PluginVersion = "0.8.0" ;
29
- = == == ==
30
- PluginVersion = "0.7.7.5" ;
31
- > >>> >>> 4f 73842 ... Made it much harder to accidentally cheat
32
- == == == =
33
- PluginVersion = "0.8.0" ;
34
- > >>> >>> 8632f 6 a . .. refactored harmony patches
26
+ PluginVersion = "0.8.1" ;
35
27
private static BindingList < PolyTechMod >
36
28
noncheatMods = new BindingList < PolyTechMod > { } ,
37
29
cheatMods = new BindingList < PolyTechMod > { } ;
@@ -675,28 +667,18 @@ private static bool PatchReplays()
675
667
}
676
668
677
669
678
- [ HarmonyPatch ( typeof ( GalleryUploadBody ) , MethodType . Constructor ) ]
670
+ [ HarmonyPatch ( typeof ( Panel_ShareReplay ) , "CreateGalleryUploadBody" ) ]
679
671
[ HarmonyPostfix ]
680
- private static void PatchGallery ( GalleryUploadBody __instance , string build , string levelId , string itemId , bool win , float maxStress , int budget , byte [ ] video , byte [ ] videoPreview )
681
- {
682
- __instance . m_Build = build ;
683
- __instance . m_LevelId = levelId ;
684
- __instance . m_ItemId = itemId ;
685
- __instance . m_Result = ( win ? "win" : "fail" ) ;
686
- __instance . m_MaxStress = maxStress ;
687
- __instance . m_BudgetUsed = budget ;
688
- __instance . m_Video = video ;
689
- __instance . m_VideoPreview = videoPreview ;
690
-
691
- if ( PolyTechMain . modEnabled . Value )
672
+ private static void PatchGalleryUploadBody ( ref GalleryUploadBody __result )
673
+ {
674
+ //ptfInstance.ptfLogger.LogMessage($"Uploading video to gallery, modCheated = {ptfInstance.modCheated}");
675
+ if ( ptfInstance . modCheated )
692
676
{
693
- __instance . m_MaxStress = - 42069 ;
694
- __instance . m_BudgetUsed = int . MaxValue ;
677
+ __result . m_MaxStress = 42069 ;
678
+ __result . m_BudgetUsed = int . MaxValue ;
695
679
}
696
680
}
697
681
698
-
699
-
700
682
[ HarmonyPatch ( typeof ( SandboxLayoutData ) , "SerializePreBridgeBinary" ) ]
701
683
[ HarmonyPrefix ]
702
684
static void patchSerializerOne ( SandboxLayoutData __instance , List < byte > bytes )
0 commit comments