本文整理汇总了Java中ninja.leaping.configurate.ConfigurationNode.getBoolean方法的典型用法代码示例。如果您正苦于以下问题:Java ConfigurationNode.getBoolean方法的具体用法?Java ConfigurationNode.getBoolean怎么用?Java ConfigurationNode.getBoolean使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ninja.leaping.configurate.ConfigurationNode
的用法示例。
在下文中一共展示了ConfigurationNode.getBoolean方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: BlockCase
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public BlockCase(ConfigurationNode node) {
super(node);
try {
ConfigurationNode location_node = node.getNode("LOCATION");
ConfigurationNode hologram_node = node.getNode("HOLOGRAM");
ConfigurationNode start_preview_on_left_click_node = node.getNode("START_PREVIEW_ON_LEFT_CLICK");
if (location_node.isVirtual()) {
throw new RuntimeException("LOCATION node does not exist!");
}
location = Utils.parseLocation(location_node);
if (!hologram_node.isVirtual()) {
hologram = Optional.of(TextSerializers.FORMATTING_CODE.deserialize(hologram_node.getString()));
}
created_hologram = Utils.tryCreateHologram(location, hologram);
start_preview_on_left_click = start_preview_on_left_click_node.getBoolean(false);
} catch (Exception e) {
GWMCrates.getInstance().getLogger().warn("Exception creating Block Case!", e);
}
}
示例2: MultiDrop
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public MultiDrop(ConfigurationNode node) {
super(node);
try {
ConfigurationNode drops_node = node.getNode("DROPS");
ConfigurationNode give_all_node = node.getNode("GIVE_ALL");
if (drops_node.isVirtual()) {
throw new RuntimeException("DROPS node does not exist");
}
drops = new ArrayList<Drop>();
for (ConfigurationNode drop_node : drops_node.getChildrenList()) {
drops.add((Drop) Utils.createSuperObject(drop_node, SuperObjectType.DROP));
}
give_all = give_all_node.getBoolean(true);
} catch (Exception e) {
throw new RuntimeException("Exception creating Multi Drop!", e);
}
}
示例3: MultiKey
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public MultiKey(ConfigurationNode node) {
super(node);
try {
ConfigurationNode keys_node = node.getNode("KEYS");
ConfigurationNode all_keys_needed_node = node.getNode("ALL_KEYS_NEEDED");
if (keys_node.isVirtual()) {
throw new RuntimeException("KEYS node does not exist");
}
keys = new ArrayList<Key>();
for (ConfigurationNode key_node : keys_node.getChildrenList()) {
keys.add((Key) Utils.createSuperObject(key_node, SuperObjectType.KEY));
}
all_keys_needed = all_keys_needed_node.getBoolean(false);
} catch (Exception e) {
throw new RuntimeException("Exception creating Multi Key!", e);
}
}
示例4: EntityCase
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public EntityCase(ConfigurationNode node) {
super(node);
try {
ConfigurationNode entity_uuid_node = node.getNode("ENTITY_UUID");
ConfigurationNode start_preview_on_left_click_node = node.getNode("START_PREVIEW_ON_LEFT_CLICK");
if (entity_uuid_node.isVirtual()) {
throw new RuntimeException("ENTITY_UUID node does not exist!");
}
entity_uuid = entity_uuid_node.getValue(TypeToken.of(UUID.class));
start_preview_on_left_click = start_preview_on_left_click_node.getBoolean(false);
} catch (Exception e) {
throw new RuntimeException("Exception creating Entity Case!", e);
}
}
示例5: ItemCase
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public ItemCase(ConfigurationNode node) {
super(node);
try {
ConfigurationNode item_node = node.getNode("ITEM");
ConfigurationNode start_preview_on_left_click_node = node.getNode("START_PREVIEW_ON_LEFT_CLICK");
if (item_node.isVirtual()) {
throw new RuntimeException("ITEM node does not exist!");
}
item = Utils.parseItem(item_node);
start_preview_on_left_click = start_preview_on_left_click_node.getBoolean(false);
} catch (Exception e) {
throw new RuntimeException("Exception creating Item Case!", e);
}
}
示例6: OrderedChangeMode
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public OrderedChangeMode(ConfigurationNode node) {
super(node);
try {
ConfigurationNode right_node = node.getNode("RIGHT");
right = right_node.getBoolean(false);
} catch (Exception e) {
throw new RuntimeException("Exception creating Ordered First Gui Decorative Items Change Mode!", e);
}
}
示例7: parseCommand
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static CommandsDrop.Command parseCommand(ConfigurationNode node) {
ConfigurationNode cmd_node = node.getNode("CMD");
ConfigurationNode console_node = node.getNode("CONSOLE");
if (cmd_node.isVirtual()) {
throw new RuntimeException("CMD node does not exist!");
}
String cmd = cmd_node.getString();
boolean console = console_node.getBoolean(true);
return new CommandsDrop.Command(cmd, console);
}
示例8: getAllianceFriendlyFire
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static boolean getAllianceFriendlyFire()
{
ConfigurationNode friendlyFireNode = ConfigAccess.getConfig(mainConfig).getNode("eaglefactions", "friendlyFire", "alliance");
Boolean friendlyFire = friendlyFireNode.getBoolean();
return friendlyFire;
}
示例9: getMobSpawning
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static boolean getMobSpawning()
{
ConfigurationNode mobSpawningNode = ConfigAccess.getConfig(mainConfig).getNode("eaglefactions", "spawn", "mobs");
boolean mobSpawning = mobSpawningNode.getBoolean();
return mobSpawning;
}
示例10: getBlockEnteringFactions
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static boolean getBlockEnteringFactions()
{
ConfigurationNode mobSpawningNode = ConfigAccess.getConfig(mainConfig).getNode("eaglefactions", "gameplay", "blockEnteringFactions");
boolean mobSpawning = mobSpawningNode.getBoolean();
return mobSpawning;
}
示例11: shouldBlockSafeZoneFromWarZone
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static boolean shouldBlockSafeZoneFromWarZone()
{
ConfigurationNode blockSafeZoneFromWarZoneNode = ConfigAccess.getConfig(mainConfig).getNode("eaglefactions", "gameplay", "blockSafeZoneWhileInWarZone");
boolean blockSafeZoneFromWarZone = blockSafeZoneFromWarZoneNode.getBoolean();
return blockSafeZoneFromWarZone;
}
示例12: isPlayerLimit
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static boolean isPlayerLimit()
{
ConfigurationNode isPlayerLimitNode = ConfigAccess.getConfig(mainConfig).getNode("eaglefactions", "playerlimit", "playerlimit");
boolean playerLimit = isPlayerLimitNode.getBoolean();
return playerLimit;
}
示例13: shouldDisplayRank
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static Boolean shouldDisplayRank()
{
ConfigurationNode rankNode = ConfigAccess.getConfig(mainConfig).getNode("eaglefactions", "chat", "factionrank");
Boolean rank = rankNode.getBoolean();
return rank;
}
示例14: getCreateByItems
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static boolean getCreateByItems()
{
ConfigurationNode createByItemsNode = ConfigAccess.getConfig(mainConfig).getNode("eaglefactions", "gameplay", "factioncreation", "createbyitems");
boolean createByItems = createByItemsNode.getBoolean();
return createByItems;
}
示例15: getFactionFriendlyFire
import ninja.leaping.configurate.ConfigurationNode; //导入方法依赖的package包/类
public static boolean getFactionFriendlyFire(String factionName)
{
ConfigurationNode friendlyFireNode = ConfigAccess.getConfig(factionsConfig).getNode("factions", factionName, "friendlyfire");
Boolean friendlyFire = friendlyFireNode.getBoolean();
return friendlyFire;
}