Skip to content

Commit a6b12ff

Browse files
authored
Merge pull request #21 from cactus-patch/Beta-Branch
I have tested this and have found no bugs nor could I replicate the workstation bug
2 parents d7eeea3 + e69bd8c commit a6b12ff

27 files changed

Lines changed: 440 additions & 592 deletions

ChangeLog.md

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1 @@
1-
># Update 3.1.0
2-
>
3-
>>## SCP-1289 (formerly <i>'Coin'</i>)
4-
>>> #### Renamed the coin
5-
>>> #### Added death and winning notes
6-
>>>> Due to a limitation of Exiled only the player who gets killed by the coin can see the new effects added by yours truly
7-
>>
8-
>>## Tranq
9-
>>> Made the player who got tranqed invulnerable but unable to use any items (humans)
10-
>>
11-
>>## Genaral code
12-
>>> Added some notes in the 'Util.cs' file for those who want to add on to this
1+
>#Update 3.2.1

Commands/CustomKeycard

Lines changed: 0 additions & 80 deletions
This file was deleted.

Commands/Debug/AdminPlastic.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ namespace ExtendedItems.Commands.Debug
66
[CommandHandler(typeof(ClientCommandHandler))]
77
class PlasticDebug : ICommand
88
{
9-
9+
1010
public string Command => "Ddetonate";
1111

1212
public string[] Aliases => ["Ddet", "Dd", "Dboom"];

Commands/Debug/Debug.cs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
using CommandSystem;
22
using Exiled.API.Features;
3-
using ExtendedItems.Commands.GuideBook;
43

54
namespace ExtendedItems.Commands.Debug
65
{
@@ -11,7 +10,7 @@ internal sealed class Debug : ParentCommand
1110

1211
public static Debug Instance { get; } = new();
1312
public override string Command => "Debug";
14-
public override string[] Aliases => [ "db" ];
13+
public override string[] Aliases => ["db"];
1514
public override string Description => "Overlord command for debugging the ExtendedItems plugin";
1615

1716
public override void LoadGeneratedCommands()
@@ -20,7 +19,7 @@ public override void LoadGeneratedCommands()
2019
}
2120
protected override bool ExecuteParent(ArraySegment<string> arguments, ICommandSender sender, out string response)
2221
{
23-
if(!sender.CheckPermission(Plugin.Instance!.Config.DebugPermissions))
22+
if (!sender.CheckPermission(Plugin.Instance!.Config.DebugPermissions))
2423
{
2524
response = "<color=red>Permission Denied.</color>";
2625
Log.Error($"{sender} tried to access admin commands!");

Commands/Debug/Locate.cs

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,15 @@
1-
using System.Text;
21
using CommandSystem;
3-
42
using Exiled.API.Features;
5-
using Exiled.API.Features.Pools;
6-
using Exiled.CustomItems;
7-
using Exiled.CustomItems.API;
83
using Exiled.CustomItems.API.Features;
4+
using System.Text;
95

106

117
namespace ExtendedItems.Commands.Debug
128
{
139
internal sealed class Locate : ICommand
1410
{
1511
public static Locate Instance { get; } = new();
16-
public Locate() {}
12+
public Locate() { }
1713
public string Command => "Locate";
1814
public string[] Aliases => ["loc", "find"];
1915
public string Description => "Locates all (unless a valid ID is given) Custom Items";

Commands/GuideBook/Coin.cs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Text;
5-
using System.Threading.Tasks;
6-
using CommandSystem;
1+
using CommandSystem;
72

83
namespace ExtendedItems.Commands.GuideBook
94
{
@@ -13,7 +8,7 @@ private Coinc() { }
138

149
public static Coinc Instance { get; } = new();
1510
public string Command => "coin";
16-
public string[] Aliases => [ "1289" ];
11+
public string[] Aliases => ["1289"];
1712
public string Description => "Information on SCP-1289 (aka \"Coin\" or \"Colin\") ";
1813
public bool Execute(ArraySegment<string> arguments, ICommandSender sender, out string response)
1914
{

Commands/GuideBook/Help.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Text;
5-
using System.Threading.Tasks;
6-
using CommandSystem;
1+
using CommandSystem;
72

83
namespace ExtendedItems.Commands.GuideBook
94
{

Commands/GuideBook/Sniper.cs

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Text;
5-
using System.Threading.Tasks;
6-
using CommandSystem;
1+
using CommandSystem;
72

83
namespace ExtendedItems.Commands.GuideBook
94
{

Commands/Main.cs

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,4 @@
1-
using System;
2-
using System.Collections.Generic;
3-
using System.Linq;
4-
using System.Text;
5-
using System.Threading.Tasks;
6-
using CommandSystem;
1+
using CommandSystem;
72

83
namespace ExtendedItems.Commands
94
{
@@ -13,7 +8,7 @@ internal sealed class Main : ParentCommand
138
public Main() { LoadGeneratedCommands(); }
149

1510
public override string Command => "ExtendedItems";
16-
public override string[] Aliases => [ "ei", "extendeditems", "eis" ];
11+
public override string[] Aliases => ["ei", "extendeditems", "eis"];
1712
public override string Description => "Overlord command for the ExtendedItems plugin";
1813

1914
public override void LoadGeneratedCommands()

Commands/Plastic.cs

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
namespace ExtendedItems.Commands
55
{
66
[CommandHandler(typeof(ClientCommandHandler))]
7+
78
class Plastic : ICommand
89
{
910
public string Command => "detonate";
@@ -15,6 +16,7 @@ class Plastic : ICommand
1516
public bool Execute(ArraySegment<string> arguments, ICommandSender sender, out string response)
1617
{
1718
Player ply = Player.Get(sender);
19+
Log.Debug($"Player: {ply.Nickname} executed the detonate command.");
1820
if (!Items.Plastic.PlacedCharges.ContainsValue(ply))
1921
{
2022
response = "\n<color=red>You've haven't placed any C4 charges!</color>";
@@ -24,12 +26,12 @@ public bool Execute(ArraySegment<string> arguments, ICommandSender sender, out s
2426
int i = 0;
2527
foreach (var charge in Items.Plastic.PlacedCharges.ToList())
2628
{
27-
float posy = charge.Key.Position.y;
29+
float posy = charge.Key.Position.y;
2830
if (charge.Value != ply) continue;
29-
30-
if (ply.Position.y >= posy - 100 && ply.Position.y <= posy + 100 )
31+
32+
if (ply.Position.y >= posy - 100 && ply.Position.y <= posy + 100)
3133
{
32-
Items.Plastic.Instance.Handler(charge.Key, Items.Plastic.C4RemoveMethod.Detonate);
34+
Items.Plastic.Instance.Handler(charge.Key, Items.Plastic.C4RemoveMethod.Detonate, ply);
3335
i++;
3436
}
3537
else

0 commit comments

Comments
 (0)