summaryrefslogtreecommitdiff
path: root/views/village.twig
diff options
context:
space:
mode:
Diffstat (limited to 'views/village.twig')
-rw-r--r--views/village.twig16
1 files changed, 11 insertions, 5 deletions
diff --git a/views/village.twig b/views/village.twig
index d2b8a4e..97d65f7 100644
--- a/views/village.twig
+++ b/views/village.twig
@@ -84,7 +84,8 @@
</tr>
</thead>
<tbody>
- {% for event in events['UpgradeBuilding'] %}
+ {% for typeEvents in events['UpgradeBuilding'] %}
+ {% for event in typeEvents %}
<tr>
<td>{{ event.type }}</td>
<td class="timer">
@@ -97,6 +98,7 @@
</td>
</tr>
{% endfor %}
+ {% endfor %}
</tbody>
</table>
{% endif %}
@@ -190,21 +192,21 @@
<tr class="village__buildings__row">
<td>{{ building.type | default(type) }}</td>
<td>{{ building.level | default(0) }}</td>
- <td>{{ building.getBuildTime() | buildTime }}</td>
+ <td>{{ building.getBuildTimeForLevel(building.getEffectiveLevel() + 1) | buildTime }}</td>
<td class="resources">
<span>
<i class="icon icon-wood"></i>
- {{ building.getResourceRequirements()['wood'] }}
+ {{ building.getResourceRequirementsForLevel(building.getEffectiveLevel() + 1)['wood'] }}
</span>
&nbsp;
<span>
<i class="icon icon-clay"></i>
- {{ building.getResourceRequirements()['clay'] }}
+ {{ building.getResourceRequirementsForLevel(building.getEffectiveLevel() + 1)['clay'] }}
</span>
&nbsp;
<span>
<i class="icon icon-iron"></i>
- {{ building.getResourceRequirements()['iron'] }}
+ {{ building.getResourceRequirementsForLevel(building.getEffectiveLevel() + 1)['iron'] }}
</span>
</td>
<td>
@@ -235,6 +237,7 @@
<tr>
<td>{{ unit.type }}</td>
<td>{{ unit.amount }}</td>
+ {% if not unit.isTraveling %}
<td>
{{ unit.getBuildTime(1) | buildTime }}
</td>
@@ -265,6 +268,9 @@
<input type="submit" value="Train" {{ village.canTrain(village, unit, 1) ? '' : 'disabled' }}>
</form>
</td>
+ {% else %}
+ <td>~traveling~</td>
+ {% endif %}
</tr>
{% endfor %}
</tbody>