Rework the BackstringSet solution
This commit is contained in:
parent
07d0197abc
commit
ad6dc57fa8
@ -14,7 +14,7 @@ import com.massivecraft.factions.entity.Faction;
|
||||
import com.massivecraft.factions.entity.MConf;
|
||||
import com.massivecraft.factions.entity.MFlag;
|
||||
import com.massivecraft.massivecore.Engine;
|
||||
import com.massivecraft.massivecore.collections.BackstringEnumSet;
|
||||
import com.massivecraft.massivecore.collections.BackstringSet;
|
||||
import com.massivecraft.massivecore.ps.PS;
|
||||
|
||||
public class EngineFlagSpawn extends Engine
|
||||
@ -30,7 +30,7 @@ public class EngineFlagSpawn extends Engine
|
||||
// CONSTANTS
|
||||
// -------------------------------------------- //
|
||||
|
||||
public static final Set<SpawnReason> NATURAL_SPAWN_REASONS = new BackstringEnumSet<>(SpawnReason.class,
|
||||
public static final Set<SpawnReason> NATURAL_SPAWN_REASONS = new BackstringSet<>(SpawnReason.class,
|
||||
"NATURAL",
|
||||
"JOCKEY",
|
||||
"CHUNK_GEN",
|
||||
|
@ -16,7 +16,7 @@ import com.massivecraft.factions.Factions;
|
||||
import com.massivecraft.factions.Rel;
|
||||
import com.massivecraft.factions.engine.EngineChat;
|
||||
import com.massivecraft.factions.event.EventFactionsChunkChangeType;
|
||||
import com.massivecraft.massivecore.collections.BackstringEnumSet;
|
||||
import com.massivecraft.massivecore.collections.BackstringSet;
|
||||
import com.massivecraft.massivecore.collections.WorldExceptionSet;
|
||||
import com.massivecraft.massivecore.command.editor.annotation.EditorName;
|
||||
import com.massivecraft.massivecore.command.editor.annotation.EditorType;
|
||||
@ -538,7 +538,7 @@ public class MConf extends Entity<MConf>
|
||||
// This way they can be protected in Faction territory.
|
||||
|
||||
// Interacting with these materials when they are already placed in the terrain results in an edit.
|
||||
public BackstringEnumSet<Material> materialsEditOnInteract = new BackstringEnumSet<Material>(Material.class,
|
||||
public BackstringSet<Material> materialsEditOnInteract = new BackstringSet<Material>(Material.class,
|
||||
"DIODE_BLOCK_OFF", // Minecraft 1.?
|
||||
"DIODE_BLOCK_ON", // Minecraft 1.?
|
||||
"NOTE_BLOCK", // Minecraft 1.?
|
||||
@ -552,7 +552,7 @@ public class MConf extends Entity<MConf>
|
||||
|
||||
// Interacting with the the terrain holding this item in hand results in an edit.
|
||||
// There's no need to add all block materials here. Only special items other than blocks.
|
||||
public BackstringEnumSet<Material> materialsEditTools = new BackstringEnumSet<Material>(Material.class,
|
||||
public BackstringSet<Material> materialsEditTools = new BackstringSet<Material>(Material.class,
|
||||
"FIREBALL", // Minecraft 1.?
|
||||
"FLINT_AND_STEEL", // Minecraft 1.?
|
||||
"BUCKET", // Minecraft 1.?
|
||||
@ -564,7 +564,7 @@ public class MConf extends Entity<MConf>
|
||||
|
||||
// The duplication bug found in Spigot 1.8 protocol patch
|
||||
// https://github.com/MassiveCraft/Factions/issues/693
|
||||
public BackstringEnumSet<Material> materialsEditToolsDupeBug = new BackstringEnumSet<Material>(Material.class,
|
||||
public BackstringSet<Material> materialsEditToolsDupeBug = new BackstringSet<Material>(Material.class,
|
||||
"CHEST", // Minecraft 1.?
|
||||
"SIGN_POST", // Minecraft 1.?
|
||||
"TRAPPED_CHEST", // Minecraft 1.?
|
||||
@ -574,7 +574,7 @@ public class MConf extends Entity<MConf>
|
||||
);
|
||||
|
||||
// Interacting with these materials placed in the terrain results in door toggling.
|
||||
public BackstringEnumSet<Material> materialsDoor = new BackstringEnumSet<Material>(Material.class,
|
||||
public BackstringSet<Material> materialsDoor = new BackstringSet<Material>(Material.class,
|
||||
"WOODEN_DOOR", // Minecraft 1.?
|
||||
"ACACIA_DOOR", // Minecraft 1.8
|
||||
"BIRCH_DOOR", // Minecraft 1.8
|
||||
@ -591,7 +591,7 @@ public class MConf extends Entity<MConf>
|
||||
);
|
||||
|
||||
// Interacting with these materials placed in the terrain results in opening a container.
|
||||
public BackstringEnumSet<Material> materialsContainer = new BackstringEnumSet<Material>(Material.class,
|
||||
public BackstringSet<Material> materialsContainer = new BackstringSet<Material>(Material.class,
|
||||
"DISPENSER", // Minecraft 1.?
|
||||
"CHEST", // Minecraft 1.?
|
||||
"FURNACE", // Minecraft 1.?
|
||||
@ -625,26 +625,26 @@ public class MConf extends Entity<MConf>
|
||||
);
|
||||
|
||||
// Interacting with these entities results in an edit.
|
||||
public BackstringEnumSet<EntityType> entityTypesEditOnInteract = new BackstringEnumSet<EntityType>(EntityType.class,
|
||||
public BackstringSet<EntityType> entityTypesEditOnInteract = new BackstringSet<EntityType>(EntityType.class,
|
||||
"ITEM_FRAME", // Minecraft 1.?
|
||||
"ARMOR_STAND" // Minecraft 1.8
|
||||
);
|
||||
|
||||
// Damaging these entities results in an edit.
|
||||
public BackstringEnumSet<EntityType> entityTypesEditOnDamage = new BackstringEnumSet<EntityType>(EntityType.class,
|
||||
public BackstringSet<EntityType> entityTypesEditOnDamage = new BackstringSet<EntityType>(EntityType.class,
|
||||
"ITEM_FRAME", // Minecraft 1.?
|
||||
"ARMOR_STAND", // Minecraft 1.8
|
||||
"ENDER_CRYSTAL" // Minecraft 1.10
|
||||
);
|
||||
|
||||
// Interacting with these entities results in opening a container.
|
||||
public BackstringEnumSet<EntityType> entityTypesContainer = new BackstringEnumSet<EntityType>(EntityType.class,
|
||||
public BackstringSet<EntityType> entityTypesContainer = new BackstringSet<EntityType>(EntityType.class,
|
||||
"MINECART_CHEST", // Minecraft 1.?
|
||||
"MINECART_HOPPER" // Minecraft 1.?
|
||||
);
|
||||
|
||||
// The complete list of entities considered to be monsters.
|
||||
public BackstringEnumSet<EntityType> entityTypesMonsters = new BackstringEnumSet<EntityType>(EntityType.class,
|
||||
public BackstringSet<EntityType> entityTypesMonsters = new BackstringSet<EntityType>(EntityType.class,
|
||||
"BLAZE", // Minecraft 1.?
|
||||
"CAVE_SPIDER", // Minecraft 1.?
|
||||
"CREEPER", // Minecraft 1.?
|
||||
@ -676,7 +676,7 @@ public class MConf extends Entity<MConf>
|
||||
);
|
||||
|
||||
// List of entities considered to be animals.
|
||||
public BackstringEnumSet<EntityType> entityTypesAnimals = new BackstringEnumSet<EntityType>(EntityType.class,
|
||||
public BackstringSet<EntityType> entityTypesAnimals = new BackstringSet<EntityType>(EntityType.class,
|
||||
"BAT", // Minecraft 1.?
|
||||
"CHICKEN", // Minecraft 1.?
|
||||
"COW", // Minecraft 1.?
|
||||
|
Loading…
Reference in New Issue
Block a user