Fix build due to outdated PR merge lol

This commit is contained in:
Lucas Nicodemus 2022-11-09 23:24:39 -08:00
parent 41c4e541b8
commit 09b1e86c0c
No known key found for this signature in database

View file

@ -3511,7 +3511,7 @@ namespace TShockAPI
var plr = args.Data.ReadInt16();
var thingType = args.Data.ReadInt16();
var isKnownBoss = thingType > 0 && thingType < Main.maxNPCTypes && NPCID.Sets.MPAllowedEnemies[thingType];
var isKnownBoss = thingType > 0 && thingType < Terraria.ID.NPCID.Count && NPCID.Sets.MPAllowedEnemies[thingType];
if ((isKnownBoss || thingType == -16) && !args.Player.HasPermission(Permissions.summonboss))
{
TShock.Log.ConsoleDebug(GetString("GetDataHandlers / HandleSpawnBoss rejected boss {0} {1}", args.Player.Name, thingType));