✨
This commit is contained in:
@@ -5,7 +5,8 @@
|
||||
"LevelShort": "LvL",
|
||||
"ExperienceShort": "EXP",
|
||||
"ArmorClass": "AC",
|
||||
"Speed": "Speed"
|
||||
"Speed": "Speed",
|
||||
"Attack": "Attack"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -416,4 +416,18 @@
|
||||
top: 186px;
|
||||
border-top-left-radius: 101px 60px;
|
||||
}
|
||||
|
||||
.statsBox {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
justify-items: space-evenly;
|
||||
}
|
||||
|
||||
.categorySelectBox {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
justify-items: space-evenly;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -63,11 +63,20 @@ export default class pokemonCharacterSheet extends api.HandlebarsApplicationMixi
|
||||
effects: baseData.document.effects
|
||||
};
|
||||
|
||||
context = this.calculateDerivated(context)
|
||||
|
||||
this.sheetContext = context;
|
||||
|
||||
return context;
|
||||
}
|
||||
|
||||
calculateDerivated(context) {
|
||||
context.system.armorClass = 10+context.system.stats.defense
|
||||
context.system.speed = 30+5*context.system.stats.speed
|
||||
|
||||
return context
|
||||
}
|
||||
|
||||
/** @override */
|
||||
_onRender(context, options) {
|
||||
|
||||
|
||||
12
pokemon.css
12
pokemon.css
@@ -349,3 +349,15 @@
|
||||
top: 186px;
|
||||
border-top-left-radius: 101px 60px;
|
||||
}
|
||||
.pokemon.sheet.characterSheet .statsBox {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
justify-items: space-evenly;
|
||||
}
|
||||
.pokemon.sheet.characterSheet .categorySelectBox {
|
||||
display: flex;
|
||||
flex-direction: column;
|
||||
align-items: flex-start;
|
||||
justify-items: space-evenly;
|
||||
}
|
||||
|
||||
BIN
system.zip
BIN
system.zip
Binary file not shown.
@@ -17,9 +17,11 @@
|
||||
"stats": {
|
||||
"attack": 0,
|
||||
"defense": 0,
|
||||
"move": 0,
|
||||
"speed": 0,
|
||||
"hp": 0
|
||||
},
|
||||
"attackCategory": 0,
|
||||
"defenseCategory": 0,
|
||||
"speed": 0,
|
||||
"hp": {
|
||||
"max": 0,
|
||||
|
||||
@@ -1,2 +1,26 @@
|
||||
<div class="charSheetBox">
|
||||
<div class="statsBox">
|
||||
<div class="row">
|
||||
<div class="charHex"><span class="charHexHead">Attack</span></br><input class="charHexValue invisibleInput" type="number" name="system.stats.attack" value="{{system.stats.attack}}"></div>
|
||||
<div class="categorySelectBox">
|
||||
<select name="system.attackCategory">
|
||||
<option value=0>Physical</option>
|
||||
<option value=1>Special</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="charHex"><span class="charHexHead">Defense</span></br><input class="charHexValue invisibleInput" type="number" name="system.stats.defense" value="{{system.stats.defense}}"></div>
|
||||
<div class="categorySelectBox">
|
||||
<select name="system.defenseCategory">
|
||||
<option value=0>Physical</option>
|
||||
<option value=1>Special</option>
|
||||
</select>
|
||||
</div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="charHex"><span class="charHexHead">Speed</span></br><input class="charHexValue invisibleInput" type="number" name="system.stats.speed" value="{{system.stats.speed}}"></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="charHex"><span class="charHexHead">HP</span></br><input class="charHexValue invisibleInput" type="number" name="system.stats.hp" value="{{system.stats.hp}}"></div>
|
||||
</div>
|
||||
</div>
|
||||
@@ -17,7 +17,7 @@
|
||||
<div class="calcStatBox">
|
||||
<div class="hitPointBox">
|
||||
<div class="charHex charHPCurrent"><span class="charHexHead">HP</span></br><input class="charHexValue hpValue invisibleInput" type="number" name="system.hp.current" value="{{system.hp.current}}"></div>
|
||||
<div class="charHex charHPMax"><span class="charHexHead">Max</span></br><span class="charHexValue hpMaxValue">{{system.hp.max}}</span></div>
|
||||
<div class="charHex charHPMax"><span class="charHexHead">Max</span></br><input class="charHexValue hpMaxValue invisibleinput" type="number" name="system.hp.max" value="{{system.hp.max}}"></div>
|
||||
</div>
|
||||
<div class="row">
|
||||
<div class="charHex"><span class="charHexHead">{{localize "POKEMON.System.ArmorClass"}}</span></br><span class="charHexValue">{{system.armorClass}}</span></div>
|
||||
|
||||
Reference in New Issue
Block a user