Skip to content

Commit

Permalink
1.0.2 update
Browse files Browse the repository at this point in the history
Added to avoid removing player ragdolls that need to be resurrected for SCP-049 Also added to avoid removing player ragdolls in disguise for SCP-3114
  • Loading branch information
XingYeNotFish committed Sep 10, 2024
1 parent 4f41a9c commit ef389b1
Show file tree
Hide file tree
Showing 35 changed files with 35,033 additions and 30 deletions.
Binary file not shown.
Binary file not shown.
Binary file added .vs/Server Maid/v17/.suo
Binary file not shown.
78 changes: 78 additions & 0 deletions .vs/Server Maid/v17/DocumentLayout.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,78 @@
{
"Version": 1,
"WorkspaceRootPath": "C:\\Users\\TYUJH\\Desktop\\Plugin Project\\Server Maid\\",
"Documents": [
{
"AbsoluteMoniker": "D:0:0:{6B577E13-73E2-45FB-BAD8-19E93F31F5B6}|Server Maid\\Server Maid.csproj|c:\\users\\tyujh\\desktop\\plugin project\\server maid\\server maid\\plugin.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
"RelativeMoniker": "D:0:0:{6B577E13-73E2-45FB-BAD8-19E93F31F5B6}|Server Maid\\Server Maid.csproj|solutionrelative:server maid\\plugin.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
},
{
"AbsoluteMoniker": "D:0:0:{6B577E13-73E2-45FB-BAD8-19E93F31F5B6}|Server Maid\\Server Maid.csproj|c:\\users\\tyujh\\desktop\\plugin project\\server maid\\server maid\\maid.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}",
"RelativeMoniker": "D:0:0:{6B577E13-73E2-45FB-BAD8-19E93F31F5B6}|Server Maid\\Server Maid.csproj|solutionrelative:server maid\\maid.cs||{A6C744A8-0E4A-4FC6-886A-064283054674}"
}
],
"DocumentGroupContainers": [
{
"Orientation": 0,
"VerticalTabListWidth": 256,
"DocumentGroups": [
{
"DockedWidth": 200,
"SelectedChildIndex": 0,
"Children": [
{
"$type": "Document",
"DocumentIndex": 0,
"Title": "Plugin.cs",
"DocumentMoniker": "C:\\Users\\TYUJH\\Desktop\\Plugin Project\\Server Maid\\Server Maid\\Plugin.cs",
"RelativeDocumentMoniker": "Server Maid\\Plugin.cs",
"ToolTip": "C:\\Users\\TYUJH\\Desktop\\Plugin Project\\Server Maid\\Server Maid\\Plugin.cs",
"RelativeToolTip": "Server Maid\\Plugin.cs",
"ViewState": "AQIAAAgAAAAAAAAAAAAIwCEAAABCAAAA",
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
"WhenOpened": "2024-09-10T13:53:35.888Z",
"EditorCaption": ""
},
{
"$type": "Document",
"DocumentIndex": 1,
"Title": "Maid.cs",
"DocumentMoniker": "C:\\Users\\TYUJH\\Desktop\\Plugin Project\\Server Maid\\Server Maid\\Maid.cs",
"RelativeDocumentMoniker": "Server Maid\\Maid.cs",
"ToolTip": "C:\\Users\\TYUJH\\Desktop\\Plugin Project\\Server Maid\\Server Maid\\Maid.cs",
"RelativeToolTip": "Server Maid\\Maid.cs",
"ViewState": "AQIAAAAAAAAAAAAAAAAAAEoAAAAVAAAA",
"Icon": "ae27a6b0-e345-4288-96df-5eaf394ee369.000738|",
"WhenOpened": "2024-09-10T13:37:28.094Z",
"EditorCaption": ""
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{1c4feeaa-4718-4aa9-859d-94ce25d182ba}"
},
{
"$type": "Bookmark",
"Name": "ST:128:0:{1fc202d4-d401-403c-9834-5b218574bb67}"
},
{
"$type": "Bookmark",
"Name": "ST:129:0:{1fc202d4-d401-403c-9834-5b218574bb67}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{34e76e81-ee4a-11d0-ae2e-00a0c90fffc3}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{d78612c7-9962-4b83-95d9-268046dad23a}"
},
{
"$type": "Bookmark",
"Name": "ST:0:0:{3ae79031-e1bc-11d0-8f78-00a0c9110057}"
}
]
}
]
}
]
}
1 change: 1 addition & 0 deletions Server Maid/.vs/Server Maid.csproj.dtbcache.json
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"RootPath":"C:\\Users\\TYUJH\\Desktop\\Plugin Project\\Server Maid\\Server Maid","ProjectFileName":"Server Maid.csproj","Configuration":"Debug|AnyCPU","FrameworkPath":"","Sources":[{"SourceFile":"Command.cs"},{"SourceFile":"CommandTranslations.cs"},{"SourceFile":"Maid.cs"},{"SourceFile":"Plugin.cs"},{"SourceFile":"Properties\\AssemblyInfo.cs"},{"SourceFile":"XYlikeconfig.cs"},{"SourceFile":"obj\\Debug\\.NETFramework,Version=v4.8.AssemblyAttributes.cs"}],"References":[{"Reference":"D:\\steam\\steamapps\\common\\SCP Secret Laboratory Dedicated Server\\SCPSL_Data\\Managed\\publicized_assemblies\\Assembly-CSharp_publicized.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\Microsoft.CSharp.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\mscorlib.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\System.Core.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\System.Data.DataSetExtensions.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\System.Data.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\System.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\System.Net.Http.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\System.Xml.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""},{"Reference":"C:\\Program Files (x86)\\Reference Assemblies\\Microsoft\\Framework\\.NETFramework\\v4.8\\System.Xml.Linq.dll","ResolvedFrom":"","OriginalItemSpec":"","Name":"","EmbedInteropTypes":false,"CopyLocal":false,"IsProjectReference":false,"ProjectPath":""}],"Analyzers":[],"Outputs":[{"OutputItemFullPath":"C:\\Users\\TYUJH\\Desktop\\Plugin Project\\Server Maid\\Server Maid\\bin\\Debug\\Server Maid.dll","OutputItemRelativePath":"Server Maid.dll"},{"OutputItemFullPath":"C:\\Users\\TYUJH\\Desktop\\Plugin Project\\Server Maid\\Server Maid\\bin\\Debug\\Server Maid.pdb","OutputItemRelativePath":"Server Maid.pdb"}],"CopyToOutputEntries":[]}
15 changes: 15 additions & 0 deletions Server Maid/Maid.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@
using System.Collections.Generic;
using System.Linq;
using PlayerRoles;
using PlayerRoles.PlayableScps.Scp3114;
using Map = Exiled.API.Features.Map;

namespace Server_Maid
{
Expand All @@ -19,6 +21,7 @@ public static void Start()
{
MaidSystem_Coroutine = Timing.RunCoroutine(MaidSystem());
Log.Warn(Config.CleaningModuleEnabledServerConsoleMessages);
Plugin.DisguisedRagdolls.Clear();
}
}

Expand All @@ -27,6 +30,7 @@ public static void End(RoundEndedEventArgs e)
if (Config.IsCleaningModuleEnabled)
{
Timing.KillCoroutines(MaidSystem_Coroutine);
Plugin.DisguisedRagdolls.Clear();
}
}

Expand All @@ -48,6 +52,17 @@ public static IEnumerator<float> MaidSystem()
continue;
}
}

