Skip to content

Commit

Permalink
HOTFIX Graplinghook
Browse files Browse the repository at this point in the history
  • Loading branch information
Relluem94 committed Oct 27, 2024
1 parent 874ed83 commit 1751e69
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
1 change: 0 additions & 1 deletion .idea/compiler.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions .idea/dbnavigator.xml

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 0 additions & 6 deletions relluessentials.iml
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,9 @@
<configuration>
<autoDetectTypes>
<platformType>SPIGOT</platformType>
<platformType>MCP</platformType>
<platformType>PAPER</platformType>
<platformType>ADVENTURE</platformType>
</autoDetectTypes>
<projectReimportVersion>1</projectReimportVersion>
</configuration>
</facet>
</component>
<component name="McpModuleSettings">
<option name="srgType" value="SRG" />
</component>
</module>
Original file line number Diff line number Diff line change
Expand Up @@ -15,12 +15,21 @@
import de.relluem94.minecraft.server.spigot.essentials.RelluEssentials;
import de.relluem94.minecraft.server.spigot.essentials.constants.Constants;

import static de.relluem94.minecraft.server.spigot.essentials.constants.Constants.PLUGIN_WORLD_LOBBY;
import static de.relluem94.minecraft.server.spigot.essentials.helpers.WorldHelper.isInWorld;

public class GrapplingHockEvent implements Listener {

protected static final List<Player> COOL_DOWN = new ArrayList<>();

@EventHandler
public void grapple(PlayerFishEvent e){
if(!isInWorld(e.getPlayer(), PLUGIN_WORLD_LOBBY)){
return;
}

// TODO Check auf item

if(e.getState().equals(State.IN_GROUND) || e.getState().equals(State.REEL_IN)){
if(!COOL_DOWN.contains(e.getPlayer())){
Location hookLocation = e.getHook().getLocation();
Expand Down

0 comments on commit 1751e69

Please sign in to comment.