Mercurial > eagle-eye
comparison pyikriam/example.py @ 188:bf4ddf5bffb9
Extracts information about resources required to upgrade a building.
author | Thinker K.F. Li <thinker@branda.to> |
---|---|
date | Sun, 02 Nov 2008 22:31:06 +0800 |
parents | 6adad3bcca78 |
children |
comparison
equal
deleted
inserted
replaced
178:bff16e6ee3ef | 188:bf4ddf5bffb9 |
---|---|
20 print 'wood is ' + city.wood | 20 print 'wood is ' + city.wood |
21 print 'wine is ' + city.wine | 21 print 'wine is ' + city.wine |
22 print 'marble is ' + city.marble | 22 print 'marble is ' + city.marble |
23 print 'crystal is ' + city.crystal | 23 print 'crystal is ' + city.crystal |
24 print 'sulfur is ' + city.sulfur | 24 print 'sulfur is ' + city.sulfur |
25 print 'positions ' + repr(city.positions) | |
26 | 25 |
27 for idx, pos in enumerate(city.positions): | 26 for idx, pos in enumerate(city.positions): |
28 if not isinstance(pos, buildings.position): | 27 if not isinstance(pos, buildings.position): |
29 continue | 28 continue |
30 pos.sync() | 29 pos.sync() |