EVEN MORE GI CHANGES
This commit is contained in:
parent
c76a8390fc
commit
a76d83cd69
@ -78,7 +78,7 @@ public class PerkFlap extends SmashPerk
|
|||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
UtilAction.velocity(player, player.getLocation().getDirection(), power, true, power, 0, 10, true);
|
UtilAction.velocity(player, player.getLocation().getDirection(), power, true, power, 0.3, 10, true);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Sound
|
// Sound
|
||||||
|
@ -113,14 +113,14 @@ public class PerkCowMilkSpiral extends SmashPerk
|
|||||||
|
|
||||||
for (Player player : Manager.GetGame().GetPlayers(true))
|
for (Player player : Manager.GetGame().GetPlayers(true))
|
||||||
{
|
{
|
||||||
if (player.equals(data.Player) || !Recharge.Instance.use(player, GetName() + " Rate", 500, false, false))
|
if (player.equals(data.Player) || !Recharge.Instance.use(player, GetName() + " Rate", 250, false, false))
|
||||||
{
|
{
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (UtilMath.offset(player.getLocation().add(0, 1.5, 0), data.Spiral) < _hitBoxRadius)
|
if (UtilMath.offset(player.getLocation().add(0, 1.5, 0), data.Spiral) < _hitBoxRadius)
|
||||||
{
|
{
|
||||||
Manager.GetDamage().NewDamageEvent(player, data.Player, null, DamageCause.CUSTOM, _damage, true, false, false, player.getName(), GetName());
|
Manager.GetDamage().NewDamageEvent(player, data.Player, null, DamageCause.CUSTOM, _damage, true, true, false, player.getName(), GetName());
|
||||||
|
|
||||||
UtilParticle.PlayParticleToAll(isSuperActive(player) ? ParticleType.RED_DUST : ParticleType.FIREWORKS_SPARK, player.getLocation().add(0, 1, 0), 0.2f, 0.2f, 0.2f, 0.3f, 30, ViewDist.LONG);
|
UtilParticle.PlayParticleToAll(isSuperActive(player) ? ParticleType.RED_DUST : ParticleType.FIREWORKS_SPARK, player.getLocation().add(0, 1, 0), 0.2f, 0.2f, 0.2f, 0.3f, 30, ViewDist.LONG);
|
||||||
player.getWorld().playSound(player.getLocation(), Sound.SPLASH, 0.25f, 2f);
|
player.getWorld().playSound(player.getLocation(), Sound.SPLASH, 0.25f, 2f);
|
||||||
|
@ -36,6 +36,7 @@ public class PerkCreeperSulphurBomb extends SmashPerk
|
|||||||
private int _cooldown;
|
private int _cooldown;
|
||||||
private float _damage;
|
private float _damage;
|
||||||
private float _knockbackMagnitude;
|
private float _knockbackMagnitude;
|
||||||
|
private float _hitBox;
|
||||||
|
|
||||||
private final IThrown _sulphurThrown = new IThrown()
|
private final IThrown _sulphurThrown = new IThrown()
|
||||||
{
|
{
|
||||||
@ -90,6 +91,7 @@ public class PerkCreeperSulphurBomb extends SmashPerk
|
|||||||
_cooldown = getPerkTime("Cooldown");
|
_cooldown = getPerkTime("Cooldown");
|
||||||
_damage = getPerkFloat("Damage");
|
_damage = getPerkFloat("Damage");
|
||||||
_knockbackMagnitude = getPerkFloat("Knockback Magnitude");
|
_knockbackMagnitude = getPerkFloat("Knockback Magnitude");
|
||||||
|
_hitBox = getPerkFloat("Hit Box");
|
||||||
}
|
}
|
||||||
|
|
||||||
@EventHandler
|
@EventHandler
|
||||||
@ -139,7 +141,7 @@ public class PerkCreeperSulphurBomb extends SmashPerk
|
|||||||
Item ent = player.getWorld().dropItem(player.getEyeLocation(), ItemStackFactory.Instance.CreateStack(Material.COAL, (byte) 0));
|
Item ent = player.getWorld().dropItem(player.getEyeLocation(), ItemStackFactory.Instance.CreateStack(Material.COAL, (byte) 0));
|
||||||
|
|
||||||
UtilAction.velocity(ent, player.getLocation().getDirection(), 1.2, false, 0, 0.2, 10, false);
|
UtilAction.velocity(ent, player.getLocation().getDirection(), 1.2, false, 0, 0.2, 10, false);
|
||||||
Manager.GetProjectile().AddThrow(ent, player, _sulphurThrown, -1, true, true, true, true, null, 1f, 1f, null, 1, UpdateType.SLOW, 0.8F);
|
Manager.GetProjectile().AddThrow(ent, player, _sulphurThrown, -1, true, true, true, true, null, 1f, 1f, null, 1, UpdateType.SLOW, _hitBox);
|
||||||
|
|
||||||
// Inform
|
// Inform
|
||||||
UtilPlayer.message(player, F.main("Game", "You used " + F.skill(GetName()) + "."));
|
UtilPlayer.message(player, F.main("Game", "You used " + F.skill(GetName()) + "."));
|
||||||
|
@ -1,17 +1,15 @@
|
|||||||
package nautilus.game.arcade.game.modules.chest;
|
package nautilus.game.arcade.game.modules.chest;
|
||||||
|
|
||||||
import mineplex.core.common.util.MapUtil;
|
import java.util.ArrayList;
|
||||||
import mineplex.core.common.util.UtilAlg;
|
import java.util.Arrays;
|
||||||
import mineplex.core.common.util.UtilBlock;
|
import java.util.HashMap;
|
||||||
import mineplex.core.common.util.UtilEvent;
|
import java.util.HashSet;
|
||||||
import mineplex.core.common.util.UtilEvent.ActionType;
|
import java.util.List;
|
||||||
import mineplex.core.common.util.UtilMath;
|
import java.util.Map;
|
||||||
import mineplex.core.common.util.UtilTime;
|
import java.util.Map.Entry;
|
||||||
import mineplex.core.updater.UpdateType;
|
import java.util.Set;
|
||||||
import mineplex.core.updater.event.UpdateEvent;
|
import java.util.concurrent.TimeUnit;
|
||||||
import nautilus.game.arcade.events.GameStateChangeEvent;
|
|
||||||
import nautilus.game.arcade.game.Game.GameState;
|
|
||||||
import nautilus.game.arcade.game.modules.Module;
|
|
||||||
import org.bukkit.Effect;
|
import org.bukkit.Effect;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
@ -24,15 +22,22 @@ import org.bukkit.event.EventPriority;
|
|||||||
import org.bukkit.event.player.PlayerInteractEvent;
|
import org.bukkit.event.player.PlayerInteractEvent;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
import mineplex.core.common.util.MapUtil;
|
||||||
import java.util.Arrays;
|
import mineplex.core.common.util.UtilAlg;
|
||||||
import java.util.HashMap;
|
import mineplex.core.common.util.UtilBlock;
|
||||||
import java.util.HashSet;
|
import mineplex.core.common.util.UtilEvent;
|
||||||
import java.util.List;
|
import mineplex.core.common.util.UtilEvent.ActionType;
|
||||||
import java.util.Map;
|
import mineplex.core.common.util.UtilMath;
|
||||||
import java.util.Map.Entry;
|
import mineplex.core.common.util.UtilTime;
|
||||||
import java.util.Set;
|
import mineplex.core.titles.tracks.standard.LuckyTrack;
|
||||||
import java.util.concurrent.TimeUnit;
|
import mineplex.core.titles.tracks.standard.UnluckyTrack;
|
||||||
|
import mineplex.core.updater.UpdateType;
|
||||||
|
import mineplex.core.updater.event.UpdateEvent;
|
||||||
|
|
||||||
|
import nautilus.game.arcade.ArcadeManager;
|
||||||
|
import nautilus.game.arcade.events.GameStateChangeEvent;
|
||||||
|
import nautilus.game.arcade.game.Game.GameState;
|
||||||
|
import nautilus.game.arcade.game.modules.Module;
|
||||||
|
|
||||||
public class ChestLootModule extends Module
|
public class ChestLootModule extends Module
|
||||||
{
|
{
|
||||||
@ -214,15 +219,23 @@ public class ChestLootModule extends Module
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Chest chest = (Chest) block.getState();
|
||||||
Player player = event.getPlayer();
|
Player player = event.getPlayer();
|
||||||
|
ArcadeManager manager = getGame().getArcadeManager();
|
||||||
getGame().AddStat(player, "ChestsOpened", 1, false, false);
|
getGame().AddStat(player, "ChestsOpened", 1, false, false);
|
||||||
|
|
||||||
|
if (manager.IsRewardStats())
|
||||||
|
{
|
||||||
|
manager.getTrackManager().getTrack(LuckyTrack.class).handleLoot(player, chest.getBlockInventory());
|
||||||
|
manager.getTrackManager().getTrack(UnluckyTrack.class).handleLoot(player, chest.getBlockInventory());
|
||||||
|
}
|
||||||
|
|
||||||
metadata.Opened = true;
|
metadata.Opened = true;
|
||||||
metadata.OpenedAt = System.currentTimeMillis();
|
metadata.OpenedAt = System.currentTimeMillis();
|
||||||
|
|
||||||
if (!_preGenerateLoot)
|
if (!_preGenerateLoot)
|
||||||
{
|
{
|
||||||
metadata.populateChest((Chest) block.getState());
|
metadata.populateChest(chest);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user