Super Ability config pt 2

This commit is contained in:
nossr50 2019-03-18 09:16:11 -07:00
parent 3a21a913c6
commit 7d2e76e464
7 changed files with 178 additions and 3 deletions

View File

@ -65,6 +65,10 @@ Version 2.2.0
Hardcore config options will now be found in "hardcore.conf"
Super Ability conifg options will now be found in "skill_super_abilities.conf"
Super Abilities now have a default max length cap of one minute
Blast Mining default cooldown increased from 60 seconds to 120 seconds
Exploit related config options will now be found in "exploit-prevention"
Exploit Prevention's "EndermanEndermiteFarms" renamed -> "Endermen-Endermite-Fix"
Added toggle for pistons marking natural blocks as unnatural after being moved to prevent afk stone farms

View File

@ -0,0 +1,64 @@
package com.gmail.nossr50.config.hocon.superabilities;
import ninja.leaping.configurate.objectmapping.Setting;
import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable;
@ConfigSerializable
public class ConfigSectionSuperAbilityCooldowns {
@Setting(value = "Berserk")
private int berserk = 240;
@Setting(value = "Giga-Drill-Breaker")
private int gigaDrillBreaker = 240;
@Setting(value = "Green-Terra")
private int greenTerra = 240;
@Setting(value = "Serrated-Strikes")
private int serratedStrikes = 240;
@Setting(value = "Skull-Splitter")
private int skullSplitter = 240;
@Setting(value = "Super-Breaker")
private int superBreaker = 240;
@Setting(value = "Tree-Feller")
private int treeFeller = 240;
@Setting(value = "Blast-Mining")
private int blastMining = 120;
public int getBerserk() {
return berserk;
}
public int getGigaDrillBreaker() {
return gigaDrillBreaker;
}
public int getGreenTerra() {
return greenTerra;
}
public int getSerratedStrikes() {
return serratedStrikes;
}
public int getSkullSplitter() {
return skullSplitter;
}
public int getSuperBreaker() {
return superBreaker;
}
public int getTreeFeller() {
return treeFeller;
}
public int getBlastMining() {
return blastMining;
}
}

View File

@ -0,0 +1,16 @@
package com.gmail.nossr50.config.hocon.superabilities;
import ninja.leaping.configurate.objectmapping.Setting;
import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable;
@ConfigSerializable
public class ConfigSectionSuperAbilityLimits {
public static final int TOOL_DURABILITY_DAMAGE_DEFAULT = 1;
@Setting(value = "Tree-Feller", comment = "Options for Tree Feller")
private ConfigSectionTreeFeller treeFeller = new ConfigSectionTreeFeller();
@Setting(value = "Tool-Durability-Damage", comment = "Increase this number to cause more durability loss for tools when using super abilities." +
"\nDefault value: "+TOOL_DURABILITY_DAMAGE_DEFAULT)
private int toolDurabilityDamage = TOOL_DURABILITY_DAMAGE_DEFAULT;
}

View File

@ -0,0 +1,54 @@
package com.gmail.nossr50.config.hocon.superabilities;
import ninja.leaping.configurate.objectmapping.Setting;
public class ConfigSectionSuperAbilityMaxLength {
@Setting(value = "Berserk")
private int berserk = 60;
@Setting(value = "Giga-Drill-Breaker")
private int gigaDrillBreaker = 60;
@Setting(value = "Green-Terra")
private int greenTerra = 60;
@Setting(value = "Serrated-Strikes")
private int serratedStrikes = 60;
@Setting(value = "Skull-Splitter")
private int skullSplitter = 60;
@Setting(value = "Super-Breaker")
private int superBreaker = 60;
@Setting(value = "Tree-Feller")
private int treeFeller = 60;
public int getBerserk() {
return berserk;
}
public int getGigaDrillBreaker() {
return gigaDrillBreaker;
}
public int getGreenTerra() {
return greenTerra;
}
public int getSerratedStrikes() {
return serratedStrikes;
}
public int getSkullSplitter() {
return skullSplitter;
}
public int getSuperBreaker() {
return superBreaker;
}
public int getTreeFeller() {
return treeFeller;
}
}

View File

@ -0,0 +1,15 @@
package com.gmail.nossr50.config.hocon.superabilities;
import ninja.leaping.configurate.objectmapping.Setting;
import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable;
@ConfigSerializable
public class ConfigSectionTreeFeller {
public static final int TREE_FELLER_LIMIT_DEFAULT = 500;
@Setting(value = "Tree-Size-Limit", comment = "Trees over this many blocks in size will not activate" +
"\nLower this number to improve performance." +
"\nDefault value: "+TREE_FELLER_LIMIT_DEFAULT)
private int treeFellerLimit = TREE_FELLER_LIMIT_DEFAULT;
}

View File

@ -1,8 +1,33 @@
package com.gmail.nossr50.config.hocon.superabilities;
import ninja.leaping.configurate.objectmapping.Setting;
import ninja.leaping.configurate.objectmapping.serialize.ConfigSerializable;
@ConfigSerializable
public class ConfigSuperAbilities {
public static final boolean SUPER_ABILITY_DEFAULT = true;
public static final boolean MUST_SNEAK_TO_ACTIVATE_DEFAULT = false;
@Setting(value = "Enable-Super-Abilities",
comment = "Turn this off to disable all super abilities." +
"\nDefault value: "+SUPER_ABILITY_DEFAULT)
private boolean superAbilitiesEnabled = SUPER_ABILITY_DEFAULT;
@Setting(value = "Require-Sneaking",
comment = "Players must be sneaking in order to activate super abilities." +
"\nDefault value: "+MUST_SNEAK_TO_ACTIVATE_DEFAULT)
private boolean mustSneakToActivate = MUST_SNEAK_TO_ACTIVATE_DEFAULT;
@Setting(value = "Super-Ability-Cooldowns",
comment = "How many seconds players must wait before they can use a super ability again.")
private ConfigSectionSuperAbilityCooldowns superAbilityCooldowns = new ConfigSectionSuperAbilityCooldowns();
@Setting(value = "Super-Ability-Max-Length",
comment = "The maximum amount of time a player can use a super ability." +
"\nMost super abilities get longer as a player grows in skill.")
private ConfigSectionSuperAbilityMaxLength superAbilityMaxLength = new ConfigSectionSuperAbilityMaxLength();
@Setting(value = "Super-Ability-Settings", comment = "Change specific parameters for super abilities.")
private ConfigSectionSuperAbilityLimits superAbilityLimits = new ConfigSectionSuperAbilityLimits();
}

View File

@ -13,8 +13,6 @@
# Settings for the Skills
###
# Enables anonymous statistics
Metrics:
bstats: true
Feedback:
SkillCommand:
BlankLinesAboveHeader: true
@ -75,7 +73,6 @@ Feedback:
SendCopyOfMessageToChat: true
Skills:
General:
StartingLevel: 1
Ability:
Length:
Standard: