Browse Source

zerg multiplier debug text

lakebane-master
FatBoy-DOTC 10 months ago
parent
commit
9ab286166e
  1. 50
      src/engine/gameManager/ZergManager.java
  2. 12
      src/engine/objects/City.java
  3. 6
      src/engine/objects/Mine.java

50
src/engine/gameManager/ZergManager.java

@ -2,9 +2,10 @@ package engine.gameManager;
import engine.objects.Bane; import engine.objects.Bane;
import engine.objects.Guild; import engine.objects.Guild;
import engine.objects.PlayerCharacter;
public class ZergManager { public class ZergManager {
public static float getMultiplier5Man(int count){ public static float getMultiplier5Man(int count, PlayerCharacter pc){
float multiplier = 1.0f; float multiplier = 1.0f;
switch(count){ switch(count){
case 1: case 1:
@ -34,10 +35,14 @@ public class ZergManager {
multiplier -= 1.0f; multiplier -= 1.0f;
break; break;
} }
return multiplier; ChatManager.chatSystemInfo(pc,"Zerg Multiplier Set: " + multiplier);
if(multiplier == 0.0f)
return 1.0f;
else
return multiplier;
} }
public static float getMultiplier10Man(int count){ public static float getMultiplier10Man(int count, PlayerCharacter pc){
float multiplier = 1.0f; float multiplier = 1.0f;
if(count <=4) if(count <=4)
return 0.0f; return 0.0f;
@ -88,10 +93,14 @@ public class ZergManager {
multiplier -= 1.0f; multiplier -= 1.0f;
break; break;
} }
return multiplier; ChatManager.chatSystemInfo(pc,"Zerg Multiplier Set: " + multiplier);
if(multiplier == 0.0f)
return 1.0f;
else
return multiplier;
} }
public static float getMultiplier20Man(int count){ public static float getMultiplier20Man(int count, PlayerCharacter pc){
float multiplier = 1.0f; float multiplier = 1.0f;
if(count < 10){ if(count < 10){
multiplier += 1.25f; multiplier += 1.25f;
@ -162,7 +171,11 @@ public class ZergManager {
break; break;
} }
} }
return multiplier; ChatManager.chatSystemInfo(pc,"Zerg Multiplier Set: " + multiplier);
if(multiplier == 0.0f)
return 1.0f;
else
return multiplier;
} }
public static int getBaneCapSize(Guild defender){ public static int getBaneCapSize(Guild defender){
@ -193,18 +206,31 @@ public class ZergManager {
} }
return capSize; return capSize;
} }
public static float getMultiplier30Man(int count){ public static float getMultiplier30Man(int count, PlayerCharacter pc){
float multiplier = 1.0f; float multiplier = 1.0f;
return multiplier; ChatManager.chatSystemInfo(pc,"Zerg Multiplier Set: " + multiplier);
if(multiplier == 0.0f)
return 1.0f;
else
return multiplier;
} }
public static float getMultiplier40Man(int count){ public static float getMultiplier40Man(int count, PlayerCharacter pc){
float multiplier = 1.0f; float multiplier = 1.0f;
return multiplier; ChatManager.chatSystemInfo(pc,"Zerg Multiplier Set: " + multiplier);
if(multiplier == 0.0f)
return 1.0f;
else
return multiplier;
} }
public static float getMultiplierUnlimited(int count){ public static float getMultiplierUnlimited(int count, PlayerCharacter pc){
float multiplier = 1.0f; float multiplier = 1.0f;
return multiplier;
ChatManager.chatSystemInfo(pc,"Zerg Multiplier Set: " + multiplier);
if(multiplier == 0.0f)
return 1.0f;
else
return multiplier;
} }
} }

12
src/engine/objects/City.java

@ -1446,22 +1446,22 @@ public class City extends AbstractWorldObject {
int count = this.dividedPlayers.get(player.getGuild().getNation()).size(); int count = this.dividedPlayers.get(player.getGuild().getNation()).size();
switch(this.getBane().capSize){ switch(this.getBane().capSize){
case 5: case 5:
player.ZergMultiplier = ZergManager.getMultiplier5Man(count); player.ZergMultiplier = ZergManager.getMultiplier5Man(count,player);
break; break;
case 10: case 10:
player.ZergMultiplier = ZergManager.getMultiplier10Man(count); player.ZergMultiplier = ZergManager.getMultiplier10Man(count,player);
break; break;
case 20: case 20:
player.ZergMultiplier = ZergManager.getMultiplier20Man(count); player.ZergMultiplier = ZergManager.getMultiplier20Man(count,player);
break; break;
case 30: case 30:
player.ZergMultiplier = ZergManager.getMultiplier30Man(count); player.ZergMultiplier = ZergManager.getMultiplier30Man(count,player);
break; break;
case 40: case 40:
player.ZergMultiplier = ZergManager.getMultiplier40Man(count); player.ZergMultiplier = ZergManager.getMultiplier40Man(count,player);
break; break;
case 9999999: case 9999999:
player.ZergMultiplier = ZergManager.getMultiplierUnlimited(count); player.ZergMultiplier = ZergManager.getMultiplierUnlimited(count,player);
break; break;
} }
} else{ } else{

6
src/engine/objects/Mine.java

@ -642,13 +642,13 @@ public class Mine extends AbstractGameObject {
int count = this.dividedPlayers.get(player.getGuild().getNation()).size(); int count = this.dividedPlayers.get(player.getGuild().getNation()).size();
switch(this.capSize){ switch(this.capSize){
case 5: case 5:
player.ZergMultiplier = ZergManager.getMultiplier5Man(count); player.ZergMultiplier = ZergManager.getMultiplier5Man(count,player);
break; break;
case 10: case 10:
player.ZergMultiplier = ZergManager.getMultiplier10Man(count); player.ZergMultiplier = ZergManager.getMultiplier10Man(count,player);
break; break;
case 20: case 20:
player.ZergMultiplier = ZergManager.getMultiplier20Man(count); player.ZergMultiplier = ZergManager.getMultiplier20Man(count,player);
break; break;
} }
} else{ } else{

Loading…
Cancel
Save