diff --git a/TShockAPI/GetDataHandlers.cs b/TShockAPI/GetDataHandlers.cs index 2eb9be4f..755a9ff8 100644 --- a/TShockAPI/GetDataHandlers.cs +++ b/TShockAPI/GetDataHandlers.cs @@ -3462,12 +3462,16 @@ namespace TShockAPI if (OnNPCSpecial(args.Player, args.Data, id, type)) return true; - if (type == 1 && TShock.Config.Settings.DisableDungeonGuardian) + if (type == 1) { - TShock.Log.ConsoleDebug(GetString("GetDataHandlers / HandleSpecial rejected type 1 for {0}", args.Player.Name)); - args.Player.SendMessage(GetString("The Dungeon Guardian returned you to your spawn point."), Color.Purple); - args.Player.Spawn(PlayerSpawnContext.RecallFromItem); - return true; + if (!args.Player.HasPermission(Permissions.summonboss)) + { + args.Player.SendErrorMessage(GetString("You do not have permission to summon the Skeletron.")); + TShock.Log.ConsoleDebug(GetString($"GetDataHandlers / HandleNpcStrike rejected Skeletron summon from {args.Player.Name}")); + return true; + } + + return false; } else if (type == 2) { diff --git a/docs/changelog.md b/docs/changelog.md index 1c3d2766..f0e19fd2 100644 --- a/docs/changelog.md +++ b/docs/changelog.md @@ -92,6 +92,9 @@ Use past tense when adding new entries; sign your name off when you add or chang * Rewrote the `.dockerignore` file into a denylist. (@timschumi) * Added a new permission, `tshock.world.time.usemoondial`, for regulating use of Enchanted Moondial. (@Arthri) * Added a set of new permissions, `tshock.specialeffects.{type}`, for regulating use of new special effects(Packet 51) which are not yet recognized by TShock. (@Arthri) +* Added check for `tshock.npc.summonboss` permission for Skeletron summoning. (@Arthri) +* Fixed `DisableDungeonGuardian` disabling Skeletron summon instead. The config option is useless as of writing. (@Arthri) +* Added CI for Docker images. (@timschumi) ## TShock 5.2 * An additional option `pvpwithnoteam` is added at `PvPMode` to enable PVP with no team. (@CelestialAnarchy, #2617, @ATFGK)