💄 Support show character ranks in abyss floor data

This commit is contained in:
xtaodada 2024-12-21 14:46:09 +08:00
parent 5f3ac5bdf5
commit 492a02b8d2
Signed by: xtaodada
GPG Key ID: 4CBB3F4FA8C85659
2 changed files with 14 additions and 0 deletions

View File

@ -22,6 +22,13 @@
<div class="battle">
{% for character in node.avatars %}
<div class="character">
{% if character.rank > 0 %}
{% set constellation = character.rank %}
{% set bg = ['blue', 'blue', 'green', 'green', 'red', 'red'][constellation - 1] %}
<div style="background-color: var(--{{ bg }})">
{{ constellation }} 命
</div>
{% endif %}
<div class="element" style="background-image: url('../../img/attribute/{{ character.element_type }}.png')"></div>
<div class="icon"
style="background-image: url('../../background/rarity/half/{{ character.rarity }}.png')">

View File

@ -29,6 +29,13 @@
<div class="battle">
{% for character in data.floor.avatar_list %}
<div class="character">
{% if character.rank > 0 %}
{% set constellation = character.rank %}
{% set bg = ['blue', 'blue', 'green', 'green', 'red', 'red'][constellation - 1] %}
<div style="background-color: var(--{{ bg }})">
{{ constellation }} 命
</div>
{% endif %}
<div class="element" style="background-image: url('../../img/attribute/{{ character.element_type }}.png')"></div>
<div class="icon"
style="background-image: url('../../background/rarity/half/{{ character.rarity }}.png')">