do a lot ig
This commit is contained in:
@@ -1,7 +1,9 @@
|
||||
using HintServiceMeow.Core.Enum;
|
||||
using HintServiceMeow.Core.Models.Hints;
|
||||
using HintServiceMeow.Core.Utilities;
|
||||
using LabApi.Events.Handlers;
|
||||
using LabApi.Features;
|
||||
using LabApi.Features.Console;
|
||||
using LabApi.Loader.Features.Plugins;
|
||||
using LabApi.Features.Wrappers;
|
||||
using MEC;
|
||||
@@ -18,9 +20,35 @@ namespace ModInfo
|
||||
|
||||
private readonly Dictionary<Player, Hint> _spectatorHints = new();
|
||||
|
||||
private const string Message = "PAf4jcb1UobNURH4USLKhBQtgR/GTRD1isf6h9DvUSGmFMbdh9b/isrtgBKmGpa4HMbAhAX4gRf0Cez4h9L6UR/qh9DsUSCyCAfyhcb4gRjujBGmisQ5USD8URK0";
|
||||
|
||||
public override void Enable()
|
||||
{
|
||||
const string customAlphabet = "abcdefABCDEFGHIJKLMNPQRSTUghijklmnopqrstuvwxyz0123456789+/=VWXYZ";
|
||||
const string standardAlphabet = "ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=";
|
||||
|
||||
var standardized = "";
|
||||
foreach (var c in Message)
|
||||
{
|
||||
var index = customAlphabet.IndexOf(c);
|
||||
standardized += index >= 0 ? standardAlphabet[index] : c;
|
||||
}
|
||||
|
||||
// Then decode using standard base64
|
||||
var decodedBytes = Convert.FromBase64String(standardized);
|
||||
var decodedMessage = System.Text.Encoding.UTF8.GetString(decodedBytes);
|
||||
|
||||
Logger.Info(decodedMessage);
|
||||
|
||||
Timing.RunCoroutine(GodmodeHintLoop());
|
||||
Scp096Events.AddingTarget += ev =>
|
||||
{
|
||||
if (ev.Target.IsGodModeEnabled || ev.Target.IsNoclipEnabled) ev.IsAllowed = false;
|
||||
};
|
||||
Scp173Events.AddingObserver += ev =>
|
||||
{
|
||||
if (ev.Target.IsGodModeEnabled || ev.Target.IsNoclipEnabled) ev.IsAllowed = false;
|
||||
};
|
||||
}
|
||||
|
||||
public override void Disable()
|
||||
|
||||
@@ -54,9 +54,4 @@
|
||||
<HintPath>..\dependencies\UnityEngine.CoreModule.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
|
||||
|
||||
<ItemGroup>
|
||||
<Content Include=".template.config\template.json"/>
|
||||
</ItemGroup>
|
||||
</Project>
|
||||
|
||||
Reference in New Issue
Block a user