From: Erik V. <ev...@us...> - 2009-11-27 20:35:26
|
Update of /cvsroot/rails/18xx/rails/game/specific/_1856 In directory sfp-cvsdas-1.v30.ch3.sourceforge.com:/tmp/cvs-serv9149/rails/game/specific/_1856 Modified Files: OperatingRound_1856.java CGRFormationRound.java Log Message: Beautified report window contents & log Index: CGRFormationRound.java =================================================================== RCS file: /cvsroot/rails/18xx/rails/game/specific/_1856/CGRFormationRound.java,v retrieving revision 1.23 retrieving revision 1.24 diff -C2 -d -r1.23 -r1.24 *** CGRFormationRound.java 26 Nov 2009 20:14:30 -0000 1.23 --- CGRFormationRound.java 27 Nov 2009 20:35:18 -0000 1.24 *************** *** 58,62 **** companiesToRepayLoans = null; ! ReportBuffer.add(LocalText.getText("StartCGRFormationRound", startingPlayer.getName())); --- 58,63 ---- companiesToRepayLoans = null; ! ReportBuffer.add(LocalText.getText("StartFormationRound", ! cgrName, startingPlayer.getName())); *************** *** 81,84 **** --- 82,89 ---- } + ReportBuffer.add(LocalText.getText("StartFormationRound", + cgrName, + startingPlayer.getName())); + setStep(STEP_REPAY_LOANS); *************** *** 155,159 **** // If that was all, we're done with this company numberOfLoans = currentCompany.getCurrentNumberOfLoans(); ! if (numberOfLoans == 0) continue; // Check the president's cash --- 160,166 ---- // If that was all, we're done with this company numberOfLoans = currentCompany.getCurrentNumberOfLoans(); ! if (numberOfLoans == 0) { ! continue; ! } // Check the president's cash *************** *** 267,271 **** } ! return true; } --- 274,278 ---- } ! return true; } *************** *** 287,290 **** --- 294,299 ---- cgrSharesUsed = 0; + ReportBuffer.add(""); + do { player = getCurrentPlayer(); *************** *** 475,478 **** --- 484,502 ---- ReportBuffer.add (LocalText.getText("Floats", PublicCompany_CGR.NAME)); + // Determine the new certificate limit. + // The number of available companies is 11, + // or 12 minus the number of closed companies, whichever is lower. + int numCompanies = Math.min(11, 12-mergingCompanies.size()); + int numPlayers = gameManager.getNumberOfPlayers(); + // Need some checks here... + int newCertLimit = certLimitsTable[numPlayers-3][numCompanies-4]; + gameManager.setPlayerCertificateLimit(newCertLimit); + message = LocalText.getText("CertificateLimit", + newCertLimit, + numPlayers, + numCompanies); + DisplayBuffer.add(message); + ReportBuffer.add(message); + // Collect the old token spots, and move cash and trains List<BaseToken> homeTokens = new ArrayList<BaseToken>(); *************** *** 514,518 **** List<Bonus> bonuses = new ArrayList<Bonus> (comp.getBonuses()); for (Bonus bonus : bonuses) { ! cgr.addBonus(new Bonus(cgr, bonus.getName(), bonus.getValue(), bonus.getLocations())); comp.removeBonus(bonus); --- 538,542 ---- List<Bonus> bonuses = new ArrayList<Bonus> (comp.getBonuses()); for (Bonus bonus : bonuses) { ! cgr.addBonus(new Bonus(cgr, bonus.getName(), bonus.getValue(), bonus.getLocations())); comp.removeBonus(bonus); *************** *** 522,525 **** --- 546,550 ---- // Replace the home tokens + ReportBuffer.add(""); for (BaseToken token : homeTokens) { city = (City) token.getHolder(); *************** *** 590,593 **** --- 615,619 ---- int trainLimit = cgr.getTrainLimit(gameManager.getCurrentPlayerIndex()); List<TrainI> trains = cgr.getPortfolio().getTrainList(); + if (cgr.getNumberOfTrains() > trainLimit) ReportBuffer.add(""); outer: while (cgr.getNumberOfTrains() > trainLimit) { for (TrainI train : trains) { *************** *** 602,620 **** } - // Determine the new certificate limit. - // The number of available companies is 11, - // or 12 minus the number of closed companies, whichever is lower. - int numCompanies = Math.min(11, 12-mergingCompanies.size()); - int numPlayers = gameManager.getNumberOfPlayers(); - // Need some checks here... - int newCertLimit = certLimitsTable[numPlayers-3][numCompanies-4]; - gameManager.setPlayerCertificateLimit(newCertLimit); - message = LocalText.getText("CertificateLimit", - newCertLimit, - numPlayers, - numCompanies); - DisplayBuffer.add(message); - ReportBuffer.add(message); - } --- 628,631 ---- *************** *** 622,625 **** --- 633,637 ---- City city; MapHex hex; + ReportBuffer.add(""); for (BaseToken token : exchangedTokens) { // Remove old token Index: OperatingRound_1856.java =================================================================== RCS file: /cvsroot/rails/18xx/rails/game/specific/_1856/OperatingRound_1856.java,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** OperatingRound_1856.java 7 Oct 2009 18:56:22 -0000 1.24 --- OperatingRound_1856.java 27 Nov 2009 20:35:18 -0000 1.25 *************** *** 477,481 **** // Remove closed companies from the operating company list ! // (leave this code in case we need it; it works) //for (Iterator<PublicCompanyI> it = companies.iterator(); // it.hasNext(); ) { --- 477,481 ---- // Remove closed companies from the operating company list ! // (PLEASE leave this code in case we need it; it works) //for (Iterator<PublicCompanyI> it = companies.iterator(); // it.hasNext(); ) { *************** *** 515,518 **** --- 515,521 ---- message = LocalText.getText("DoesNotForm", cgr.getName()); } + ReportBuffer.add(LocalText.getText("EndOfFormationRound", + cgr.getName(), + getRoundName())); ReportBuffer.add (message); DisplayBuffer.add(message); |