From: Stefan F. (web.de) <ste...@we...> - 2010-05-14 16:03:59
|
Alex: that is one idea, which I use for the simple RevenueBonuses, which lay on a Hex or Tile. For the more complex cases I prefer a "push" approach to a "pull" approach: The objects that change reveneues have to register themselves as RevenueModifiers. Those are two Interfaces (static and a dynamic version) which have to be implemented by the objects that want to modify the revenue results. The major obstacle is my neglectable knowledge about Tokens and BonusTokens in Rails. Thus I do not want to change anything there close to the next release. Stefan > > My approach is to include "token" requirements to the bonus definition. > For example, for port token in 1856 I have an entry in bonus table (that > gives +20 to the city) with 2 requirements: (1) hex must contain port > token; (2) company must have port token. Tokens are transferred during the > private company sales and (when applicable) due to direct token sales. > > Alex. > > --------------------------------------------------------------------------- >--- > > _______________________________________________ > Rails-devel mailing list > Rai...@li... > https://lists.sourceforge.net/lists/listinfo/rails-devel |