if (Plugin.DisguisedRagdolls.Contains(ragdoll))
{
continue;
}

if (!ragdoll.IsExpired)
{
continue;
}

ragdoll.Destroy();
int num = ragdollnum;
ragdollnum = num + 1;
Expand Down
25 changes: 23 additions & 2 deletions Server Maid/Plugin.cs
Original file line number Diff line number Diff line change
@@ -1,22 +1,26 @@
using Exiled.API.Features;
using System;
using System.Collections.Generic;
using Exiled.Events.EventArgs.Scp3114;

namespace Server_Maid
{
public class Plugin : Plugin<XYlikeconfig>
{
public override string Name { get; } = "Server Maid / 服务器女仆";
public override string Author { get; } = "XingYeNotFish";
public override Version Version { get; } = new Version(1, 0, 1);
public override Version Version { get; } = new Version(1, 0, 2);

public static Plugin Instance;

public static List<Ragdoll> DisguisedRagdolls = new List<Ragdoll>();
public override void OnEnabled()
{
Instance = this;
base.OnEnabled();
Exiled.Events.Handlers.Server.RoundStarted += Maid.Start;
Exiled.Events.Handlers.Server.RoundEnded += Maid.End;
Exiled.Events.Handlers.Scp3114.Disguised += Disguised;
Exiled.Events.Handlers.Scp3114.Revealing += Revealing;
Log.Info("Plugin has been enabled! / 插件已启用!");
}

Expand All @@ -26,7 +30,24 @@ public override void OnDisabled()
base.OnDisabled();
Exiled.Events.Handlers.Server.RoundStarted -= Maid.Start;
Exiled.Events.Handlers.Server.RoundEnded -= Maid.End;
Exiled.Events.Handlers.Scp3114.Disguised -= Disguised;
Exiled.Events.Handlers.Scp3114.Revealing -= Revealing;
Log.Info("Plugin has been disabled! / 插件已关闭!");
}

private void Disguised(DisguisedEventArgs e)
{
if (e.Player != null)
{
DisguisedRagdolls.Add(e.Ragdoll);
}
}
private void Revealing(RevealingEventArgs e)
{
if (e.Player != null)
{
DisguisedRagdolls.Remove(e.Scp3114.Ragdoll);
}
}
}
}
53 changes: 26 additions & 27 deletions Server Maid/Server Maid.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -34,54 +34,53 @@
</PropertyGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Assembly-CSharp-Publicized.dll</HintPath>
<Private>True</Private>
<HintPath>D:\steam\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Assembly-CSharp-firstpass">
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\Assembly-CSharp-firstpass.dll</HintPath>
<HintPath>D:\steam\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\Assembly-CSharp-firstpass.dll</HintPath>
</Reference>
<Reference Include="Assembly-CSharp-Publicized, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Assembly-CSharp-Publicized.dll</HintPath>
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\Assembly-CSharp-Publicized.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Assembly-CSharp_publicized">
<HintPath>D:\steam\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\publicized_assemblies\Assembly-CSharp_publicized.dll</HintPath>
</Reference>
<Reference Include="CommandSystem.Core, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\CommandSystem.Core.dll</HintPath>
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\CommandSystem.Core.dll</HintPath>
</Reference>
<Reference Include="Exiled.API, Version=8.2.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Exiled.API.dll</HintPath>
<Reference Include="Exiled.API, Version=8.11.0.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\Exiled.API.dll</HintPath>
</Reference>
<Reference Include="Exiled.CreditTags, Version=8.2.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Exiled.CreditTags.dll</HintPath>
<Reference Include="Exiled.CreditTags, Version=8.11.0.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\Exiled.CreditTags.dll</HintPath>
</Reference>
<Reference Include="Exiled.CustomItems, Version=8.2.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Exiled.CustomItems.dll</HintPath>
<Reference Include="Exiled.CustomItems, Version=8.11.0.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\Exiled.CustomItems.dll</HintPath>
</Reference>
<Reference Include="Exiled.CustomRoles, Version=8.2.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Exiled.CustomRoles.dll</HintPath>
<Reference Include="Exiled.CustomRoles, Version=8.11.0.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\Exiled.CustomRoles.dll</HintPath>
</Reference>
<Reference Include="Exiled.Events, Version=8.2.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Exiled.Events.dll</HintPath>
<Reference Include="Exiled.Events, Version=8.11.0.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\Exiled.Events.dll</HintPath>
</Reference>
<Reference Include="Exiled.Loader, Version=8.2.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Exiled.Loader.dll</HintPath>
<Reference Include="Exiled.Loader, Version=8.11.0.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\Exiled.Loader.dll</HintPath>
</Reference>
<Reference Include="Exiled.Permissions, Version=8.2.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Exiled.Permissions.dll</HintPath>
<Reference Include="Exiled.Permissions, Version=8.11.0.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\Exiled.Permissions.dll</HintPath>
</Reference>
<Reference Include="Exiled.Updater, Version=3.1.2.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\Exiled.Updater.dll</HintPath>
</Reference>
<Reference Include="Mirror">
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\Mirror.dll</HintPath>
<HintPath>D:\steam\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\Mirror.dll</HintPath>
</Reference>
<Reference Include="NorthwoodLib, Version=1.3.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\NorthwoodLib.dll</HintPath>
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\NorthwoodLib.dll</HintPath>
</Reference>
<Reference Include="PluginAPI, Version=12.0.0.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\PluginAPI.dll</HintPath>
<Reference Include="PluginAPI, Version=13.1.3.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\PluginAPI.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
Expand All @@ -92,16 +91,16 @@
<Reference Include="System.Net.Http" />
<Reference Include="System.Xml" />
<Reference Include="UnityEngine">
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.dll</HintPath>
<HintPath>D:\steam\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.CoreModule">
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.CoreModule.dll</HintPath>
<HintPath>D:\steam\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.CoreModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.PhysicsModule">
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.PhysicsModule.dll</HintPath>
<HintPath>D:\steam\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.PhysicsModule.dll</HintPath>
</Reference>
<Reference Include="YamlDotNet, Version=11.0.0.0, Culture=neutral, PublicKeyToken=ec19458f3c15af5e, processorArchitecture=MSIL">
<HintPath>..\packages\EXILED.8.2.1\lib\net48\YamlDotNet.dll</HintPath>
<HintPath>..\packages\EXILEDOFFICIAL.8.11.0\lib\net48\YamlDotNet.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
Binary file not shown.
Binary file not shown.
Empty file.
2 changes: 1 addition & 1 deletion Server Maid/packages.config
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="EXILED" version="8.2.1" targetFramework="net481" />
<package id="EXILEDOFFICIAL" version="8.11.0" targetFramework="net48" />
</packages>
Binary file added packages/EXILEDOFFICIAL.8.11.0/.signature.p7s
Binary file not shown.
Binary file not shown.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Loading

0 comments on commit ef389b1

Please sign in to comment.