Just a simple, and painful to use calculator for the game Factorio written in Python
修订版 | 6483f0e78fbeb103a2b9b68f41ca9ad777cf6628 (tree) |
---|---|
时间 | 2017-08-07 06:40:12 |
作者 | Eric Hopper <hopper@omni...> |
Commiter | Eric Hopper |
Stringifying an item just gives its name.
@@ -26,6 +26,9 @@ | ||
26 | 26 | return f'ProductionItem({self._name!r}, {self._time}, ' \ |
27 | 27 | f'{self._ingredients!r}, produced={self._produced})' |
28 | 28 | |
29 | + def __str__(self): | |
30 | + return self._name | |
31 | + | |
29 | 32 | @property |
30 | 33 | def base_rate(self): |
31 | 34 | if self._produced is None: |