Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 2 additions & 3 deletions Cosmetics/Glows/GlowsHandler.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using Exiled.API.Features;
using Exiled.API.Features;
using Exiled.Events.EventArgs.Player;
using PlayerRoles;
using SCPCosmetics.Cosmetics.Hats;
Expand Down Expand Up @@ -36,10 +36,9 @@ public static GlowComponent SpawnGlow(Player player, Color color)
GlowComponent glowComp = player.GameObject.AddComponent<GlowComponent>();

glowComp.GlowLight = Exiled.API.Features.Toys.Light.Create(player.Position, null, null, true, color);
glowComp.GlowLight.ShadowEmission = false;
glowComp.GlowLight.Range = 1.15f;
glowComp.GlowLight.ShadowStrength = 0;
glowComp.GlowLight.Intensity = 5f;

thisHandler.PlayerLinkedCosmetics.Add(player.UserId, glowComp);

return glowComp;
Expand Down
5 changes: 2 additions & 3 deletions Cosmetics/Pets/PetComponent.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using CustomPlayerEffects;
using CustomPlayerEffects;
using Exiled.API.Features;
using MapEditorReborn.API.Extensions;
using MapEditorReborn.API.Features.Objects;
Expand Down Expand Up @@ -146,10 +146,9 @@ public override void OnDestroy()
try
{
PetNPC.ClearInventory();
PetNPC.Position = new Vector3(-9999f, -9999f, -9999f);
Timing.CallDelayed(0.5f, () =>
{
NetworkServer.Destroy(PetNPC.GameObject);
PetNPC.Destroy();
});
}
catch (Exception e)
Expand Down
7 changes: 2 additions & 5 deletions Cosmetics/Pets/PetsHandler.cs
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
using Exiled.API.Enums;
using Exiled.API.Enums;
using Exiled.API.Extensions;
using Exiled.API.Features;
using Exiled.API.Features.Components;
Expand Down Expand Up @@ -183,10 +183,7 @@ public static void SpawnPet(string Name, string Color, RoleTypeId Role, ItemType
public static Npc SpawnFix(string name, RoleTypeId role, int id = 0, Vector3? position = null)
{
GameObject gameObject = UnityEngine.Object.Instantiate(NetworkManager.singleton.playerPrefab);
Npc npc = new(gameObject)
{
IsNPC = true
};
Npc npc = new(gameObject);
try
{
npc.ReferenceHub.roleManager.InitializeNewRole(RoleTypeId.None, RoleChangeReason.None);
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ Made for v13.0.0 of SCP:SL and v7.0.0 of Exiled and onward by creepycats.
This plugin contains code originally from SCPStats, [you can find its source code here](https://github.com/SCPStats/Plugin/).

## Installation
**This Plugin Requires MapEditorReborn, [you can download it here](https://github.com/Michal78900/MapEditorReborn/releases)**
**This Plugin Requires [MapEditorReborn](https://discord.gg/9qV8fuCKeP) (Needs to be version from day 12/26/2024), [you can download it here](https://discord.com/channels/947849283514814486/995694845903524002)**

After you've installed MapEditorReborn, go to [Releases](https://github.com/creepycats/SCPHats/releases) and download the latest Plugin file.

Expand Down
82 changes: 45 additions & 37 deletions SCPCosmetics.csproj
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
<PropertyGroup>
Expand Down Expand Up @@ -74,78 +74,86 @@
<Compile Include="Types\Pets\SchematicPetConfig.cs" />
</ItemGroup>
<ItemGroup>
<Reference Include="0Harmony %281%29">
<HintPath>..\..\..\Downloads\0Harmony (1).dll</HintPath>
</Reference>
<Reference Include="0Harmony, Version=2.2.2.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>packages\Lib.Harmony.2.2.2\lib\net48\0Harmony.dll</HintPath>
</Reference>
<Reference Include="Assembly-CSharp">
<HintPath>..\Exiled Master References\Assembly-CSharp.dll</HintPath>
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\Assembly-CSharp-Publicized.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="Assembly-CSharp-firstpass, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\Exiled Master References\Assembly-CSharp-firstpass.dll</HintPath>
<HintPath>..\..\..\Downloads\steamcmd\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\ExMod.Exiled.9.5.1\lib\net48\Assembly-CSharp-Publicized.dll</HintPath>
<Private>True</Private>
</Reference>
<Reference Include="CommandSystem.Core, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>packages\EXILED.7.2.0\lib\net48\CommandSystem.Core.dll</HintPath>
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\CommandSystem.Core.dll</HintPath>
</Reference>
<Reference Include="Exiled.API, Version=8.4.2.0, Culture=neutral, processorArchitecture=AMD64">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\AppData\Roaming\EXILED\Plugins\dependencies\Exiled.API.dll</HintPath>
<Reference Include="Exiled.API, Version=9.5.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\Exiled.API.dll</HintPath>
</Reference>
<Reference Include="Exiled.CreditTags, Version=8.0.2.0, Culture=neutral, processorArchitecture=AMD64">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\AppData\Roaming\EXILED\Plugins\Exiled.CreditTags.dll</HintPath>
<Reference Include="Exiled.CreditTags, Version=9.5.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\Exiled.CreditTags.dll</HintPath>
</Reference>
<Reference Include="Exiled.CustomItems, Version=8.0.2.0, Culture=neutral, processorArchitecture=AMD64">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\AppData\Roaming\EXILED\Plugins\Exiled.CustomItems.dll</HintPath>
<Reference Include="Exiled.CustomItems, Version=9.5.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\Exiled.CustomItems.dll</HintPath>
</Reference>
<Reference Include="Exiled.CustomRoles, Version=8.0.2.0, Culture=neutral, processorArchitecture=AMD64">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\AppData\Roaming\EXILED\Plugins\Exiled.CustomRoles.dll</HintPath>
<Reference Include="Exiled.CustomRoles, Version=9.5.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\Exiled.CustomRoles.dll</HintPath>
</Reference>
<Reference Include="Exiled.Events, Version=8.0.2.0, Culture=neutral, processorArchitecture=AMD64">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\AppData\Roaming\EXILED\Plugins\Exiled.Events.dll</HintPath>
<Reference Include="Exiled.Events, Version=9.5.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\Exiled.Events.dll</HintPath>
</Reference>
<Reference Include="Exiled.Permissions, Version=8.0.2.0, Culture=neutral, processorArchitecture=AMD64">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\AppData\Roaming\EXILED\Plugins\Exiled.Permissions.dll</HintPath>
<Reference Include="Exiled.Loader, Version=9.5.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\Exiled.Loader.dll</HintPath>
</Reference>
<Reference Include="Exiled.Permissions, Version=9.5.1.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\Exiled.Permissions.dll</HintPath>
</Reference>
<Reference Include="Exiled.Updater, Version=3.1.2.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\EXILED.7.2.0\lib\net48\Exiled.Updater.dll</HintPath>
</Reference>
<Reference Include="MapEditorReborn, Version=1.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\AppData\Roaming\EXILED\Plugins\MapEditorReborn.dll</HintPath>
<HintPath>..\..\..\Downloads\MapEditorReborn.dll</HintPath>
</Reference>
<Reference Include="Mirror, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\Mirror.dll</HintPath>
<HintPath>..\..\..\Downloads\steamcmd\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">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\NorthwoodLib.dll</HintPath>
<Reference Include="NorthwoodLib, Version=1.3.1.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\NorthwoodLib.dll</HintPath>
</Reference>
<Reference Include="PluginAPI, Version=12.0.0.0, Culture=neutral, processorArchitecture=AMD64">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\PluginAPI.dll</HintPath>
<Reference Include="PluginAPI, Version=13.1.5.0, Culture=neutral, processorArchitecture=AMD64">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\PluginAPI.dll</HintPath>
</Reference>
<Reference Include="Pooling">
<HintPath>$(SL_REFERENCES)\Pooling.dll</HintPath>
<HintPath>..\..\..\Downloads\steamcmd\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\Pooling.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.ComponentModel.Composition" />
<Reference Include="System.Xml" />
<Reference Include="System.Xml.Linq" />
<Reference Include="Unity.TextMeshPro">
<HintPath>..\..\..\Downloads\steamcmd\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\Unity.TextMeshPro.dll</HintPath>
</Reference>
<Reference Include="UnityEngine">
<HintPath>..\..\..\Downloads\steamcmd\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.CoreModule">
<HintPath>$(SL_REFERENCES)\UnityEngine.CoreModule.dll</HintPath>
<HintPath>..\..\..\Downloads\steamcmd\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.CoreModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.PhysicsModule">
<HintPath>$(SL_REFERENCES)\UnityEngine.PhysicsModule.dll</HintPath>
<HintPath>..\..\..\Downloads\steamcmd\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\UnityEngine.PhysicsModule.dll</HintPath>
</Reference>
<Reference Include="YamlDotNet, Version=12.0.0.0, Culture=neutral, PublicKeyToken=ec19458f3c15af5e, processorArchitecture=MSIL">
<SpecificVersion>False</SpecificVersion>
<HintPath>..\..\..\..\..\..\SteamLibrary\steamapps\common\SCP Secret Laboratory Dedicated Server\SCPSL_Data\Managed\YamlDotNet.dll</HintPath>
<Reference Include="YamlDotNet, Version=11.0.0.0, Culture=neutral, PublicKeyToken=ec19458f3c15af5e, processorArchitecture=MSIL">
<HintPath>packages\ExMod.Exiled.9.5.1\lib\net48\YamlDotNet.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
Expand All @@ -154,4 +162,4 @@
</ItemGroup>
<ItemGroup />
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
</Project>
</Project>
6 changes: 3 additions & 3 deletions packages.config
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?>
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="EXILED" version="7.2.0" targetFramework="net48" />
<package id="ExMod.Exiled" version="9.5.1" targetFramework="net48" />
<package id="Lib.Harmony" version="2.2.2" targetFramework="net48" />
</packages>
</packages>