Fix items and NPCs not being searched for properly.
This commit is contained in:
parent
283dec89a0
commit
383633a823
1 changed files with 2 additions and 2 deletions
|
|
@ -248,7 +248,7 @@ namespace TShockAPI
|
||||||
}
|
}
|
||||||
//Method #2 - allows impartial matching
|
//Method #2 - allows impartial matching
|
||||||
var found = new List<Item>();
|
var found = new List<Item>();
|
||||||
for (int i = 1; i < Main.maxItemTypes; i++)
|
for (int i = -24; i < Main.maxItemTypes; i++)
|
||||||
{
|
{
|
||||||
try
|
try
|
||||||
{
|
{
|
||||||
|
|
@ -284,7 +284,7 @@ namespace TShockAPI
|
||||||
public List<NPC> GetNPCByName(string name)
|
public List<NPC> GetNPCByName(string name)
|
||||||
{
|
{
|
||||||
//Method #1 - must be exact match, allows support for different coloured slimes
|
//Method #1 - must be exact match, allows support for different coloured slimes
|
||||||
for (int i = 1; i < Main.maxNPCTypes; i++)
|
for (int i = -17; i < Main.maxNPCTypes; i++)
|
||||||
{
|
{
|
||||||
NPC npc = new NPC();
|
NPC npc = new NPC();
|
||||||
npc.SetDefaults(name);
|
npc.SetDefaults(name);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue