Move the nethack templates into nethack/ subdirectories of partial and shortcodes
This commit is contained in:
parent
d1dfea9f97
commit
7f470262ec
4 changed files with 28 additions and 36 deletions
18
layouts/partials/nethack/logentry.html
Normal file
18
layouts/partials/nethack/logentry.html
Normal file
|
@ -0,0 +1,18 @@
|
|||
{{ $level := (cond (gt .dungeon.level.n 0) (.dungeon.level.descriptive | lower) .dungeon.level.descriptive) }}
|
||||
<div>{{ if .death.cause }}🪦{{ end }}</div>
|
||||
<h4 class="date">{{ time.Format "January 2, 2006" .end_date }}</h4>
|
||||
<div class="character-descriptor">{{ .character.abbreviated }}</div>
|
||||
<p>{{ .character.name }}, a {{ .character.alignment.descriptive | lower }} {{ .character.race.descriptive | lower }}
|
||||
{{ .character.gender.descriptive | lower }} {{ .character.role.descriptive }},
|
||||
died {{ if gt .death.count 1 }}for the last time{{ end }} in <span class="nobreak">{{ .dungeon.name }}</span>
|
||||
on <span class="nobreak">{{ $level }}</span>.
|
||||
She was {{ .death.cause }}.</p>
|
||||
<table class="stats">
|
||||
<tr>
|
||||
<td class="began">Began {{ time.Format "January 2, 2006" .start_date }}</td>
|
||||
<td class="score">{{ .score }} points</td>
|
||||
<td class="level">Level {{ .character.max_level }}</td>
|
||||
<td class="hp">{{ cond (gt .character.hp.n 0) (printf "%s / %s" .character.hp.n .character.hp.max)
|
||||
.character.hp.max }} hp</td>
|
||||
</tr>
|
||||
</table>
|
Loading…
Add table
Add a link
Reference in a new issue