mirror of
https://github.com/TotalFreedomMC/TF-ProjectKorra.git
synced 2025-02-11 11:40:40 +00:00
Make Air Particles Configurable
Defaults to smoke (White Clouds) Other options are: blacksmoke (The original Airbending Particles) spell (the swirly potion particles)
This commit is contained in:
parent
7e3b8ceb21
commit
848b61f65d
4 changed files with 43 additions and 21 deletions
23
.classpath
23
.classpath
|
@ -2,18 +2,15 @@
|
||||||
<classpath>
|
<classpath>
|
||||||
<classpathentry kind="src" path="src"/>
|
<classpathentry kind="src" path="src"/>
|
||||||
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
|
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER"/>
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/ProjectKorra/Factions.jar"/>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/CombatTag.jar"/>
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/ProjectKorra/GriefPrevention-282.jar"/>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/Factions.jar"/>
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/ProjectKorra/mcore 7.2.1.jar"/>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/GriefPrevention.jar"/>
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/ProjectKorra/PreciousStones.jar"/>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/mcore.jar"/>
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/ProjectKorra/TagAPI.jar"/>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/PreciousStones.jar"/>
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/ProjectKorra/Towny.jar"/>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/TagAPI.jar"/>
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/bukkit-1.7.9-R0.2.jar">
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/Towny.jar"/>
|
||||||
<attributes>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/WorldEdit.jar"/>
|
||||||
<attribute name="javadoc_location" value="http://jd.bukkit.org/dev/apidocs"/>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/Bending Plugins/WorldGuard.jar"/>
|
||||||
</attributes>
|
<classpathentry kind="lib" path="C:/Users/Shawn/Documents/LocalServer/BukkitForPlugins.jar"/>
|
||||||
</classpathentry>
|
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/WorldEdit-5.9.jar"/>
|
|
||||||
<classpathentry kind="lib" path="E:/Jack/Game dev/bukkit lib/WorldGuard-5.9.jar"/>
|
|
||||||
<classpathentry kind="output" path="bin"/>
|
<classpathentry kind="output" path="bin"/>
|
||||||
</classpath>
|
</classpath>
|
||||||
|
|
|
@ -64,6 +64,7 @@ public class ConfigManager {
|
||||||
config.addDefault("Properties.RegionProtection.RespectPreciousStones", true);
|
config.addDefault("Properties.RegionProtection.RespectPreciousStones", true);
|
||||||
|
|
||||||
config.addDefault("Properties.Air.CanBendWithWeapons", false);
|
config.addDefault("Properties.Air.CanBendWithWeapons", false);
|
||||||
|
config.addDefault("Properties.Air.Particles", "smoke");
|
||||||
|
|
||||||
config.addDefault("Properties.Water.CanBendWithWeapons", true);
|
config.addDefault("Properties.Water.CanBendWithWeapons", true);
|
||||||
config.addDefault("Properties.Water.NightFactor", 1.5);
|
config.addDefault("Properties.Water.NightFactor", 1.5);
|
||||||
|
|
|
@ -1472,10 +1472,33 @@ public class Methods {
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void playAirbendingParticles(Location loc) {
|
public static void playAirbendingParticles(Location loc) {
|
||||||
|
String particle = plugin.getConfig().getString("Properties.Air.Particles");
|
||||||
|
if (particle == null) {
|
||||||
for (int i = 0; i < 20; i++) {
|
for (int i = 0; i < 20; i++) {
|
||||||
ParticleEffect.CLOUD.display(loc, (float) Math.random(), (float) Math.random(), (float) Math.random(), 0, 1);
|
ParticleEffect.CLOUD.display(loc, (float) Math.random(), (float) Math.random(), (float) Math.random(), 0, 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
else if (particle.equalsIgnoreCase("spell")) {
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
ParticleEffect.SPELL.display(loc, (float) Math.random(), (float) Math.random(), (float) Math.random(), 0, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (particle.equalsIgnoreCase("blacksmoke")) {
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
ParticleEffect.SMOKE.display(loc, (float) Math.random(), (float) Math.random(), (float) Math.random(), 0, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (particle.equalsIgnoreCase("smoke")) {
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
ParticleEffect.CLOUD.display(loc, (float) Math.random(), (float) Math.random(), (float) Math.random(), 0, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
ParticleEffect.CLOUD.display(loc, (float) Math.random(), (float) Math.random(), (float) Math.random(), 0, 1);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public static void playFocusWaterEffect(Block block) {
|
public static void playFocusWaterEffect(Block block) {
|
||||||
block.getWorld().playEffect(block.getLocation(), Effect.SMOKE, 4, 20);
|
block.getWorld().playEffect(block.getLocation(), Effect.SMOKE, 4, 20);
|
||||||
|
|
|
@ -34,6 +34,7 @@ Properties:
|
||||||
RespectPreciousStones: true
|
RespectPreciousStones: true
|
||||||
Air:
|
Air:
|
||||||
CanBendWithWeapons: false
|
CanBendWithWeapons: false
|
||||||
|
Particles: smoke
|
||||||
Water:
|
Water:
|
||||||
CanBendWithWeapons: false
|
CanBendWithWeapons: false
|
||||||
NightFactor: 1.5
|
NightFactor: 1.5
|
||||||
|
|
Loading…
Reference in a new issue