Merge pull request 'Fix Trace show/hide Bug' (#86) from TNTTracer into master
Reviewed-by: Lixfel <lixfel@steamwar.de>
Dieser Commit ist enthalten in:
Commit
24f8e22fb4
@ -86,7 +86,7 @@ public class PlayerTraceCache_15 {
|
||||
}
|
||||
}
|
||||
|
||||
public synchronized void hide(Player player) {
|
||||
public void hideBlockTraces(Player player) {
|
||||
hiding = true;
|
||||
if (positions.length == 0 || positions.length % 3 != 0) return;
|
||||
for (int i = 0; i < positions.length; i += 3) {
|
||||
|
@ -1,7 +1,6 @@
|
||||
package de.steamwar.bausystem.tracer;
|
||||
|
||||
import de.steamwar.bausystem.tracer.debugcallback.DebugCallbackActionBar;
|
||||
import de.steamwar.bausystem.tracer.showcallback.TNTCallbackCacheUpdate;
|
||||
import de.steamwar.bausystem.tracer.showcallback.TNTCallbackShow;
|
||||
import de.steamwar.bausystem.tracer.updatecallback.*;
|
||||
import net.md_5.bungee.api.ChatMessageType;
|
||||
@ -158,10 +157,10 @@ class TNTTracer_15 {
|
||||
return result;
|
||||
}
|
||||
|
||||
static void hide(Player p) {
|
||||
static void hideBlockTraces(Player p) {
|
||||
PlayerTraceCache_15 tracerCache15 = playerMap.get(p);
|
||||
if (tracerCache15 == null) return;
|
||||
tracerCache15.hide(p);
|
||||
tracerCache15.hideBlockTraces(p);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -133,7 +133,6 @@ public class CommandTrace implements CommandExecutor {
|
||||
case "particle":
|
||||
case "particles":
|
||||
TNTTracer15.hideBlockTraces(player);
|
||||
ShowManager.get(player).show();
|
||||
ShowManager.get(player).setShowMode(ShowStatus.ShowMode.PARTICLE);
|
||||
break;
|
||||
default:
|
||||
@ -142,7 +141,7 @@ public class CommandTrace implements CommandExecutor {
|
||||
ShowManager.get(player).addSelection(tntID);
|
||||
player.sendMessage(BauSystem.PREFIX + "§aTNT-Positionen des TNT mit ID " + tntID + " angezeigt");
|
||||
player.sendMessage(BauSystem.PREFIX + "§eBei zu vielen zu zeigenden Positionen wird der Block Tracer aktiviert");
|
||||
player.sendMessage(BauSystem.PREFIX + "§eBitte aktiviere animiertes Feuer in den Grafikeinstellungen");
|
||||
// player.sendMessage(BauSystem.PREFIX + "§eBitte aktiviere animiertes Feuer in den Grafikeinstellungen");
|
||||
} catch (NumberFormatException e) {
|
||||
help15(player);
|
||||
}
|
||||
@ -152,7 +151,7 @@ public class CommandTrace implements CommandExecutor {
|
||||
ShowManager.get(player).show();
|
||||
player.sendMessage(BauSystem.PREFIX + "§aAlle TNT-Positionen angezeigt");
|
||||
player.sendMessage(BauSystem.PREFIX + "§eBei zu vielen zu zeigenden Positionen wird der Block Tracer aktiviert");
|
||||
player.sendMessage(BauSystem.PREFIX + "§eBitte aktiviere animiertes Feuer in den Grafikeinstellungen");
|
||||
// player.sendMessage(BauSystem.PREFIX + "§eBitte aktiviere animiertes Feuer in den Grafikeinstellungen");
|
||||
break;
|
||||
case "hide":
|
||||
if (args.length == 2) {
|
||||
|
@ -302,7 +302,7 @@ public class TNTTracer15 {
|
||||
}
|
||||
|
||||
public static void hideBlockTraces(Player p) {
|
||||
TNTTracer_15.hide(p);
|
||||
TNTTracer_15.hideBlockTraces(p);
|
||||
}
|
||||
|
||||
public static void start() {
|
||||
|
In neuem Issue referenzieren
Einen Benutzer sperren