Terraria v1.4.4.9
Terraria source code documentation
Loading...
Searching...
No Matches

◆ DropSelectedItem_InterruptActionsThatUseAnimations()

void Terraria.Player.DropSelectedItem_InterruptActionsThatUseAnimations ( )
inlineprivate

Definition at line 4405 of file Player.cs.

4406 {
4407 if (heldProj >= 0)
4408 {
4409 Projectile projectile = Main.projectile[heldProj];
4410 if (projectile.active && projectile.owner == whoAmI)
4411 {
4412 projectile.Kill();
4413 }
4414 }
4415 for (int i = 0; i < 1000; i++)
4416 {
4417 Projectile projectile2 = Main.projectile[i];
4418 if (projectile2.active && projectile2.owner == whoAmI && (projectile2.aiStyle == 61 || projectile2.aiStyle == 160))
4419 {
4420 projectile2.Kill();
4421 }
4422 }
4423 }

References Terraria.Entity.active, Terraria.Player.heldProj, Terraria.Projectile.Kill(), Terraria.Projectile.owner, Terraria.Main.projectile, and Terraria.Entity.whoAmI.

Referenced by Terraria.Player.DropSelectedItem(), and Terraria.Player.PlayDroppedItemAnimation().