From: <ev...@us...> - 2010-09-06 17:39:53
|
Revision: 1412 http://rails.svn.sourceforge.net/rails/?rev=1412&view=rev Author: evos Date: 2010-09-06 17:39:47 +0000 (Mon, 06 Sep 2010) Log Message: ----------- Fix: closing company (1856) to transfer trains and cash Modified Paths: -------------- trunk/18xx/rails/game/PublicCompany.java Modified: trunk/18xx/rails/game/PublicCompany.java =================================================================== --- trunk/18xx/rails/game/PublicCompany.java 2010-08-28 18:52:52 UTC (rev 1411) +++ trunk/18xx/rails/game/PublicCompany.java 2010-09-06 17:39:47 UTC (rev 1412) @@ -1017,6 +1017,13 @@ } } + // Any trains go to the pool (from the 1856 rules) + Util.moveObjects(portfolio.getTrainList(), bank.getPool()); + + // Any cash goes to the bank (from the 1856 rules) + int cash = treasury.getCash(); + if (cash > 0) new CashMove (this, bank, cash); + lastRevenue.setOption(MoneyModel.SUPPRESS_ZERO); setLastRevenue(0); treasury.setOption(CashModel.SUPPRESS_ZERO); This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |