Merge remote-tracking branch 'origin/general-devel' into old-code
This commit is contained in:
commit
846386f98a
2 changed files with 3 additions and 3 deletions
|
|
@ -979,7 +979,7 @@ namespace TShockAPI
|
|||
short type = args.Type;
|
||||
int index = args.Index;
|
||||
|
||||
if (index > Main.maxProjectiles || index < 0)
|
||||
if (index > Main.maxProjectiles)
|
||||
{
|
||||
args.Player.RemoveProjectile(ident, owner);
|
||||
args.Handled = true;
|
||||
|
|
|
|||
|
|
@ -832,7 +832,7 @@ namespace TShockAPI
|
|||
/// </summary>
|
||||
/// <param name="identity">identity</param>
|
||||
/// <param name="owner">owner</param>
|
||||
/// <returns>projectile ID or -1 if not found</returns>
|
||||
/// <returns>projectile ID</returns>
|
||||
public int SearchProjectile(short identity, int owner)
|
||||
{
|
||||
for (int i = 0; i < Main.maxProjectiles; i++)
|
||||
|
|
@ -840,7 +840,7 @@ namespace TShockAPI
|
|||
if (Main.projectile[i].identity == identity && Main.projectile[i].owner == owner)
|
||||
return i;
|
||||
}
|
||||
return -1;
|
||||
return 1000;
|
||||
}
|
||||
|
||||
/// <summary>
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue