Skip to content

Commit

Permalink
11.0.0 and translation fix
Browse files Browse the repository at this point in the history
  • Loading branch information
GrafDimenzio committed Aug 21, 2021
1 parent da63db3 commit 2eb763a
Show file tree
Hide file tree
Showing 6 changed files with 36 additions and 36 deletions.
10 changes: 5 additions & 5 deletions Scp035/EventHandlers.cs
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
using Synapse;
using Synapse.Api;
using Synapse.Api.Items;
using System.Collections.Generic;
using System.Linq;
using System.Collections.Generic;
using MEC;
using Synapse;
using Synapse.Api;
using Synapse.Api.Items;

namespace Scp035
{
Expand Down Expand Up @@ -100,7 +100,7 @@ public void Spawn035Item()
var items = Map.Get.Items.Where(x => x.State == Synapse.Api.Enum.ItemState.Map);
var pos = items.ElementAt(UnityEngine.Random.Range(0, items.Count())).Position;

var item = new SynapseItem(type + 100, 0f, 0, 0, 0);
var item = new SynapseItem(type + 100);
item.Drop(pos);
}
}
Expand Down
9 changes: 4 additions & 5 deletions Scp035/PluginClass.cs
Original file line number Diff line number Diff line change
@@ -1,6 +1,5 @@
using Synapse;
using Synapse.Api.Plugin;
using System.Collections.Generic;
using Synapse.Translation;

namespace Scp035
Expand All @@ -13,12 +12,12 @@ namespace Scp035
SynapseMajor = 2,
SynapseMinor = 5,
SynapsePatch = 3,
Version = "v.1.1.0"
Version = "v.1.1.1"
)]
public class PluginClass : AbstractPlugin
{
[Synapse.Api.Plugin.Config(section = "Scp035")]
public static Config Config;
[Config(section = "Scp035")]
public static PluginConfig Config;

[SynapseTranslation]
public static new SynapseTranslation<PluginTranslation> Translation { get; set; }
Expand All @@ -45,7 +44,7 @@ public override void Load()
Survived035 = "Das war <color=red>SCP-035</color> aber du hast es überlebt",
InteractWith035 = "Du kannst nicht mit einem <color=red>SCP-035</color> Item interagieren",
Pickup035 = "<b>Du hast <color=red>SCP-035</color> aufgehoben</b>",
Spawn035 = "<b>Du bist jetzt <color=red>SCP-035</color></b",
Spawn035 = "<b>Du bist jetzt <color=red>SCP-035</color></b>",
KilledBy035 = "<b>Du wurdest von <color=red>SCP-035</color> umgebracht</b>"
}, "GERMAN");

Expand Down
6 changes: 3 additions & 3 deletions Scp035/Config.cs → Scp035/PluginConfig.cs
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
using Synapse.Config;
using System.Collections.Generic;
using System.ComponentModel;
using System.Collections.Generic;
using Synapse.Config;

