Chris' Fix PR

Config fix
Air/Fire laggyness fix #1
Combo fix
/b who restructure
This commit is contained in:
OmniCypher 2015-08-02 15:17:41 -07:00
parent ced03652de
commit 52d83f35de
18 changed files with 60 additions and 47 deletions

View file

@ -1555,7 +1555,7 @@ public class Commands {
}
}
}
if (GeneralMethods.hasRPG()) {
if (RPGMethods.isCurrentAvatar(p.getUniqueId())) {
s.sendMessage(GeneralMethods.getAvatarColor() + "Current Avatar");
@ -1563,44 +1563,56 @@ public class Commands {
s.sendMessage(GeneralMethods.getAvatarColor() + "Former Avatar");
}
}
//Administrators
if (uuid2.toString().equals("8621211e-283b-46f5-87bc-95a66d68880e")) {
s.sendMessage(ChatColor.RED + "ProjectKorra Founder"); // MistPhizzle
}
//Lead Developer
if (uuid2.toString().equals("a197291a-cd78-43bb-aa38-52b7c82bc68c")) {
s.sendMessage(ChatColor.DARK_PURPLE + "ProjectKorra Lead Developer"); // OmniCypher
}
if (uuid2.toString().equals("929b14fc-aaf1-4f0f-84c2-f20c55493f53")) { // vidcom
s.sendMessage(ChatColor.GREEN + "ProjectKorra Concept Designer");
s.sendMessage(ChatColor.GOLD + "ProjectKorra Head Moderator");
//Head Concept Designer
if (uuid2.toString().equals("929b14fc-aaf1-4f0f-84c2-f20c55493f53")) { // Vidcom
s.sendMessage(ChatColor.GREEN + "ProjectKorra Head Concept Designer");
}
//Head Community Moderator
if (uuid2.toString().equals("")) {
s.sendMessage(ChatColor.GOLD + "ProjectKorra Head Community Moderator");
}
//Digital Director
if (uuid2.toString().equals("15d1a5a7-76ef-49c3-b193-039b27c47e30")) { // Kiam
s.sendMessage(ChatColor.GREEN + "ProjectKorra Digital Director");
}
//Developers
if (uuid2.toString().equals("833a7132-a9ec-4f0a-ad9c-c3d6b8a1c7eb") // Jacklin213
|| uuid2.toString().equals("96f40c81-dd5d-46b6-9afe-365114d4a082") // Coolade
|| uuid2.toString().equals("81adae76-d647-4b41-bfb0-8166516fa189") // AlexTheCoder
|| uuid2.toString().equals("7bb267eb-cf0b-4fb9-a697-27c2a913ed92")) { // Finn
|| uuid2.toString().equals("81adae76-d647-4b41-bfb0-8166516fa189")) { // AlexTheCoder
s.sendMessage(ChatColor.DARK_PURPLE + "ProjectKorra Developer");
}
if (uuid2.toString().equals("9c18ff57-04b3-4841-9726-9d64373d0d65")) { // coastyo
s.sendMessage(ChatColor.GREEN + "ProjectKorra Concept Designer");
s.sendMessage(ChatColor.BLUE + "ProjectKorra Graphic Artist");
}
if (uuid2.toString().equals("b2d82a84-ce22-4518-a8fc-1b28aeda0c0b") // Shunky
|| uuid2.toString().equals("623df34e-9cd4-438d-b07c-1905e1fc46b6") // Loony
//Concept Designers
if (uuid2.toString().equals("623df34e-9cd4-438d-b07c-1905e1fc46b6") // Loony
|| uuid2.toString().equals("80f9072f-e37e-4adc-8675-1ba6af87d63b") // Cross
|| uuid2.toString().equals("38217173-8a32-4ba7-9fe1-dd4fed031a74") // Fly
|| uuid2.toString().equals("15d1a5a7-76ef-49c3-b193-039b27c47e30")) { // Kiam
|| uuid2.toString().equals("38217173-8a32-4ba7-9fe1-dd4fed031a74")) { // Fly
s.sendMessage(ChatColor.GREEN + "ProjectKorra Concept Designer");
}
if (uuid2.toString().equals("0fd77ff6-07fb-4a7d-ba87-ae6f802ed1f9")) { // Hit_Manx
s.sendMessage(ChatColor.GREEN + "ProjectKorra Concept Designer");
s.sendMessage(ChatColor.GOLD + "ProjectKorra Wiki Contributor");
//Community Moderators
if (uuid2.toString().equals("")) {
s.sendMessage(ChatColor.GOLD + "ProjectKorra Community Moderator");
}
//Digital Team
if (uuid2.toString().equals("")) {
s.sendMessage(ChatColor.BLUE + "ProjectKorra Digital Team");
}
return true;
}
if (args.length == 1) {

View file

@ -139,7 +139,7 @@ public class AirBlast extends CoreAbility {
return;
}
AirMethods.playAirbendingParticles(origin, 10);
AirMethods.playAirbendingParticles(origin, 6);
// origin.getWorld().playEffect(origin, Effect.SMOKE, 4,
// (int) originselectrange);
}
@ -168,7 +168,7 @@ public class AirBlast extends CoreAbility {
private void advanceLocation() {
if (showParticles)
AirMethods.playAirbendingParticles(location, 10);
AirMethods.playAirbendingParticles(location, 6);
if (GeneralMethods.rand.nextInt(4) == 0) {
AirMethods.playAirbendingSound(location);
}

View file

@ -88,7 +88,7 @@ public class AirCombo implements ConfigLoadable {
return;
if (!bPlayer.hasElement(Element.Air))
return;
if (GeneralMethods.canBend(player.getDisplayName(), ability)) {
if (!GeneralMethods.canBend(player.getName(), ability)) {
return;
}
if (GeneralMethods.isRegionProtectedFromBuild(player, "AirBlast", player.getLocation()))

View file

@ -186,7 +186,7 @@ public class AirScooter extends CoreAbility {
double x = Math.cos(Math.toRadians(angles.get(i))) * scooterradius;
double y = ((double) i) / 2 * scooterradius - scooterradius;
double z = Math.sin(Math.toRadians(angles.get(i))) * scooterradius;
AirMethods.playAirbendingParticles(origin.clone().add(x, y, z), 10);
AirMethods.playAirbendingParticles(origin.clone().add(x, y, z), 7);
// player.getWorld().playEffect(origin.clone().add(x, y, z),
// Effect.SMOKE, 4, (int) AirBlast.defaultrange);
}

View file

@ -197,7 +197,7 @@ public class AirShield extends CoreAbility {
Location effect = new Location(origin.getWorld(), x, y, z);
if (!GeneralMethods.isRegionProtectedFromBuild(player, "AirShield", effect)) {
AirMethods.playAirbendingParticles(effect, 10);
AirMethods.playAirbendingParticles(effect, 5);
if (GeneralMethods.rand.nextInt(4) == 0) {
AirMethods.playAirbendingSound(effect);
}

View file

@ -172,7 +172,7 @@ public class AirSpout extends CoreAbility {
Location effectloc2 = new Location(location.getWorld(), location.getX(), block.getY() + i, location.getZ());
AirMethods.playAirbendingParticles(effectloc2, 15);
AirMethods.playAirbendingParticles(effectloc2, 6);
// location.getWorld().playEffect(effectloc2, Effect.SMOKE,
// (int) directions[index], (int) height + 5);

View file

@ -117,7 +117,7 @@ public class AirSuction extends CoreAbility {
return;
}
AirMethods.playAirbendingParticles(origin, 10);
AirMethods.playAirbendingParticles(origin, 6);
//
// origin.getWorld().playEffect(origin, Effect.SMOKE, 4,
// (int) originselectrange);
@ -146,7 +146,7 @@ public class AirSuction extends CoreAbility {
}
private void advanceLocation() {
AirMethods.playAirbendingParticles(location, 10);
AirMethods.playAirbendingParticles(location, 6);
if (GeneralMethods.rand.nextInt(4) == 0) {
AirMethods.playAirbendingSound(location);
}

View file

@ -162,7 +162,7 @@ public class AirSwipe extends CoreAbility {
}
}
} else {
AirMethods.playAirbendingParticles(location, 10);
AirMethods.playAirbendingParticles(location, 3);
if (GeneralMethods.rand.nextInt(4) == 0) {
AirMethods.playAirbendingSound(location);
}
@ -334,7 +334,7 @@ public class AirSwipe extends CoreAbility {
pushfactor *= factor;
return true;
} else if (System.currentTimeMillis() >= time + maxchargetime) {
AirMethods.playAirbendingParticles(player.getEyeLocation(), 10);
AirMethods.playAirbendingParticles(player.getEyeLocation(), 3);
}
}
return true;

View file

@ -14,14 +14,14 @@ public class AirbendingManager implements Runnable {
@Override
public void run() {
AirBlast.progressAll(AirBlast.class);
AirBlast.progressAll();
AirPassive.handlePassive(Bukkit.getServer());
AirBurst.progressAll(AirBurst.class);
AirScooter.progressAll(AirScooter.class);
Suffocate.progressAll(Suffocate.class);
AirSpout.progressAll(AirSpout.class);
AirBubble.handleBubbles(Bukkit.getServer());
AirSuction.progressAll(AirSuction.class);
AirSuction.progressAll();
AirSwipe.progressAll(AirSwipe.class);
Tornado.progressAll(Tornado.class);
AirShield.progressAll(AirShield.class);

View file

@ -234,7 +234,7 @@ public class Tornado extends CoreAbility {
Location effect = new Location(origin.getWorld(), x, y, z);
if (!GeneralMethods.isRegionProtectedFromBuild(player, "AirBlast", effect)) {
AirMethods.playAirbendingParticles(effect, 20);
AirMethods.playAirbendingParticles(effect, 4);
if (GeneralMethods.rand.nextInt(20) == 0) {
AirMethods.playAirbendingSound(effect);
}

View file

@ -82,7 +82,7 @@ public class ChiComboManager {
//ProjectKorra.log.info("Combo Matched for player "+player.getName());
if (combo.size() == 4 && combo.get(0) == ChiCombo.QuickStrike && combo.get(1) == ChiCombo.SwiftKick && combo.get(2) == ChiCombo.QuickStrike && combo.get(3) == ChiCombo.QuickStrike) {
if (!GeneralMethods.getBendingPlayer(player.getName()).isOnCooldown("Immobilize") && GeneralMethods.canBend(player.getDisplayName(), "Immobilize")) {
if (!GeneralMethods.getBendingPlayer(player.getName()).isOnCooldown("Immobilize") && GeneralMethods.canBend(player.getName(), "Immobilize")) {
GeneralMethods.getBendingPlayer(player.getName()).addCooldown("Immobilize", cooldown);
paralyzeTarget(player, paralysisDuration);
}

View file

@ -134,8 +134,8 @@ public class Cook extends AddonAbility {
cook();
time = System.currentTimeMillis();
}
ParticleEffect.FLAME.display(player.getEyeLocation(), 0.6F, 0.6F, 0.6F, 0, 6);
ParticleEffect.SMOKE.display(player.getEyeLocation(), 0.6F, 0.6F, 0.6F, 0, 6);
ParticleEffect.FLAME.display(player.getEyeLocation(), 0.6F, 0.6F, 0.6F, 0, 3);
ParticleEffect.SMOKE.display(player.getEyeLocation(), 0.6F, 0.6F, 0.6F, 0, 1);
return true;
}

View file

@ -156,8 +156,8 @@ public class FireBlast extends CoreAbility {
private void advanceLocation() {
if (showParticles) {
//ParticleEffect.RED_DUST.display((float) 16, (float) 111, (float) 227, 0.01F, 0, location, 256D);
ParticleEffect.FLAME.display(location, 0.6F, 0.6F, 0.6F, 0, 20);
ParticleEffect.SMOKE.display(location, 0.6F, 0.6F, 0.6F, 0, 20);
ParticleEffect.FLAME.display(location, 0.6F, 0.6F, 0.6F, 0, 12);
ParticleEffect.SMOKE.display(location, 0.6F, 0.6F, 0.6F, 0, 5);
}
location = location.add(direction.clone().multiply(speedfactor));
if (rand.nextInt(4) == 0) {

View file

@ -98,7 +98,7 @@ public class FireCombo implements ConfigLoadable {
return;
if (!GeneralMethods.getBendingPlayer(player.getName()).isToggled())
return;
if (GeneralMethods.canBend(player.getDisplayName(), ability)) {
if (!GeneralMethods.canBend(player.getName(), ability)) {
return;
}
/* End Initial Checks */

View file

@ -152,8 +152,8 @@ public class FireShield extends CoreAbility {
for (Block block : blocks) {
if (!GeneralMethods.isRegionProtectedFromBuild(player, "FireShield", block.getLocation())) {
ParticleEffect.FLAME.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 10);
ParticleEffect.SMOKE.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 10);
ParticleEffect.FLAME.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 2);
ParticleEffect.SMOKE.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 1);
if (GeneralMethods.rand.nextInt(7) == 0) {
FireMethods.playFirebendingSound(block.getLocation());
}
@ -194,7 +194,8 @@ public class FireShield extends CoreAbility {
for (Block block : blocks) {
if (!GeneralMethods.isRegionProtectedFromBuild(player, "FireShield", block.getLocation())) {
ParticleEffect.FLAME.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 20);
ParticleEffect.FLAME.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 6);
ParticleEffect.SMOKE.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 1);
if (GeneralMethods.rand.nextInt(4) == 0) {
FireMethods.playFirebendingSound(block.getLocation());
}

View file

@ -190,8 +190,8 @@ public class Fireball extends AddonAbility {
private void fireball() {
for (Block block : GeneralMethods.getBlocksAroundPoint(location, radius)) {
ParticleEffect.FLAME.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 17);
ParticleEffect.SMOKE.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 17);
ParticleEffect.FLAME.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 5);
ParticleEffect.SMOKE.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 2);
if (GeneralMethods.rand.nextInt(4) == 0) {
FireMethods.playFirebendingSound(location);
}

View file

@ -127,8 +127,8 @@ public class WallOfFire extends CoreAbility {
private void display() {
for (Block block : blocks) {
ParticleEffect.FLAME.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 6);
ParticleEffect.SMOKE.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 6);
ParticleEffect.FLAME.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 3);
ParticleEffect.SMOKE.display(block.getLocation(), 0.6F, 0.6F, 0.6F, 0, 1);
if (GeneralMethods.rand.nextInt(7) == 0) {
FireMethods.playFirebendingSound(block.getLocation());

View file

@ -98,7 +98,7 @@ public class WaterCombo {
this.ability = ability;
this.bplayer = GeneralMethods.getBendingPlayer(player.getName());
if (GeneralMethods.canBend(player.getDisplayName(), ability)) {
if (!GeneralMethods.canBend(player.getName(), ability)) {
return;
}