mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-01-15 05:01:08 +01:00
add death roll in character sheet
This commit is contained in:
parent
c6cede40b2
commit
566ffa4c6e
3 changed files with 34 additions and 4 deletions
|
|
@ -605,7 +605,6 @@ export default class CharacterSheet extends DaggerheartSheet(ActorSheetV2) {
|
||||||
static async makeDeathMove() {
|
static async makeDeathMove() {
|
||||||
if (this.document.system.resources.hitPoints.value === this.document.system.resources.hitPoints.max) {
|
if (this.document.system.resources.hitPoints.value === this.document.system.resources.hitPoints.max) {
|
||||||
await new DhpDeathMove(this.document).render(true);
|
await new DhpDeathMove(this.document).render(true);
|
||||||
await this.minimize();
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -12,12 +12,39 @@
|
||||||
background: transparent;
|
background: transparent;
|
||||||
}
|
}
|
||||||
|
|
||||||
img {
|
.portrait {
|
||||||
|
position: relative;
|
||||||
height: 235px;
|
height: 235px;
|
||||||
width: 275px;
|
width: 275px;
|
||||||
border-bottom: 1px solid light-dark(@dark-blue, @golden);
|
border-bottom: 1px solid light-dark(@dark-blue, @golden);
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
object-fit: cover;
|
|
||||||
|
img {
|
||||||
|
height: 235px;
|
||||||
|
width: 275px;
|
||||||
|
object-fit: cover;
|
||||||
|
}
|
||||||
|
|
||||||
|
.death-roll-btn {
|
||||||
|
display: none;
|
||||||
|
}
|
||||||
|
|
||||||
|
&.death-roll {
|
||||||
|
filter: grayscale(1);
|
||||||
|
|
||||||
|
.death-roll-btn {
|
||||||
|
display: flex;
|
||||||
|
position: absolute;
|
||||||
|
top: 30%;
|
||||||
|
right: 30%;
|
||||||
|
font-size: 6rem;
|
||||||
|
color: @beige;
|
||||||
|
|
||||||
|
&:hover {
|
||||||
|
text-shadow: 0 0 8px @beige;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
.info-section {
|
.info-section {
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,9 @@
|
||||||
<aside class="character-sidebar-sheet">
|
<aside class="character-sidebar-sheet">
|
||||||
<img class="portrait" src="{{document.img}}" alt="{{document.name}}" data-action='editImage' data-edit="img">
|
<div class="portrait {{#if (gte document.system.resources.hitPoints.value document.system.resources.hitPoints.maxTotal)}}death-roll{{/if}}">
|
||||||
|
<img src="{{document.img}}" alt="{{document.name}}" data-action='editImage' data-edit="img">
|
||||||
|
<a class="death-roll-btn" data-tooltip="{{localize "DAGGERHEART.Sheets.PC.Health.DeathMoveTooltip"}}" data-action="makeDeathMove"><i class="fas fa-skull death-save" ></i></a>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div class="info-section">
|
<div class="info-section">
|
||||||
<div class="resources-section">
|
<div class="resources-section">
|
||||||
<div class="status-bar">
|
<div class="status-bar">
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue