From: Erik V. <eri...@xs...> - 2010-01-19 21:23:26
|
OK. I just found a test case and for me works fine now. I hope it does for you. Erik. -----Original Message----- From: Phil Davies [mailto:de...@gm...] Sent: Monday 18 January 2010 23:56 To: Development list for Rails: an 18xx game Subject: Re: [Rails-devel] 18EU: incorrect player set to start MinorCompanyexchange round When we ran it through Phil (Me :)) got the first turn in the FME round because the 12 minor bought a new train in OR2. Assuming no one buys a train in the 2nd OR it probably goes to the first player by the sounds of it. Phil 2010/1/18 Erik Vos <eri...@xs...>: > Hmm yes - I think you're right, although when I tried > to continue your game, everything went allright: > Chris who had bought the first 5-train did get the > first turn in the Final Exchange round. But perhaps > that was because he's the first player. > > Anyway, you're right that items that are supposed to survive > operating rounds should not be OR instance objects. > > Making it static would do for now, but indeed is not > according our design principles (which are looking forward > to a potential future multi-game server). > > In stead, such items should be stored in the GameManager > object, which survives all rounds. And that is where this item > is used too! I will change accordingly. > > Erik. > > > -----Original Message----- > From: Phil Davies [mailto:de...@gm...] > Sent: Monday 18 January 2010 12:25 > To: Development list for Rails: an 18xx game > Subject: [Rails-devel] 18EU: incorrect player set to start Minor > Companyexchange round > > There is a case where the player to start the Final Company exchange > round can become set incorrectly. > > As far as I can tell, it's because the PlayerToStartExchangeRound > object is declared in OperatingRound_18EU. If the first 5 train > purchase occurs in OR1 of the round, this is not correctly carried > over into OR2. > > I have a saved game here: > http://dl.dropbox.com/u/218527/18EU_20100113_2014.rails where the > first 5 is about to be bought in the first OR. You can see it sets > the PlayerToStartExchangeRound correctly but when OR 2 starts it > creates a new PlayerToStartExchangeRound object for that OR. > > Please forgive my slightly wonky Java abilities, but is this just a > case of changing: > > protected State playerToStartExchangeRound > > into > > protected static State playerToStartExchangeRound > > So that it is present for the class rather than each instance? This > seems to work trying it locally but I'm unsure if this has an impact > on the overall design...should the variable access methods be changed > to reference the OperatingRound class rather than the > playerToStartExchangeRound variable directly? Or is that unnecessary? > > > Phil > > ---------------------------------------------------------------------------- > -- > Throughout its 18-year history, RSA Conference consistently attracts the > world's best and brightest in the field, creating opportunities for > Conference > attendees to learn about information security's most important issues > through > interactions with peers, luminaries and emerging and established companies. > http://p.sf.net/sfu/rsaconf-dev2dev > _______________________________________________ > Rails-devel mailing list > Rai...@li... > https://lists.sourceforge.net/lists/listinfo/rails-devel > > > ---------------------------------------------------------------------------- -- > Throughout its 18-year history, RSA Conference consistently attracts the > world's best and brightest in the field, creating opportunities for Conference > attendees to learn about information security's most important issues through > interactions with peers, luminaries and emerging and established companies. > http://p.sf.net/sfu/rsaconf-dev2dev > _______________________________________________ > Rails-devel mailing list > Rai...@li... > https://lists.sourceforge.net/lists/listinfo/rails-devel > ---------------------------------------------------------------------------- -- Throughout its 18-year history, RSA Conference consistently attracts the world's best and brightest in the field, creating opportunities for Conference attendees to learn about information security's most important issues through interactions with peers, luminaries and emerging and established companies. http://p.sf.net/sfu/rsaconf-dev2dev _______________________________________________ Rails-devel mailing list Rai...@li... https://lists.sourceforge.net/lists/listinfo/rails-devel |