Dieser Commit ist enthalten in:
Ursprung
006a0edef6
Commit
3d0ebbe743
@ -21,9 +21,14 @@ package de.steamwar.bausystem.features.simulator.data.tnt;
|
||||
|
||||
import de.steamwar.bausystem.features.simulator.data.SimulatorPhase;
|
||||
import de.steamwar.bausystem.features.simulator.execute.SimulatorAction;
|
||||
import de.steamwar.bausystem.region.Region;
|
||||
import de.steamwar.bausystem.region.flags.Flag;
|
||||
import de.steamwar.bausystem.region.flags.flagvalues.FreezeMode;
|
||||
import de.steamwar.bausystem.region.tags.Tag;
|
||||
import lombok.Getter;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.Setter;
|
||||
import org.bukkit.Location;
|
||||
import org.bukkit.World;
|
||||
import org.bukkit.entity.TNTPrimed;
|
||||
import org.bukkit.util.Vector;
|
||||
@ -59,7 +64,9 @@ public final class TNTPhase extends SimulatorPhase {
|
||||
tickStart.accept(tickOffset, new SimulatorAction(order, count) {
|
||||
@Override
|
||||
public void accept(World world) {
|
||||
TNTPrimed tnt = world.spawn(position.toLocation(world), TNTPrimed.class);
|
||||
Location location = position.toLocation(world);
|
||||
if (Region.getRegion(location).get(Flag.FREEZE) == FreezeMode.ACTIVE) return;
|
||||
TNTPrimed tnt = world.spawn(location, TNTPrimed.class);
|
||||
if (!xJump) tnt.setVelocity(tnt.getVelocity().setX(0));
|
||||
if (!yJump) tnt.setVelocity(tnt.getVelocity().setY(0));
|
||||
if (!zJump) tnt.setVelocity(tnt.getVelocity().setZ(0));
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren