Make combustion do damage

This commit is contained in:
MistPhizzle 2014-08-03 01:29:47 -04:00
parent e3f67b0e8b
commit 5464be5fae
4 changed files with 10 additions and 3 deletions

View file

@ -402,7 +402,8 @@ public class ConfigManager {
config.addDefault("Abilities.Fire.Combustion.Cooldown", 25000);
config.addDefault("Abilities.Fire.Combustion.ChargeTime", 5000);
config.addDefault("Abilities.Fire.Combustion.BreakBlocks", false);
config.addDefault("Abilities.Fire.Combustion.Power", 1);
config.addDefault("Abilities.Fire.Combustion.Power", 1.0);
// config.addDefault("Abilities.Fire.Combustion.Damage", 5);
config.addDefault("Abilities.Fire.FireBlast.Enabled", true);
config.addDefault("Abilities.Fire.FireBlast.Description","FireBlast is the most fundamental bending technique of a firebender. "

View file

@ -182,6 +182,12 @@ public class PKListener implements Listener {
if (Combustion.fireballs.contains(id)) {
Location loc = event.getEntity().getLocation();
loc.getWorld().createExplosion(loc.getX(), loc.getY(), loc.getZ(), (float) ProjectKorra.plugin.getConfig().getDouble("Abilities.Fire.Combustion.Power"), true, ProjectKorra.plugin.getConfig().getBoolean("Abilities.Fire.Combustion.BreakBlocks"));
// for (Entity en: Methods.getEntitiesAroundPoint(loc, 4)) {
// if (en instanceof LivingEntity) {
// LivingEntity le = (LivingEntity) en;
// le.damage(ProjectKorra.plugin.getConfig().getDouble("Abilities.Fire.Combustion.Damage"));
// }
// }
}
}

View file

@ -75,7 +75,7 @@ public class Combustion {
if (charged) {
if (player.isSneaking()) {
player.getWorld().playEffect(player.getEyeLocation(), Effect.SMOKE, 10);
player.getWorld().playEffect(player.getEyeLocation(), Effect.SMOKE, 4, 3);
} else {
launchFireball();
cooldowns.put(player.getName(), System.currentTimeMillis());

View file

@ -298,7 +298,7 @@ Abilities:
Cooldown: 25000
ChargeTime: 5000
BreakBlocks: false
Power: 1
Power: 1.0
FireBlast:
Enabled: true
Description: "FireBlast is the most fundamental technique of a firebender. To use, simply left-click in a direction. A blast of fire will be created at your fingertips. If this blast contacts an enemy, it will dissipate and engulf them in flames, doing additional damage and knocking them back slightly. If the blast hits terrain, it will ignite the nearby area. Additionally, if you hold sneak, you will charge up the fireblast. If you release it when it's charged, it will instead launch a powerful fireball that explodes on contact."