From: Erik V. <eri...@hc...> - 2007-01-03 22:44:39
|
OK, I have implemented undo/redo for token lays along the lines that we have discussed. It seems to work. Much of the token laying code has been rewritten, and several new classes and interfaces have been added, including Token, TokenI and BaseToken. The MapHex method moveTokens has disappeared. The new code to move tokens from the old to the new tile is simpler, and now also handles simple 2-to-1 and 3-to-1 station mergers, like 1856 Toronto and 18EU Berlin/Vienna. However, the code is still not smart enough to correctly map old to new stations in 1830 OO-city upgrades. Erik. > -----Original Message----- > From: rai...@li... > [mailto:rai...@li...] On Behalf > Of brett lentz > Sent: Sunday 31 December 2006 20:59 > To: Development list for Rails: an 18xx game > Subject: Re: [Rails-devel] Available tokens > > It makes sense to me to make the object structure and interfaces as > consistent as possible across object types. > > It's also helpful to do this considering our JavaDoc needs > some work. ;-) > > I also agree that it'll probably help to have a generic Token class > when we implement Port tokens. > > ---Brett. > > On 12/31/06, Erik Vos <eri...@xs...> wrote: > > I'm currently pondering whether or not it is worthwhile > > to restructure the code to make token laying follow this pattern > > as well (each lay would then become a transfer of a Token object > > between two TokenHolder objects). > > > > While thinking about this I also keep in mind that different token > > types exist (e.g. port tokens occur in several games). > > It might be useful to have a generic Token class from which > > specific token types can be subclassed. > > (the existing Token class would then be renamed to GUIToken > or such). > > You'll be aware that I already fairly consistently refer to the > > usual tokens as BaseTokens. > > > > Erik. > > -------------------------------------------------------------- > ----------- > Take Surveys. Earn Cash. Influence the Future of IT > Join SourceForge.net's Techsay panel and you'll get the > chance to share your > opinions on IT & business topics through brief surveys - and earn cash > http://www.techsay.com/default.php?page=join.php&p=sourceforge > &CID=DEVDEV > _______________________________________________ > Rails-devel mailing list > Rai...@li... > https://lists.sourceforge.net/lists/listinfo/rails-devel > > |