namespace Scp035
{
public class Config : AbstractConfigSection
public class PluginConfig : AbstractConfigSection
{
[Description("The Health of Scp035")]
public int Scp035Health = 150;
Expand Down
30 changes: 15 additions & 15 deletions Scp035/Scp035.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -31,23 +31,23 @@
<WarningLevel>4</WarningLevel>
</PropertyGroup>
<ItemGroup>
<Reference Include="0Harmony, Version=2.0.4.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Lib.Harmony.2.0.4\lib\net472\0Harmony.dll</HintPath>
<Reference Include="0Harmony, Version=2.1.1.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\Lib.Harmony.2.1.1\lib\net472\0Harmony.dll</HintPath>
</Reference>
<Reference Include="Assembly-CSharp, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\SynapseSL.2.5.3\lib\net472\Assembly-CSharp.dll</HintPath>
<HintPath>..\packages\SynapseSL.2.7.0-dev4\lib\net472\Assembly-CSharp.dll</HintPath>
</Reference>
<Reference Include="Assembly-CSharp-firstpass, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\SynapseSL.2.5.3\lib\net472\Assembly-CSharp-firstpass.dll</HintPath>
<HintPath>..\packages\SynapseSL.2.7.0-dev4\lib\net472\Assembly-CSharp-firstpass.dll</HintPath>
</Reference>
<Reference Include="LiteDB, Version=5.0.9.0, Culture=neutral, PublicKeyToken=4ee40123013c9f27, processorArchitecture=MSIL">
<HintPath>..\packages\LiteDB.5.0.9\lib\net45\LiteDB.dll</HintPath>
<Reference Include="LiteDB, Version=5.0.11.0, Culture=neutral, PublicKeyToken=4ee40123013c9f27, processorArchitecture=MSIL">
<HintPath>..\packages\LiteDB.5.0.11\lib\net45\LiteDB.dll</HintPath>
</Reference>
<Reference Include="Mirror, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\SynapseSL.2.5.3\lib\net472\Mirror.dll</HintPath>
<HintPath>..\packages\SynapseSL.2.7.0-dev4\lib\net472\Mirror.dll</HintPath>
</Reference>
<Reference Include="Synapse, Version=2.5.3.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\SynapseSL.2.5.3\lib\net472\Synapse.dll</HintPath>
<Reference Include="Synapse, Version=2.7.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\SynapseSL.2.7.0-dev4\lib\net472\Synapse.dll</HintPath>
</Reference>
<Reference Include="System" />
<Reference Include="System.Core" />
Expand All @@ -62,21 +62,21 @@
<Reference Include="System.Net.Http" />
<Reference Include="System.Xml" />
<Reference Include="UnityEngine, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\SynapseSL.2.5.3\lib\net472\UnityEngine.dll</HintPath>
<HintPath>..\packages\SynapseSL.2.7.0-dev4\lib\net472\UnityEngine.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.CoreModule, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\SynapseSL.2.5.3\lib\net472\UnityEngine.CoreModule.dll</HintPath>
<HintPath>..\packages\SynapseSL.2.7.0-dev4\lib\net472\UnityEngine.CoreModule.dll</HintPath>
</Reference>
<Reference Include="UnityEngine.PhysicsModule, Version=0.0.0.0, Culture=neutral, processorArchitecture=MSIL">
<HintPath>..\packages\SynapseSL.2.5.3\lib\net472\UnityEngine.PhysicsModule.dll</HintPath>
<HintPath>..\packages\SynapseSL.2.7.0-dev4\lib\net472\UnityEngine.PhysicsModule.dll</HintPath>
</Reference>
<Reference Include="YamlDotNet, Version=8.0.0.0, Culture=neutral, PublicKeyToken=ec19458f3c15af5e, processorArchitecture=MSIL">
<HintPath>..\packages\YamlDotNet.8.1.2\lib\net45\YamlDotNet.dll</HintPath>
<Reference Include="YamlDotNet, Version=11.0.0.0, Culture=neutral, PublicKeyToken=ec19458f3c15af5e, processorArchitecture=MSIL">
<HintPath>..\packages\YamlDotNet.11.2.1\lib\net45\YamlDotNet.dll</HintPath>
</Reference>
</ItemGroup>
<ItemGroup>
<Compile Include="EventHandlers.cs" />
<Compile Include="Config.cs" />
<Compile Include="PluginConfig.cs" />
<Compile Include="PluginTranslation.cs" />
<Compile Include="Scp035PlayerScript.cs" />
<Compile Include="PluginClass.cs" />
Expand Down
9 changes: 5 additions & 4 deletions Scp035/Scp035PlayerScript.cs
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
using MEC;
using Synapse.Api;
using Synapse.Api.Enum;
using System.Collections.Generic;

namespace Scp035
Expand All @@ -22,7 +23,7 @@ public Scp035PlayerScript() { }
public override void Spawn()
{
if(_target == null)
Player.RoleType = RoleType.ChaosInsurgency;
Player.RoleType = RoleType.ChaosRifleman;
else
{
Player.RoleType = _target.RoleType;
Expand All @@ -35,9 +36,9 @@ public override void Spawn()
}

Timing.CallDelayed(0.2f, () => Player.Position = _target.Position);
Player.Ammo5 = _target.Ammo5;
Player.Ammo7 = _target.Ammo7;
Player.Ammo9 = _target.Ammo9;

foreach (var type in (AmmoType[])System.Enum.GetValues(typeof(AmmoType)))
Player.AmmoBox[type] = _target.AmmoBox[type];

_target.RoleID = (int)RoleType.Spectator;

Expand Down
8 changes: 4 additions & 4 deletions Scp035/packages.config
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<?xml version="1.0" encoding="utf-8"?>
<packages>
<package id="Lib.Harmony" version="2.0.4" targetFramework="net472" />
<package id="LiteDB" version="5.0.9" targetFramework="net472" />
<package id="SynapseSL" version="2.5.3" targetFramework="net472" />
<package id="Lib.Harmony" version="2.1.1" targetFramework="net472" />
<package id="LiteDB" version="5.0.11" targetFramework="net472" />
<package id="SynapseSL" version="2.7.0-dev4" targetFramework="net472" />
<package id="System.Runtime.CompilerServices.Unsafe" version="4.5.2" targetFramework="net472" />
<package id="YamlDotNet" version="8.1.2" targetFramework="net472" />
<package id="YamlDotNet" version="11.2.1" targetFramework="net472" />
</packages>

0 comments on commit 2eb763a

Please sign in to comment.