Skip to content

Commit

Permalink
Merge pull request #5 from bladuk/exiledv8
Browse files Browse the repository at this point in the history
Update to Exiled V8 and SCP:SL 13.2
  • Loading branch information
bladuk authored Sep 22, 2023
2 parents 83e690d + 4fded5b commit 785fd8a
Show file tree
Hide file tree
Showing 12 changed files with 136 additions and 69 deletions.
50 changes: 49 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
## Ignore Visual Studio temporary files, build results, and
## files generated by popular Visual Studio add-ons.
##
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
## Get latest from https://github.com/github/gitignore/blob/main/VisualStudio.gitignore

# User-specific files
*.rsuser
Expand All @@ -23,6 +23,7 @@ mono_crash.*
[Rr]eleases/
x64/
x86/
[Ww][Ii][Nn]32/
[Aa][Rr][Mm]/
[Aa][Rr][Mm]64/
bld/
Expand Down Expand Up @@ -61,6 +62,9 @@ project.lock.json
project.fragment.lock.json
artifacts/

# ASP.NET Scaffolding
ScaffoldingReadMe.txt

# StyleCop
StyleCopReport.xml

Expand All @@ -86,6 +90,7 @@ StyleCopReport.xml
*.tmp_proj
*_wpftmp.csproj
*.log
*.tlog
*.vspscc
*.vssscc
.builds
Expand Down Expand Up @@ -137,6 +142,11 @@ _TeamCity*
.axoCover/*
!.axoCover/settings.json

# Coverlet is a free, cross platform Code Coverage Tool
coverage*.json
coverage*.xml
coverage*.info

# Visual Studio code coverage results
*.coverage
*.coveragexml
Expand Down Expand Up @@ -284,6 +294,17 @@ node_modules/
# Visual Studio 6 auto-generated workspace file (contains which files were open etc.)
*.vbw

# Visual Studio 6 auto-generated project file (contains which files were open etc.)
*.vbp

# Visual Studio 6 workspace and project file (working project files containing files to include in project)
*.dsw
*.dsp

# Visual Studio 6 technical files
*.ncb
*.aps

# Visual Studio LightSwitch build output
**/*.HTMLClient/GeneratedArtifacts
**/*.DesktopClient/GeneratedArtifacts
Expand Down Expand Up @@ -340,6 +361,9 @@ ASALocalRun/
# Local History for Visual Studio
.localhistory/

# Visual Studio History (VSHistory) files
.vshistory/

# BeatPulse healthcheck temp database
healthchecksdb

Expand All @@ -348,3 +372,27 @@ MigrationBackup/

# Ionide (cross platform F# VS Code tools) working folder
.ionide/

# Fody - auto-generated XML schema
FodyWeavers.xsd

# VS Code files for those working on multiple tools
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
*.code-workspace

# Local History for Visual Studio Code
.history/

# Windows Installer files from build outputs
*.cab
*.msi
*.msix
*.msm
*.msp

# JetBrains Rider
*.sln.iml
3 changes: 1 addition & 2 deletions ScpsInfoDisplay-NWAPI/EventHandlers.cs
Original file line number Diff line number Diff line change
Expand Up @@ -80,8 +80,7 @@ private string ProcessStringVariables(string raw, Player observer, Player target
.Replace("%079experience", tier.RelativeExp.ToString());
break;
case Scp106Role scp106:
scp106.SubroutineModule.TryGetSubroutine(out Scp106Vigor vigor);
raw = raw.Replace("%106vigor%", Math.Floor(vigor.VigorAmount * 100).ToString());
raw = raw.Replace("%106vigor%", Math.Floor(scp106.TargetStats.GetModule<Scp106Vigor>().CurValue * 100).ToString());
break;

}
Expand Down
24 changes: 2 additions & 22 deletions ScpsInfoDisplay-NWAPI/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
using System.Reflection;
using System.Runtime.InteropServices;

// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("ScpsInfoDisplay")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
Expand All @@ -12,24 +9,7 @@
[assembly: AssemblyCopyright("Copyright © 2022")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("DE55514B-C887-4021-80A4-6572F4EE1894")]

// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.0.0.0")]
[assembly: AssemblyFileVersion("2.0.0.0")]
[assembly: AssemblyVersion("2.0.2.0")]
[assembly: AssemblyFileVersion("2.0.2.0")]
2 changes: 1 addition & 1 deletion ScpsInfoDisplay-NWAPI/ScpsInfoDisplay.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ internal sealed class ScpsInfoDisplay
[PluginConfig]
public Config Config;

[PluginEntryPoint("ScpsInfoDisplay", "2.0.1", "A plugin that displays information about SCPs in player's team.", "bladuk.")]
[PluginEntryPoint("ScpsInfoDisplay", "2.0.2", "A plugin that displays information about SCPs in player's team.", "bladuk.")]
private void LoadPlugin()
{
Singleton = this;
Expand Down
23 changes: 16 additions & 7 deletions ScpsInfoDisplay-NWAPI/ScpsInfoDisplay.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -34,26 +34,32 @@
</PropertyGroup>
<ItemGroup>
<Reference Include="Assembly-CSharp">
<HintPath>..\Assembly-CSharp_publicized.dll</HintPath>
<HintPath>..\..\References\Assembly-CSharp-Publicized.dll</HintPath>
</Reference>
<Reference Include="Assembly-CSharp-firstpass">
<HintPath>..\Assembly-CSharp-firstpass.dll</HintPath>
<HintPath>..\..\nwapi_references\Assembly-CSharp-firstpass.dll</HintPath>
</Reference>
<Reference Include="Mirror">
<HintPath>..\Mirror.dll</HintPath>
<HintPath>..\..\nwapi_references\Mirror.dll</HintPath>
</Reference>
<Reference Include="NorthwoodLib">
<HintPath>..\NorthwoodLib.dll</HintPath>
<HintPath>..\..\nwapi_references\NorthwoodLib.dll</HintPath>
</Reference>
<Reference Include="PluginAPI">
<HintPath>..\PluginAPI.dll</HintPath>
<Reference Include="PluginAPI, Version=13.1.1.0, Culture=neutral, processorArchitecture=Amd64">
<HintPath>..\packages\Northwood.PluginAPI.13.1.1\lib\net48\PluginAPI.dll</HintPath>
</Reference>
<Reference Include="Pooling">
<HintPath>..\..\References\Pooling.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
<Reference Include="System.Data" />
<Reference Include="System.Xml" />
<Reference Include="UnityEngine.CoreModule">
<HintPath>..\UnityEngine.CoreModule.dll</HintPath>
<HintPath>..\..\nwapi_references\UnityEngine.CoreModule.dll</HintPath>
</Reference>
<Reference Include="YamlDotNet, Version=11.0.0.0, Culture=neutral, PublicKeyToken=ec19458f3c15af5e, processorArchitecture=MSIL">
<HintPath>..\packages\YamlDotNet.11.0.1\lib\net45\YamlDotNet.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
Expand All @@ -63,6 +69,9 @@
<Compile Include="ScpsInfoDisplay.cs" />
<Compile Include="Properties\AssemblyInfo.cs" />
</ItemGroup>
<ItemGroup>
<None Include="packages.config" />
</ItemGroup>
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
Expand Down
8 changes: 6 additions & 2 deletions ScpsInfoDisplay.sln
Original file line number Diff line number Diff line change
Expand Up @@ -5,16 +5,20 @@ VisualStudioVersion = 17.0.32014.148
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ScpsInfoDisplay", "ScpsInfoDisplay\ScpsInfoDisplay.csproj", "{8DAA7834-8141-448E-8694-EBE9F4800C66}"
EndProject
Project("{DE55514B-C887-4021-80A4-6572F4EE1894}") = "ScpsInfoDisplay-NWAPI", "ScpsInfoDisplay-NWAPI\ScpsInfoDisplay.csproj", "{DE55514B-C887-4021-80A4-6572F4EE1894}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{8DAA7834-8141-448E-8694-EBE9F4800C66}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{8DAA7834-8141-448E-8694-EBE9F4800C66}.Debug|Any CPU.Build.0 = Debug|Any CPU
{8DAA7834-8141-448E-8694-EBE9F4800C66}.Release|Any CPU.ActiveCfg = Release|Any CPU
{8DAA7834-8141-448E-8694-EBE9F4800C66}.Release|Any CPU.Build.0 = Release|Any CPU
{8DAA7834-8141-448E-8694-EBE9F4800C66}.Debug|Any CPU.ActiveCfg = Release|Any CPU
{8DAA7834-8141-448E-8694-EBE9F4800C66}.Debug|Any CPU.Build.0 = Release|Any CPU
{DE55514B-C887-4021-80A4-6572F4EE1894}.Debug|Any CPU.ActiveCfg = Release|Any CPU
{DE55514B-C887-4021-80A4-6572F4EE1894}.Debug|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
10 changes: 10 additions & 0 deletions ScpsInfoDisplay/App.config
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?xml version="1.0" encoding="utf-8"?><configuration>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="NorthwoodLib" publicKeyToken="null" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-1.3.0.0" newVersion="1.3.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
8 changes: 7 additions & 1 deletion ScpsInfoDisplay/Config.cs
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ public class Config : IConfig
{
[Description("Is the plugin enabled?")]
public bool IsEnabled { get; set; } = true;

[Description("Display strings. Format: Role, display string.")]
public Dictionary<RoleTypeId, string> DisplayStrings { get; set; } = new Dictionary<RoleTypeId, string>()
{
Expand All @@ -18,16 +19,21 @@ public class Config : IConfig
{ RoleTypeId.Scp096, "<color=#D51D1D>SCP-096 [%healthpercent%%] %distance%</color>" },
{ RoleTypeId.Scp106, "<color=#D51D1D>SCP-106 [%healthpercent%%] Vigor: %106vigor%% %distance%</color>" },
{ RoleTypeId.Scp173, "<color=#D51D1D>SCP-173 [%healthpercent%%] %distance%</color>" },
{ RoleTypeId.Scp939, "<color=#D51D1D>SCP-939 [%healthpercent%%] %distance%</color>" },
{ RoleTypeId.Scp939, "<color=#D51D1D>SCP-939 [%healthpercent%%] %distance%</color>" }
};

[Description("Custom roles integrations. Format: SessionVariable that marks that the player belongs to that role, display string.")]
public Dictionary<string, string> CustomRolesIntegrations { get; set; } = new Dictionary<string, string>();

[Description("Display string alignment. Possible values: Left, Center, Right.")]
public TextAlignment TextAlignment { get; set; } = TextAlignment.Right;

[Description("Display text position offset.")]
public sbyte TextPositionOffset { get; set; } = 30;

[Description("The player seeing the list will be highlighted with the special marker to the left. Leave it empty if disabled.")]
public string PlayersMarker { get; set; } = "<color=#D51D1D>You --></color>";

[Description("Display debug messages in server console?")]
public bool Debug { get; set; } = false;
}
Expand Down
2 changes: 1 addition & 1 deletion ScpsInfoDisplay/EventHandlers.cs
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@

namespace ScpsInfoDisplay
{
internal class EventHandlers
internal sealed class EventHandlers
{
private CoroutineHandle _displayCoroutine;

Expand Down
24 changes: 2 additions & 22 deletions ScpsInfoDisplay/Properties/AssemblyInfo.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
using System.Reflection;
using System.Runtime.InteropServices;

// General Information about an assembly is controlled through the following
// set of attributes. Change these attribute values to modify the information
// associated with an assembly.
[assembly: AssemblyTitle("ScpsInfoDisplay")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
Expand All @@ -12,24 +9,7 @@
[assembly: AssemblyCopyright("Copyright © 2022")]
[assembly: AssemblyTrademark("")]
[assembly: AssemblyCulture("")]

// Setting ComVisible to false makes the types in this assembly not visible
// to COM components. If you need to access a type in this assembly from
// COM, set the ComVisible attribute to true on that type.
[assembly: ComVisible(false)]

// The following GUID is for the ID of the typelib if this project is exposed to COM
[assembly: Guid("8daa7834-8141-448e-8694-ebe9f4800c66")]

// Version information for an assembly consists of the following four values:
//
// Major Version
// Minor Version
// Build Number
// Revision
//
// You can specify all the values or you can default the Build and Revision Numbers
// by using the '*' as shown below:
// [assembly: AssemblyVersion("1.0.*")]
[assembly: AssemblyVersion("2.0.1.0")]
[assembly: AssemblyFileVersion("2.0.1.0")]
[assembly: AssemblyVersion("2.0.2.0")]
[assembly: AssemblyFileVersion("2.0.2.0")]
4 changes: 2 additions & 2 deletions ScpsInfoDisplay/ScpsInfoDisplay.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,8 @@ internal class ScpsInfoDisplay : Plugin<Config>
public override string Prefix => "scpsinfodisplay";
public override string Name => "ScpsInfoDisplay";
public override string Author => "bladuk.";
public override Version Version { get; } = new Version(2, 0, 1);
public override Version RequiredExiledVersion { get; } = new Version(6, 0, 0);
public override Version Version { get; } = new Version(2, 0, 2);
public override Version RequiredExiledVersion { get; } = new Version(8, 2, 1);
public static ScpsInfoDisplay Singleton = new ScpsInfoDisplay();
private EventHandlers _eventHandlers;

Expand Down
Loading

0 comments on commit 785fd8a

Please sign in to comment.