LogicUsing Events
Player Shoot Projectile
Triggers when a player fires a projectile, like an arrow or snowball.
This event fires the moment a player launches a projectile from a bow, crossbow, trident, or by throwing an item like a snowball or egg.
Action Values
Player: The player who shot the projectile.Projectile: The projectile entity that was fired.
Event Configuration
- Projectile Type: Filter to only trigger for a specific type of projectile (e.g.,
ARROW,SNOWBALL,TRIDENT). - Cancel Event: If
true, the projectile will not be launched.
Use Cases
- Disabling the use of bows or other projectiles in certain areas.
- Creating a custom weapon that fires something other than a normal arrow (e.g., replace an arrow with a fireball).
- Tracking a player's ammo count using a
Property. - Applying a cooldown to projectile firing.
Example: A "Fireball Wand"
- Create a Custom Item: A blaze rod named
&cFireball Wand. - Region: A region where the wand should work.
- Event:
Player Shoot Projectile. - Configuration: Set Projectile Type to
ARROW(this triggers when a bow is fired). - Actions:
Conditional: Check if thePlayeris holding theFireball Wand.- If Actions:
Cancel Event:True. This stops the original arrow from firing.Launch Projectile: Target thePlayer, and launch aLARGE_FIREBALL.