Sentry Issue #223481030
Prevent Fish Flurry from activating if no suitable blocks are found Steps to reproduce: 1) Select squid on hyrule castle 2) Activate fish flurry while looking at middle of empty side of castle
This commit is contained in:
parent
7e9211815f
commit
cb9ac1fc9f
@ -102,11 +102,6 @@ public class PerkFishFlurry extends SmashPerk implements IThrown
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!Recharge.Instance.use(player, GetName(), COOLDOWN, true, true))
|
|
||||||
{
|
|
||||||
return;
|
|
||||||
|
|
||||||
}
|
|
||||||
event.setCancelled(true);
|
event.setCancelled(true);
|
||||||
|
|
||||||
Set<Block> blocks = new HashSet<>();
|
Set<Block> blocks = new HashSet<>();
|
||||||
@ -131,11 +126,19 @@ public class PerkFishFlurry extends SmashPerk implements IThrown
|
|||||||
blocks.add(cur);
|
blocks.add(cur);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!blocks.isEmpty())
|
||||||
|
{
|
||||||
|
if (!Recharge.Instance.use(player, GetName(), COOLDOWN, true, true))
|
||||||
|
{
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
_active.add(new DataSquidGeyser(player, blocks));
|
_active.add(new DataSquidGeyser(player, blocks));
|
||||||
|
|
||||||
// Inform
|
// Inform
|
||||||
UtilPlayer.message(player, F.main("Game", "You used " + F.skill(GetName()) + "."));
|
UtilPlayer.message(player, F.main("Game", "You used " + F.skill(GetName()) + "."));
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@EventHandler
|
@EventHandler
|
||||||
public void update(UpdateEvent event)
|
public void update(UpdateEvent event)
|
||||||
|
Loading…
Reference in New Issue
Block a user