Add Config Options for Shockwave

This commit is contained in:
MistPhizzle 2014-07-29 10:40:22 -04:00
parent 33e4d6a6fb
commit 2a4cf0bd1d
3 changed files with 8 additions and 3 deletions

View file

@ -378,7 +378,9 @@ public class ConfigManager {
+ "Anything caught in the shockwave will be blasted back and dealt damage. "
+ "If you instead click while charged, the disruption is focused in a cone in front of you. "
+ "Lastly, if you fall from a great enough height with this ability selected, you will automatically create a shockwave.");
config.addDefault("Abilities.Earth.Shockwave.FallThreshold", 10);
config.addDefault("Abilities.Earth.Shockwave.ChargeTime", 2500);
config.addDefault("Abilities.Earth.Tremorsense.Enabled", true);
config.addDefault("Abilities.Earth.Tremorsense.Description", "This is a pure utility ability for earthbenders. If you are in an area of low-light and are standing on top of an earthbendable block, this ability will automatically turn that block into glowstone, visible *only by you*. If you lose contact with a bendable block, the light will go out as you have lost contact with the earth and cannot 'see' until you can touch earth again. Additionally, if you click with this ability selected, smoke will appear above nearby earth with pockets of air beneath them.");
config.addDefault("Abilities.Earth.Tremorsense.MaxDepth", 10);

View file

@ -8,6 +8,7 @@ import org.bukkit.entity.Player;
import org.bukkit.util.Vector;
import com.projectkorra.ProjectKorra.Methods;
import com.projectkorra.ProjectKorra.ProjectKorra;
import com.projectkorra.ProjectKorra.Ability.AvatarState;
public class Shockwave {
@ -15,8 +16,8 @@ public class Shockwave {
private static ConcurrentHashMap<Player, Shockwave> instances = new ConcurrentHashMap<Player, Shockwave>();
private static final double angle = Math.toRadians(40);
private static final long defaultchargetime = 2500;
private static final double threshold = 10;
private static final long defaultchargetime = ProjectKorra.plugin.getConfig().getLong("Abilities.Earth.Shockwave.ChargeTime");
private static final double threshold = ProjectKorra.plugin.getConfig().getDouble("Abilities.Earth.Shockwave.FallThreshold");
private Player player;
private long starttime;

View file

@ -273,6 +273,8 @@ Abilities:
Shockwave:
Enabled: true
Description: "This is one of the most powerful moves in the earthbender's arsenal. To use, you must first charge it by holding sneak (default: shift). Once charged, you can release sneak to create an enormous shockwave of earth, disturbing all earth around you and expanding radially outwards. Anything caught in the shockwave will be blasted back and dealt damage. If you instead click while charged, the disruption is focused in a cone in front of you. Lastly, if you fall from a great enough height with this ability selected, you will automatically create a shockwave."
ChargeTime: 2500
FallThreshold: 10
Tremorsense:
Enabled: true
Description: "This is a pure utility ability for earthbenders. If you are in an area of low-light and are standing on top of an earthbendable block, this ability will automatically turn that block into glowstone, visible *only by you*. If you lose contact with a bendable block, the light will go out as you have lost contact with the earth and cannot 'see' until you can touch earth again. Additionally, if you click with this ability selected, smoke will appear above nearby earth with pockets of air beneath them."