SteamWar/BauSystem2.0
Archiviert
12
0

Fix Naming in TNTSimulator

Dieser Commit ist enthalten in:
yoyosource 2021-04-18 01:33:41 +02:00
Ursprung 0040f2c40d
Commit a2e677b369
4 geänderte Dateien mit 9 neuen und 7 gelöschten Zeilen

Datei anzeigen

@ -30,8 +30,8 @@ class SimulatorEntity_15 extends BaseEntity_15 implements AbstractSimulatorEntit
private ReferenceCounter referenceCounter = new ReferenceCounter(); private ReferenceCounter referenceCounter = new ReferenceCounter();
public SimulatorEntity_15(World world, Vector position, boolean tnt) { public SimulatorEntity_15(World world, Vector position, boolean highlight) {
super(world, position, tnt ? Material.TNT : Material.WHITE_STAINED_GLASS); super(world, position, highlight ? Material.TNT : Material.WHITE_STAINED_GLASS);
this.setNoGravity(true); this.setNoGravity(true);
this.ticksLived = -12000; this.ticksLived = -12000;

Datei anzeigen

@ -24,8 +24,8 @@ import org.bukkit.util.Vector;
public class Simulator_15 { public class Simulator_15 {
public static AbstractSimulatorEntity create(World world, Vector tntPosition, boolean tnt) { public static AbstractSimulatorEntity create(World world, Vector tntPosition, boolean highlight) {
return new SimulatorEntity_15(world, tntPosition, tnt); return new SimulatorEntity_15(world, tntPosition, highlight);
} }
} }

Datei anzeigen

@ -22,6 +22,8 @@
package de.steamwar.bausystem.features.simulator; package de.steamwar.bausystem.features.simulator;
import de.steamwar.bausystem.BauSystem; import de.steamwar.bausystem.BauSystem;
import de.steamwar.bausystem.SWUtils;
import de.steamwar.bausystem.config.ColorConfig;
import de.steamwar.bausystem.features.simulator.show.SimulatorEntityShowMode; import de.steamwar.bausystem.features.simulator.show.SimulatorEntityShowMode;
import de.steamwar.inventory.SWAnvilInv; import de.steamwar.inventory.SWAnvilInv;
import de.steamwar.inventory.SWInventory; import de.steamwar.inventory.SWInventory;
@ -94,7 +96,7 @@ public class TNTSimulator {
cursor = SimulatorEntityShowMode.createEntity(player, entity.position, false); cursor = SimulatorEntityShowMode.createEntity(player, entity.position, false);
cursor.display(player); cursor.display(player);
player.spigot().sendMessage(ChatMessageType.ACTION_BAR, TextComponent.fromLegacyText("§ePosition bearbeiten")); SWUtils.sendToActionbar(player, ColorConfig.HIGHLIGHT + "Position bearbeiten");
return; return;
} }

Datei anzeigen

@ -48,8 +48,8 @@ public class SimulatorEntityShowMode implements ShowMode<Position> {
entity.display(player); entity.display(player);
} }
public static AbstractSimulatorEntity createEntity(Player player, Vector position, boolean tnt) { public static AbstractSimulatorEntity createEntity(Player player, Vector position, boolean highlight) {
return VersionedCallable.call(new VersionedCallable<>(() -> Simulator_15.create(player.getWorld(), position, tnt), 15)); return VersionedCallable.call(new VersionedCallable<>(() -> Simulator_15.create(player.getWorld(), position, highlight), 15));
} }
@Override @Override