Mirror von
https://github.com/IntellectualSites/FastAsyncWorldEdit.git
synchronisiert 2024-11-03 01:50:07 +01:00
Add rotations to various blocks that were missing them.
Up/down levers still broken. Fixes WORLDEDIT-3490.
Dieser Commit ist enthalten in:
Ursprung
a4455e875e
Commit
e511758d99
@ -33,6 +33,7 @@ import com.sk89q.worldedit.extension.platform.Actor;
|
||||
import com.sk89q.worldedit.extension.platform.Platform;
|
||||
import com.sk89q.worldedit.world.World;
|
||||
import com.sk89q.worldedit.world.registry.BundledBlockData;
|
||||
import com.sk89q.worldedit.world.registry.SimpleState;
|
||||
import com.sk89q.worldedit.world.registry.State;
|
||||
import com.sk89q.worldedit.world.registry.StateValue;
|
||||
|
||||
@ -80,9 +81,14 @@ public class QueryTool implements BlockTool {
|
||||
StringBuilder builder = new StringBuilder();
|
||||
builder.append("States: ");
|
||||
boolean first = true;
|
||||
boolean hasVisibleStates = false;
|
||||
for (Entry<String, ? extends State> e : states.entrySet()) {
|
||||
String name = e.getKey();
|
||||
State state = e.getValue();
|
||||
if (state instanceof SimpleState && ((SimpleState) state).getDataMask() == 0) {
|
||||
continue; // don't try to determine states that aren't reflected in their data value
|
||||
}
|
||||
hasVisibleStates = true;
|
||||
if (!first) {
|
||||
builder.append(", ");
|
||||
}
|
||||
@ -91,11 +97,14 @@ public class QueryTool implements BlockTool {
|
||||
for (Entry<String, ? extends StateValue> entry : state.valueMap().entrySet()) {
|
||||
if (entry.getValue().isSet(block)) {
|
||||
valName = entry.getKey();
|
||||
break;
|
||||
}
|
||||
}
|
||||
builder.append("\u00A79").append(name).append(": \u00A7f").append(valName != null ? valName : "set");
|
||||
}
|
||||
if (hasVisibleStates) {
|
||||
player.printRaw(builder.toString());
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
@ -25,7 +25,7 @@ import javax.annotation.Nullable;
|
||||
import java.util.Collections;
|
||||
import java.util.Map;
|
||||
|
||||
class SimpleState implements State {
|
||||
public class SimpleState implements State {
|
||||
|
||||
private Byte dataMask;
|
||||
private Map<String, SimpleStateValue> values;
|
||||
@ -47,7 +47,7 @@ class SimpleState implements State {
|
||||
return null;
|
||||
}
|
||||
|
||||
byte getDataMask() {
|
||||
public byte getDataMask() {
|
||||
return dataMask != null ? dataMask : 0xF;
|
||||
}
|
||||
|
||||
|
Datei-Diff unterdrückt, da er zu groß ist
Diff laden
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren