BattleSim/client/views/battle_pokemon.jade

20 lines
814 B
Plaintext
Raw Normal View History

2016-02-01 22:19:30 +00:00
- var percent = pokemon.getPercentHP()
- var color = ((percent <= 25) ? "#f00" : (percent <= 50) ? "#ff0" : "#0f0")
- var style = "width: " + percent + "%"
- var greenStyle = style + "; background-color: " + color
a.sprite.preload(href=pokemon.getPokedexUrl(), target='_blank', data-species = pokemon.get('species'), data-forme = pokemon.get('forme'), data-shiny = (pokemon.get('shiny') ? "true" : "false"))
.pokemon-info
span.pokemon-meta
span.pokemon-name= pokemon.get('name')
if pokemon.get('gender') === 'F'
span.gender.gender_female &#9792;
else if pokemon.get('gender') === 'M'
span.gender.gender_male &#9794;
2016-02-19 23:54:42 +00:00
span.pokemon-level
span.pokemon-level-text Lv.
= pokemon.get('level')
2016-02-01 22:19:30 +00:00
.hp-text #{percent}%
.hp(style = greenStyle)
.hp-gradient
.pokemon-effects