Tipped Arrow
Registry name
etfuturum.tippedArrow (registered as entity class; arrows are typically spawned via item, not direct entity registration)
Basic info
- Health: Not applicable (projectile)
- Armor: None
- Size: Inherited from
EntityArrow - Spawn conditions: Spawned when a bow with a tipped arrow is fired; also spawned directly by
EntityStrayranged attack - Drops: When stuck in ground and picked up by player: one tipped arrow item with the same potion effect
- Behaviour: Arrow projectile that carries a potion effect. Particles spawn around the arrow indicating the effect colour.
Potion handling
- Stores an
ItemStackarrow pointing toModItems.TIPPED_ARROWwith the potion damage value isEffectValid(): returnstrueifarrow != nullsetPotionDamage(): if arrow is null, creates a newTIPPED_ARROWstack and sets its damage- NBT:
"Potion"compound stores full potion data; legacy"potionValue"int also supported
Particle effects
- In ground: spawns 1 particle every 5 ticks (mobSpell, colour from arrow’s item colour)
- In air: spawns 2 particles per tick
- Particles use the RGB from
ModItems.TIPPED_ARROW.get().getColorFromItemStack
Pickup mechanics
- Same pickup rules as
EntityArrow:canBePickedUp == 1: any player can pick upcanBePickedUp == 2: only creative mode players
- Picked-up arrow retains potion data from the entity
Network sync (IEntityAdditionalSpawnData)
writeSpawnData: sends yaw, shooter entity ID, motion XYZ, and the full arrow ItemStackreadSpawnData: reads those fields and reconstructs the arrow entity with potion
Notes
- Extends
EntityArrow(notEntityTippedArrowfrom vanilla 1.9+) - This entity class exists to back the
tipped_arrowitem implementation in 1.8-compatible Forge onCollideWithPlayer: the potion effect itself is NOT applied on pickup — only the arrow item is given to the player; the effect applies when the arrow is consumed/crafted with- Used by
EntityStray.attackEntityWithRangedAttackto fire Slowness-tipped arrows