From: Erik V. <ev...@us...> - 2012-04-01 11:56:03
|
rails/game/PublicCompany.java | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) New commits: commit a9a425403147d11fba8559e7798dde93a850d9aa Author: Erik Vos <eri...@xs...> Date: Sun Apr 1 13:55:40 2012 +0200 1830: fixed wrong worth calculation for Prussian shares. For PR, the market price applies to 2 (5%) share units. This (unique) difeerence was overlooked in teh worth calculation. diff --git a/rails/game/PublicCompany.java b/rails/game/PublicCompany.java index 48c56ed..92c045e 100644 --- a/rails/game/PublicCompany.java +++ b/rails/game/PublicCompany.java @@ -792,7 +792,7 @@ public class PublicCompany extends Company implements PublicCompanyI { name + "_" + colour + "_ExtraTileTurns", turns)); } - + /** Reset turn objects */ public void initTurn() { @@ -1024,7 +1024,7 @@ public class PublicCompany extends Company implements PublicCompanyI { public boolean hasFloated() { return hasFloated.booleanValue(); } - + public ModelObject getFloatedModel() { return hasFloated; } @@ -1160,7 +1160,7 @@ public class PublicCompany extends Company implements PublicCompanyI { * @return */ public int getGameEndPrice() { - return getMarketPrice(); + return getMarketPrice()/getShareUnitsForSharePrice(); } /** @@ -1968,7 +1968,7 @@ public class PublicCompany extends Company implements PublicCompanyI { // New style int tileLays = phase.getTileLaysPerColour(getTypeName(), tileColour); - + if (tileLays <= 1) { extraTileLays = null; return tileLays; @@ -1979,8 +1979,8 @@ public class PublicCompany extends Company implements PublicCompanyI { if (turnsWithExtraTileLays != null) { extraTiles = turnsWithExtraTileLays.get(tileColour); } - - + + if (extraTiles != null) { if (extraTiles.intValue() == 0) { extraTiles = null; |