Skip to content

Refactoring and implementation of the LaunchProjectileEvent#1769

Closed
RedNesto wants to merge 9 commits into
SpongePowered:bleedingfrom
RedNesto:api8-impl/launch-projectile-event
Closed

Refactoring and implementation of the LaunchProjectileEvent#1769
RedNesto wants to merge 9 commits into
SpongePowered:bleedingfrom
RedNesto:api8-impl/launch-projectile-event

Conversation

@RedNesto

@RedNesto RedNesto commented Feb 4, 2018

Copy link
Copy Markdown
Contributor

SpongeAPI | SpongeCommon

This PR implement its SpongeAPI counterpart.

When is the event fired ?

Here are each cases I tested:

  • A non-player entity shoots a projectile (skeletons shooting arrows, llamas spitting, ghasts shooting fireballs, snowmans shooting snowballs, blaze shooting small fireballs)
  • A player shoots arrows (with a bow heh)
  • A player throws projectiles (snowballs, eggs, potions - splash and lingering -, enderpearls, eyes of ender, using fishing rod, experience bottle)
  • A dispenser dispenses projectiles (arrows, snowballs, eggs, potions - splash and lingering -, experience bottle)
  • A plugin shoots a projectile
  • A player uses a firework.
  • A dispenser dispenses a firework.
  • A Wither attacks.
  • The dragon shoots a fireball

Tell me if you see a case of projectile I missed.

And there is the content of a test plugin

Note: It seems that there are two projectile-related EventContextKeys, PROJECTILE_SOURCE and THROWER, from what I saw, only one would be necessary, I may address this issue later if it is considered as one.
Fixed in 5d0184d

@limbo-app limbo-app added status: needs review a code review is needed status: needs testing does this run, does it solve the issue etc labels Feb 4, 2018
@RedNesto

RedNesto commented Feb 5, 2018

Copy link
Copy Markdown
Contributor Author

~wip

@phit phit added status: wip Work in progress and removed status: needs review a code review is needed status: needs testing does this run, does it solve the issue etc labels Feb 5, 2018
@limbo-app limbo-app added status: needs review a code review is needed status: needs testing does this run, does it solve the issue etc and removed status: wip Work in progress labels Feb 6, 2018
@ImMorpheus ImMorpheus removed the status: needs testing does this run, does it solve the issue etc label Aug 30, 2018
@ImMorpheus ImMorpheus changed the title [API 8] Refactoring and implementation of the LaunchProjectileEvent Refactoring and implementation of the LaunchProjectileEvent Jul 6, 2019
@gabizou gabizou closed this Dec 2, 2019
@gabizou

gabizou commented Dec 2, 2019

Copy link
Copy Markdown
Member

This will need to be re-done and re-target api-8. Bleeding is no longer a valid branch.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants