Skip to content

Commit

Permalink
Merge pull request #302 from Controllerdestiny/main
Browse files Browse the repository at this point in the history
修复: EconomicsAPI 无法生成弹幕以及陷阱弹幕无法对敌怪照成伤害
  • Loading branch information
Controllerdestiny authored Jul 15, 2024
2 parents 16e1c8e + db91d20 commit 56fa86a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 2 additions & 0 deletions Economics.Projectile/Plugin.cs
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,7 @@ private void Projectile_Damage(On.Terraria.Projectile.orig_Damage orig, Terraria
self.Minion_FindTargetInRange(1500, ref id, false);
}
}
orig(self);
}

private void Projectile_Minion_FindTargetInRange(On.Terraria.Projectile.orig_Minion_FindTargetInRange orig, Terraria.Projectile self, int startAttackRange, ref int attackTarget, bool skipIfCannotHitWithOwnBody, Func<Entity, int, bool> customEliminationCheck)
Expand Down Expand Up @@ -115,6 +116,7 @@ private void Projectile_Minion_FindTargetInRange(On.Terraria.Projectile.orig_Min
}
}
}
orig(self, startAttackRange, ref attackTarget, skipIfCannotHitWithOwnBody, customEliminationCheck);
}

private void Onupdate(EventArgs args)
Expand Down
2 changes: 1 addition & 1 deletion EconomicsAPI/Utils/SpawnProjectile.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public static int NewProjectile(IEntitySource spawnSource, float X, float Y, flo
Owner = Main.myPlayer;
}
int num = 1000;
for (int i = 9999; i > 0; i--)
for (int i = 999; i > 0; i--)
{
if (!Main.projectile[i].active)
{
Expand Down

0 comments on commit 56fa86a

Please sign in to comment.