Compare commits
2 Commits
fvtt-warhe
...
fvtt-warhe
| Author | SHA1 | Date | |
|---|---|---|---|
| 7137de0983 | |||
| 46b129cf81 |
12
lang/en.json
12
lang/en.json
@@ -44,6 +44,9 @@
|
||||
"WH.ui.Strength": "Strength",
|
||||
"WH.ui.Instinct": "Instinct",
|
||||
"WH.ui.Dexterity": "Dexterity",
|
||||
"WH.ui.savestr": "Str Save",
|
||||
"WH.ui.savedex": "Dex Save",
|
||||
"WH.ui.savemin": "Mind Save",
|
||||
"WH.ui.Mind": "Mind",
|
||||
"WH.ui.Type": "Type",
|
||||
"WH.ui.HitPoints": "Hit Points",
|
||||
@@ -113,7 +116,10 @@
|
||||
"WH.ui.quantity": "Quantity",
|
||||
"WH.ui.cost": "Cost",
|
||||
"WH.ui.details": "Details",
|
||||
|
||||
"WH.ui.magicschool": "Magic School",
|
||||
"WH.ui.providedslot": "Provided slot",
|
||||
"WH.ui.skilllevelacquired": "Acquired at level",
|
||||
|
||||
"WH.chat.save": "Save",
|
||||
"WH.chat.mweaponmalus": "Multiple weapons malus ",
|
||||
"WH.chat.diceresult": "Dice result",
|
||||
@@ -123,5 +129,7 @@
|
||||
"WH.chat.rollformula": "Roll Formula",
|
||||
"WH.chat.useshield":"Use shield ?",
|
||||
"WH.chat.power": "Power",
|
||||
"WH.chat.powerlevel": "Power Level"
|
||||
"WH.chat.powerlevel": "Power Level",
|
||||
|
||||
"WH.notif.skillmaxuse": "Maximum skill usage reach - Use is not allowed"
|
||||
}
|
||||
@@ -99,7 +99,8 @@ export class WarheroActorSheet extends ActorSheet {
|
||||
})
|
||||
html.find('.item-add').click(ev => {
|
||||
let dataType = $(ev.currentTarget).data("type")
|
||||
this.actor.createEmbeddedDocuments('Item', [{ name: "NewItem", type: dataType }], { renderSheet: true })
|
||||
let slotKey = $(ev.currentTarget).data("slot")
|
||||
this.actor.createEmbeddedDocuments('Item', [{ name: "NewItem", type: dataType, system: { slotlocation: slotKey} }], { renderSheet: true })
|
||||
})
|
||||
|
||||
html.find('.equip-activate').click(ev => {
|
||||
@@ -133,6 +134,15 @@ export class WarheroActorSheet extends ActorSheet {
|
||||
const li = $(event.currentTarget).parents(".item");
|
||||
this.actor.incDecQuantity( li.data("item-id"), +1 );
|
||||
} );
|
||||
html.find('.skill-use-minus').click(event => {
|
||||
const li = $(event.currentTarget).parents(".item");
|
||||
this.actor.incDecSkillUse( li.data("item-id"), -1 );
|
||||
} );
|
||||
html.find('.skill-use-plus').click(event => {
|
||||
const li = $(event.currentTarget).parents(".item");
|
||||
this.actor.incDecSkillUse( li.data("item-id"), +1 );
|
||||
} );
|
||||
|
||||
|
||||
html.find('.ammo-minus').click(event => {
|
||||
const li = $(event.currentTarget).parents(".item")
|
||||
|
||||
@@ -135,7 +135,7 @@ export class WarheroActor extends Actor {
|
||||
}
|
||||
sortPowers() {
|
||||
let schools = {}
|
||||
for(let power of this.items) {
|
||||
for (let power of this.items) {
|
||||
if (power.type == "power") {
|
||||
power = duplicate(power)
|
||||
let school = schools[power.system.magicschool] || []
|
||||
@@ -176,14 +176,16 @@ export class WarheroActor extends Actor {
|
||||
/* -------------------------------------------- */
|
||||
buildEquipmentsSlot() {
|
||||
let containers = {}
|
||||
for(let slotName in game.system.warhero.config.slotNames) {
|
||||
for (let slotName in game.system.warhero.config.slotNames) {
|
||||
let slotDef = game.system.warhero.config.slotNames[slotName]
|
||||
containers[slotName] = duplicate(slotDef)
|
||||
containers[slotName].content = this.items.filter(it => (it.type == 'weapon' || it.type == 'armor' || it.type == 'shield'||it.type == 'equipment')
|
||||
&& it.system.slotlocation == slotName )
|
||||
containers[slotName].content = this.items.filter(it => (it.type == 'weapon' || it.type == 'armor' || it.type == 'shield' || it.type == 'equipment')
|
||||
&& it.system.slotlocation == slotName)
|
||||
let slotUsed = 0
|
||||
for(let item of containers[slotName].content) {
|
||||
slotUsed += item.system.slotused * ((item.system.quantity) ? item.system.quantity : 1)
|
||||
for (let item of containers[slotName].content) {
|
||||
let q = (item.system.quantity) ? item.system.quantity : 1
|
||||
containers[slotName].nbslots += (item.system.providedslot?? 0) * q
|
||||
slotUsed += item.system.slotused * q
|
||||
}
|
||||
slotUsed = Math.ceil(slotUsed)
|
||||
containers[slotName].slotUsed = slotUsed
|
||||
@@ -203,11 +205,11 @@ export class WarheroActor extends Actor {
|
||||
formula += "+" + this.system.statistics.str.value
|
||||
}
|
||||
if (weapon.system.weapontype == "twohanded") {
|
||||
formula += "+" + Math.floor(this.system.statistics.str.value*1.5)
|
||||
formula += "+" + Math.floor(this.system.statistics.str.value * 1.5)
|
||||
}
|
||||
if (weapon.system.weapontype == "polearm") {
|
||||
formula += "+" + Math.floor(this.system.statistics.str.value*1)
|
||||
weapon.damageFormula2Hands = weapon.system.damage2hands + "+" + Math.floor(this.system.statistics.str.value*1.5)
|
||||
formula += "+" + Math.floor(this.system.statistics.str.value * 1)
|
||||
weapon.damageFormula2Hands = weapon.system.damage2hands + "+" + Math.floor(this.system.statistics.str.value * 1.5)
|
||||
}
|
||||
weapon.damageFormula = formula
|
||||
}
|
||||
@@ -382,7 +384,7 @@ export class WarheroActor extends Actor {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async incDecHP(formula) {
|
||||
let dmgRoll = new Roll(formula+"[warhero-orange]").roll({ async: false })
|
||||
let dmgRoll = new Roll(formula + "[warhero-orange]").roll({ async: false })
|
||||
await WarheroUtility.showDiceSoNice(dmgRoll, game.settings.get("core", "rollMode"))
|
||||
let hp = duplicate(this.system.secondary.hp)
|
||||
hp.value = Number(hp.value) + Number(dmgRoll.total)
|
||||
@@ -391,7 +393,7 @@ export class WarheroActor extends Actor {
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
updateCompetency(competency, obj, labelTab) {
|
||||
for(let key in obj) {
|
||||
for (let key in obj) {
|
||||
if (obj[key]) {
|
||||
//console.log("Parsing", key) //game.system.warhero.config.weaponTypes[key].label)
|
||||
competency[key] = { enabled: true, label: labelTab[key].label }
|
||||
@@ -401,11 +403,13 @@ export class WarheroActor extends Actor {
|
||||
getCompetency() {
|
||||
let myRace = this.getRace()
|
||||
let myClass = this.getClass()
|
||||
let competency = { weapons: {}, armors: {}, shields: {}}
|
||||
if ( myRace.system && myClass.system) {
|
||||
let competency = { weapons: {}, armors: {}, shields: {} }
|
||||
if (myRace.system) {
|
||||
this.updateCompetency(competency.weapons, myRace.system.weapons, game.system.warhero.config.weaponTypes)
|
||||
this.updateCompetency(competency.armors, myRace.system.armors, game.system.warhero.config.armorTypes)
|
||||
this.updateCompetency(competency.shields, myRace.system.shields, game.system.warhero.config.shieldTypes)
|
||||
}
|
||||
if (myClass.system) {
|
||||
this.updateCompetency(competency.weapons, myClass.system.weapons, game.system.warhero.config.weaponTypes)
|
||||
this.updateCompetency(competency.armors, myClass.system.armors, game.system.warhero.config.armorTypes)
|
||||
this.updateCompetency(competency.shields, myClass.system.shields, game.system.warhero.config.shieldTypes)
|
||||
@@ -457,12 +461,10 @@ export class WarheroActor extends Actor {
|
||||
}
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
getInitiativeScore(combatId, combatantId) {
|
||||
if (this.type == 'character') {
|
||||
this.rollMR(true, combatId, combatantId)
|
||||
}
|
||||
console.log("Init required !!!!")
|
||||
return -1;
|
||||
async getInitiativeScore(combatId, combatantId) {
|
||||
let roll = new Roll("1d20+"+this.system.attributes.ini.value).roll({async: false})
|
||||
await WarheroUtility.showDiceSoNice(roll, game.settings.get("core", "rollMode"))
|
||||
return roll.total
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
@@ -543,7 +545,19 @@ export class WarheroActor extends Actor {
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async incDecSkillUse(skillId, value) {
|
||||
let skill = this.items.get(skillId)
|
||||
if (skill) {
|
||||
let newUse = skill.system.currentuse + value
|
||||
if (newUse > skill.system.maxuse) {
|
||||
ui.notifications.warn(game.i18n.localize("WH.notif.skillmaxuse"))
|
||||
return
|
||||
}
|
||||
newUse = Math.max(newUse, 0)
|
||||
this.updateEmbeddedDocuments('Item', [{ _id: skill.id, 'system.currentuse': newUse }])
|
||||
}
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
async incDecQuantity(objetId, incDec = 0) {
|
||||
let objetQ = this.items.get(objetId)
|
||||
@@ -596,7 +610,7 @@ export class WarheroActor extends Actor {
|
||||
/* -------------------------------------------- */
|
||||
setLevel() {
|
||||
let xp = this.system.secondary.xp.value
|
||||
this.system.secondary.xp.level = 1 + Math.floor(xp/10)
|
||||
this.system.secondary.xp.level = 1 + Math.floor(xp / 10)
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
computeDRTotal() {
|
||||
@@ -605,7 +619,7 @@ export class WarheroActor extends Actor {
|
||||
for (let armor of armors) {
|
||||
dr += armor.system.damagereduction
|
||||
}
|
||||
this.system.secondary.drbonustotal.value = this.system.secondary.drbonus.value + dr
|
||||
this.system.secondary.drbonustotal.value = this.system.secondary.drbonus.value + dr
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
computeParryBonusTotal() {
|
||||
@@ -614,21 +628,23 @@ export class WarheroActor extends Actor {
|
||||
for (let shield of shields) {
|
||||
parry += shield.system.parrybonus
|
||||
}
|
||||
this.system.secondary.parrybonustotal.value = this.system.secondary.parrybonus.value + parry
|
||||
this.system.secondary.parrybonustotal.value = this.system.secondary.parrybonus.value + parry
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
computeBonusLanguages() {
|
||||
this.system.secondary.nblanguage.value = Math.floor(this.system.statistics.min.value / 2)
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
spentMana( mana) {
|
||||
if ( Number(mana) > this.system.attributes.mana.value) {
|
||||
spentMana(spentValue) {
|
||||
let mana = duplicate(this.system.attributes.mana)
|
||||
if (Number(spentValue) > mana.value) {
|
||||
ui.notifications.warn("Not enough Mana points !")
|
||||
return false
|
||||
}
|
||||
this.update({'system.attributes.mana.value': this.system.attributes.mana.value-mana})
|
||||
mana.value -= Number(spentValue)
|
||||
this.update({ 'system.attributes.mana': mana })
|
||||
return true
|
||||
}
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
getCommonRollData() {
|
||||
let rollData = WarheroUtility.getBasicRollData()
|
||||
@@ -647,7 +663,11 @@ export class WarheroActor extends Actor {
|
||||
let rollData = this.getCommonRollData()
|
||||
rollData.mode = rollType
|
||||
rollData.stat = stat
|
||||
if ( rollKey == "parrybonustotal") {
|
||||
if (stat && stat.stat)
|
||||
{
|
||||
rollData.statBonus = duplicate(this.system.statistics[stat.stat])
|
||||
}
|
||||
if (rollKey == "parrybonustotal") {
|
||||
WarheroUtility.rollParry(rollData)
|
||||
return
|
||||
}
|
||||
@@ -661,7 +681,7 @@ export class WarheroActor extends Actor {
|
||||
rollData.stat = stat
|
||||
this.startRoll(rollData)
|
||||
}
|
||||
|
||||
|
||||
/* -------------------------------------------- */
|
||||
rollWeapon(weaponId) {
|
||||
let weapon = this.items.get(weaponId)
|
||||
@@ -669,12 +689,12 @@ export class WarheroActor extends Actor {
|
||||
weapon = duplicate(weapon)
|
||||
let rollData = this.getCommonRollData()
|
||||
rollData.mode = "weapon"
|
||||
if (weapon.system.weapontype ==="shooting" || weapon.system.weapontype ==="throwing") {
|
||||
if (weapon.system.weapontype === "shooting" || weapon.system.weapontype === "throwing") {
|
||||
rollData.stat = duplicate(this.system.attributes.txcr)
|
||||
} else {
|
||||
rollData.stat = duplicate(this.system.attributes.txcm)
|
||||
}
|
||||
rollData.usemWeaponMalus =
|
||||
rollData.usemWeaponMalus = false
|
||||
rollData.mWeaponMalus = this.system.secondary.malusmultiweapon.value
|
||||
rollData.weapon = weapon
|
||||
rollData.img = weapon.img
|
||||
@@ -703,13 +723,13 @@ export class WarheroActor extends Actor {
|
||||
let rollData = this.getCommonRollData()
|
||||
rollData.mode = "power"
|
||||
rollData.power = power
|
||||
rollData.powerLevel = power.system.level
|
||||
rollData.powerLevel = Number(power.system.level)
|
||||
rollData.img = power.img
|
||||
rollData.hasBM = false
|
||||
this.startRoll(rollData)
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async startRoll(rollData) {
|
||||
this.syncRoll(rollData)
|
||||
|
||||
@@ -9,7 +9,7 @@ export class WarheroCombat extends Combat {
|
||||
for (let cId = 0; cId < ids.length; cId++) {
|
||||
const c = this.combatants.get(ids[cId]);
|
||||
let id = c._id || c.id;
|
||||
let initBonus = c.actor ? c.actor.getInitiativeScore( this.id, id ) : -1;
|
||||
let initBonus = c.actor ? await c.actor.getInitiativeScore( this.id, id ) : -1;
|
||||
await this.updateEmbeddedDocuments("Combatant", [ { _id: id, initiative: initBonus } ]);
|
||||
}
|
||||
|
||||
|
||||
@@ -69,12 +69,6 @@ export class WarheroItemSheet extends ItemSheet {
|
||||
owner: this.document.isOwner,
|
||||
isGM: game.user.isGM
|
||||
}
|
||||
if ( this.object.type == "power") {
|
||||
formData.level1 = await TextEditor.enrichHTML(this.object.system.level1, {async: true})
|
||||
formData.level2 = await TextEditor.enrichHTML(this.object.system.level2, {async: true})
|
||||
formData.level3 = await TextEditor.enrichHTML(this.object.system.level3, {async: true})
|
||||
formData.level4 = await TextEditor.enrichHTML(this.object.system.level4, {async: true})
|
||||
}
|
||||
this.options.editable = !(this.object.origin == "embeddedItem");
|
||||
console.log("ITEM DATA", formData, this);
|
||||
return formData;
|
||||
@@ -130,11 +124,6 @@ export class WarheroItemSheet extends ItemSheet {
|
||||
const item = this.object.options.actor.getOwnedItem(li.data("item-id"));
|
||||
item.sheet.render(true);
|
||||
});
|
||||
|
||||
html.find('.delete-spec').click(ev => {
|
||||
this.object.update({ "data.specialisation": [{ name: 'None' }] });
|
||||
});
|
||||
|
||||
html.find('.delete-subitem').click(ev => {
|
||||
this.deleteSubitem(ev);
|
||||
});
|
||||
@@ -145,15 +134,6 @@ export class WarheroItemSheet extends ItemSheet {
|
||||
let itemId = li.data("item-id");
|
||||
let itemType = li.data("item-type");
|
||||
});
|
||||
|
||||
html.find('.view-subitem').click(ev => {
|
||||
this.viewSubitem(ev);
|
||||
});
|
||||
|
||||
html.find('.view-spec').click(ev => {
|
||||
this.manageSpec();
|
||||
});
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
@@ -11,6 +11,7 @@ export const defaultItemImg = {
|
||||
money: "systems/fvtt-warhero/images/icons/two-coins.svg",
|
||||
power: "systems/fvtt-warhero/images/icons/magia.webp",
|
||||
condition: "systems/fvtt-warhero/images/icons/stordenti.webp",
|
||||
language: "systems/fvtt-warhero/images/icons/linguaggi.webp"
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -71,16 +71,6 @@ Hooks.once("init", async function () {
|
||||
WarheroUtility.init()
|
||||
});
|
||||
|
||||
/* -------------------------------------------- */
|
||||
function welcomeMessage() {
|
||||
ChatMessage.create({
|
||||
user: game.user.id,
|
||||
whisper: [game.user.id],
|
||||
content: `<div id="welcome-message-crucible"><span class="rdd-roll-part">
|
||||
<strong>Welcome to the Warhero RPG.</strong>
|
||||
` });
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
/* Foundry VTT Initialization */
|
||||
/* -------------------------------------------- */
|
||||
@@ -96,15 +86,14 @@ Hooks.once("ready", function () {
|
||||
}
|
||||
|
||||
// CSS patch for v9
|
||||
if (game.version) {
|
||||
/*if (game.version) {
|
||||
let sidebar = document.getElementById("sidebar");
|
||||
sidebar.style.width = "min-content";
|
||||
}
|
||||
}*/
|
||||
|
||||
welcomeMessage();
|
||||
//welcomeMessage();
|
||||
WarheroUtility.ready()
|
||||
WarheroCommands.init()
|
||||
WarheroHotbar.initDropbar()
|
||||
//WarheroHotbar.initDropbar()
|
||||
|
||||
})
|
||||
|
||||
|
||||
@@ -19,7 +19,16 @@ export class WarheroUtility {
|
||||
this.defenderStore = {}
|
||||
|
||||
WarheroCommands.init();
|
||||
|
||||
|
||||
Handlebars.registerHelper('concat', function () {
|
||||
var outStr = '';
|
||||
for (var arg in arguments) {
|
||||
if (typeof arguments[arg] != 'object') {
|
||||
outStr += arguments[arg];
|
||||
}
|
||||
}
|
||||
return outStr;
|
||||
});
|
||||
Handlebars.registerHelper('count', function (list) {
|
||||
return list.length;
|
||||
})
|
||||
@@ -543,7 +552,7 @@ export class WarheroUtility {
|
||||
let actor = game.actors.get(rollData.actorId)
|
||||
|
||||
if (rollData.mode == "power") {
|
||||
let manaCost = Array.from(rollData.powerLevel)[0]
|
||||
let manaCost = rollData.powerLevel
|
||||
if (actor.spentMana(manaCost)) {
|
||||
let powerKey = "level" + rollData.powerLevel
|
||||
rollData.powerText = rollData.power.system[powerKey]
|
||||
@@ -575,7 +584,7 @@ export class WarheroUtility {
|
||||
}
|
||||
|
||||
let diceFormula
|
||||
if (rollData.weapon.system.weapontype == "special") {
|
||||
if (rollData.weapon && rollData.weapon.system.weapontype == "special") {
|
||||
diceFormula = rollData.weapon.system.rollformula
|
||||
} else {
|
||||
// ability/save/size => 0
|
||||
@@ -583,6 +592,9 @@ export class WarheroUtility {
|
||||
if (rollData.stat) {
|
||||
diceFormula += "+" + rollData.stat.value
|
||||
}
|
||||
if (rollData.statBonus) {
|
||||
diceFormula += "+" + rollData.statBonus.value
|
||||
}
|
||||
}
|
||||
if (rollData.usemWeaponMalus) {
|
||||
diceFormula += "+" + rollData.mWeaponMalus
|
||||
|
||||
@@ -876,16 +876,36 @@ li {
|
||||
|
||||
/* background: rgb(105,85,65) url("../images/ui/texture_feuille_perso_onglets.webp") no-repeat right bottom;*/
|
||||
|
||||
#sidebar.collapsed {
|
||||
height: 470px !important;
|
||||
}
|
||||
|
||||
#sidebar-tabs > .collapsed,
|
||||
#chat-controls .chat-control-icon {
|
||||
color: rgba(220, 220, 220, 0.75);
|
||||
text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.75);
|
||||
}
|
||||
|
||||
#sidebar-tabs {
|
||||
flex: 0 0 28px;
|
||||
box-sizing: border-box;
|
||||
margin: 0 0 3px;
|
||||
border-bottom: 1px solid rgba(0,0,0,0);
|
||||
box-shadow: inset 0 0 2rem rgba(0,0,0,0.5);
|
||||
}
|
||||
|
||||
#sidebar-tabs > .item.active {
|
||||
border: 1px solid rgba(114,98,72,1);
|
||||
background: rgba(30, 25, 20, 0.75);
|
||||
box-shadow: 0 0 6px inset rgba(114,98,72,1);
|
||||
}
|
||||
|
||||
#sidebar #sidebar-tabs i{
|
||||
width: 23px;
|
||||
height: 23px;
|
||||
display: inline-block;
|
||||
background-position:center;
|
||||
background-size:cover;
|
||||
text-shadow: 1px 1px 0 rgba(0,0,0,0.75);
|
||||
|
||||
}
|
||||
|
||||
.sidebar-tab .directory-list .entity {
|
||||
border-top: 1px dashed rgba(0, 0, 0, 0.25);
|
||||
border-bottom: 0 none;
|
||||
@@ -1028,21 +1048,6 @@ li {
|
||||
box-shadow: inset 0 0 2rem rgba(0, 0, 0, 0.5);
|
||||
}
|
||||
|
||||
#sidebar-tabs > .item.active {
|
||||
border: 1px solid rgba(114, 98, 72, 1);
|
||||
background: rgba(30, 25, 20, 0.75);
|
||||
box-shadow: 0 0 6px inset rgba(114, 98, 72, 1);
|
||||
}
|
||||
|
||||
#sidebar #sidebar-tabs i {
|
||||
width: 25px;
|
||||
height: 25px;
|
||||
display: inline-block;
|
||||
background-position: center;
|
||||
background-size: cover;
|
||||
text-shadow: 1px 1px 0 rgba(0, 0, 0, 0.75);
|
||||
}
|
||||
|
||||
/*--------------------------------------------------------------------------*/
|
||||
/* Control, Tool, hotbar & navigation */
|
||||
|
||||
@@ -1550,4 +1555,8 @@ form .notes {
|
||||
}
|
||||
a.content-link, a.inline-roll {
|
||||
color: #222;
|
||||
}
|
||||
.journal-page-header,
|
||||
.journal-page-content {
|
||||
color: #222;
|
||||
}
|
||||
@@ -107,7 +107,7 @@
|
||||
"styles": [
|
||||
"styles/simple.css"
|
||||
],
|
||||
"version": "10.0.27",
|
||||
"version": "10.0.31",
|
||||
"compatibility": {
|
||||
"minimum": "10",
|
||||
"verified": "10",
|
||||
@@ -115,7 +115,7 @@
|
||||
},
|
||||
"title": "Warhero RPG",
|
||||
"manifest": "https://www.uberwald.me/gitea/public/fvtt-warhero/raw/branch/master/system.json",
|
||||
"download": "https://www.uberwald.me/gitea/uberwald/fvtt-warhero/archive/fvtt-warhero-10.0.27.zip",
|
||||
"download": "https://www.uberwald.me/gitea/uberwald/fvtt-warhero/archive/fvtt-warhero-10.0.31.zip",
|
||||
"url": "https://www.uberwald.me/gitea/public/fvtt-warhero",
|
||||
"background": "images/ui/warhero_welcome_page.webp",
|
||||
"id": "fvtt-warhero"
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
"biodata": {
|
||||
"class": "",
|
||||
"age": 0,
|
||||
"size": 0,
|
||||
"size": 3,
|
||||
"weight": "",
|
||||
"height": "",
|
||||
"hair": "",
|
||||
@@ -111,6 +111,7 @@
|
||||
"label": "WH.ui.Initiative",
|
||||
"abbrev": "ini",
|
||||
"style": "edit",
|
||||
"roll": true,
|
||||
"max": 1,
|
||||
"value": 1
|
||||
},
|
||||
@@ -180,9 +181,11 @@
|
||||
},
|
||||
"counterspell": {
|
||||
"label": "WH.ui.counterspell",
|
||||
"stat": "min",
|
||||
"abbrev": "counterspell",
|
||||
"style": "edit",
|
||||
"hasmax": true,
|
||||
"roll": true,
|
||||
"max": 1,
|
||||
"value": 0
|
||||
},
|
||||
@@ -236,7 +239,8 @@
|
||||
"power",
|
||||
"language",
|
||||
"condition",
|
||||
"class"
|
||||
"class",
|
||||
"genericitem"
|
||||
],
|
||||
"templates": {
|
||||
"commonclassrace": {
|
||||
@@ -260,6 +264,9 @@
|
||||
}
|
||||
}
|
||||
},
|
||||
"genericitem": {
|
||||
"description": ""
|
||||
},
|
||||
"condition": {
|
||||
"shortdescription": "",
|
||||
"description": ""
|
||||
@@ -288,6 +295,7 @@
|
||||
"skill": {
|
||||
"classskill": false,
|
||||
"unlimited": false,
|
||||
"acquiredatlevel": 0,
|
||||
"currentuse": 0,
|
||||
"maxuse": 0,
|
||||
"description": ""
|
||||
@@ -332,6 +340,7 @@
|
||||
"equipped": false,
|
||||
"slotused": 1,
|
||||
"slotlocation": "backpack",
|
||||
"providedslot": 0,
|
||||
"description": ""
|
||||
},
|
||||
"power": {
|
||||
|
||||
@@ -103,17 +103,17 @@
|
||||
</li>
|
||||
{{/if}}
|
||||
{{/each}}
|
||||
{{#each competency.shields as |flag key|}}
|
||||
{{#if flag}}
|
||||
{{#each competency.shields as |cdata key|}}
|
||||
{{#if cdata}}
|
||||
<li class="item flexrow list-item list-item-shadow" data-item-id="{{language._id}}">
|
||||
<span class="item-name-label-long">{{localize "WH.ui.shields"}} {{key}}</span>
|
||||
<span class="item-name-label-long">{{localize "WH.ui.shields"}} {{localize cdata.label}}</span>
|
||||
</li>
|
||||
{{/if}}
|
||||
{{/each}}
|
||||
{{#each competency.armors as |flag key|}}
|
||||
{{#if flag}}
|
||||
{{#each competency.armors as |cdata key|}}
|
||||
{{#if cdata}}
|
||||
<li class="item flexrow list-item list-item-shadow" data-item-id="{{language._id}}">
|
||||
<span class="item-name-label-long">{{localize "WH.ui.armors"}} {{key}}</span>
|
||||
<span class="item-name-label-long">{{localize "WH.ui.armors"}} {{localize cdata.label}}</span>
|
||||
</li>
|
||||
{{/if}}
|
||||
{{/each}}
|
||||
@@ -191,7 +191,7 @@
|
||||
src="{{weapon.img}}" /></a>
|
||||
<span class="item-name-label-long"><a class="roll-weapon"><i class="fa-solid fa-dice-d20"></i>{{weapon.name}}</a></span>
|
||||
|
||||
<span class="item-field-label-medium">{{weapon.system.weapontype}}</span>
|
||||
<span class="item-field-label-medium">{{localize (concat "WH.conf." weapon.system.weapontype)}}</span>
|
||||
|
||||
{{#if (eq system.weapontype "special")}}
|
||||
<span class="item-field-label-medium"><a class="roll-damage"><i class="fa-solid fa-dice-d20"></i>{{weapon.system.damageformula}}</a></span>
|
||||
@@ -306,7 +306,9 @@
|
||||
<span class="item-field-label-medium">N/A</span>
|
||||
<span class="item-field-label-medium">N/A</span>
|
||||
{{else}}
|
||||
<span class="item-field-label-medium">{{skill.system.currentuse}}</span>
|
||||
<span class="item-field-label-medium">{{skill.system.currentuse}}
|
||||
(<a class="skill-use-minus plus-minus-button"> -</a>/<a class="skill-use-plus plus-minus-button">+</a>)
|
||||
</span>
|
||||
<span class="item-field-label-medium">{{skill.system.maxuse}}</span>
|
||||
{{/if}}
|
||||
|
||||
@@ -446,7 +448,7 @@
|
||||
</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-add" data-type="{{itemtype}}" title="Create Item"><i class="fas fa-plus"></i></a>
|
||||
<a class="item-control item-add" data-type="{{itemtype}}" data-slot="{{slotKey}}" title="Create Item"><i class="fas fa-plus"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{#each slot.content as |item itemKey|}}
|
||||
@@ -486,20 +488,20 @@
|
||||
<ul class="item-list alternate-list">
|
||||
<li class="item flexrow">
|
||||
<label class="generic-label">{{localize "WH.ui.origin"}}</label>
|
||||
<input type="text" class="" name="system.biodata.origin" value="{{data.biodata.origin}}"
|
||||
<input type="text" class="" name="system.biodata.origin" value="{{system.biodata.origin}}"
|
||||
data-dtype="String" />
|
||||
</li>
|
||||
<li class="item flexrow">
|
||||
<label class="generic-label">{{localize "WH.ui.age"}}</label>
|
||||
<input type="text" class="" name="system.biodata.age" value="{{data.biodata.age}}" data-dtype="String" />
|
||||
<input type="text" class="" name="system.biodata.age" value="{{system.biodata.age}}" data-dtype="String" />
|
||||
</li>
|
||||
<li class="item flexrow">
|
||||
<label class="generic-label">{{localize "WH.ui.height"}}</label>
|
||||
<input type="text" class="" name="system.biodata.height" value="{{data.biodata.height}}" data-dtype="String" />
|
||||
<input type="text" class="" name="system.biodata.height" value="{{system.biodata.height}}" data-dtype="String" />
|
||||
</li>
|
||||
<li class="flexrow item">
|
||||
<label class="generic-label">{{localize "WH.ui.preferredhand"}}</label>
|
||||
<input type="text" class="" name="system.biodata.preferredhand" value="{{data.biodata.preferredhand}}"
|
||||
<input type="text" class="" name="system.biodata.preferredhand" value="{{system.biodata.preferredhand}}"
|
||||
data-dtype="String" />
|
||||
</li>
|
||||
</ul>
|
||||
@@ -508,8 +510,8 @@
|
||||
<ul>
|
||||
<li class="flexrow item">
|
||||
<label class="generic-label">{{localize "WH.ui.size"}}</label>
|
||||
<select class="competence-base flexrow" type="text" name="system.biodata.size" value="{{data.biodata.size}}" data-dtype="Number">
|
||||
{{#select data.biodata.size}}
|
||||
<select class="competence-base flexrow" type="text" name="system.biodata.size" value="{{system.biodata.size}}" data-dtype="Number">
|
||||
{{#select system.biodata.size}}
|
||||
<option value="1">Tiny</option>
|
||||
<option value="2">Small</option>
|
||||
<option value="3">Medium</option>
|
||||
@@ -521,15 +523,15 @@
|
||||
</li>
|
||||
<li class="flexrow item">
|
||||
<label class="generic-label">{{localize "WH.ui.gender"}}</label>
|
||||
<input type="text" class="" name="system.biodata.sex" value="{{data.biodata.sex}}" data-dtype="String" />
|
||||
<input type="text" class="" name="system.biodata.sex" value="{{system.biodata.sex}}" data-dtype="String" />
|
||||
</li>
|
||||
<li class="item flexrow">
|
||||
<label class="generic-label">{{localize "WH.ui.eyes"}}</label>
|
||||
<input type="text" class="" name="system.biodata.eyes" value="{{data.biodata.eyes}}" data-dtype="String" />
|
||||
<input type="text" class="" name="system.biodata.eyes" value="{{system.biodata.eyes}}" data-dtype="String" />
|
||||
</li>
|
||||
<li class="item flexrow">
|
||||
<label class="generic-label">{{localize "WH.ui.hair"}}</label>
|
||||
<input type="text" class="" name="system.biodata.hair" value="{{data.biodata.hair}}" data-dtype="String" />
|
||||
<input type="text" class="" name="system.biodata.hair" value="{{system.biodata.hair}}" data-dtype="String" />
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
@@ -13,7 +13,7 @@
|
||||
<div class="tab details" data-group="primary" data-tab="description">
|
||||
|
||||
<label class="generic-label">{{localize "WH.ui.description"}}</label>
|
||||
<div class="medium-editor item-text-long-line">
|
||||
<div class="editor item-text-long-line">
|
||||
{{editor description target="system.description" button=true owner=owner editable=editable}}
|
||||
</div>
|
||||
</div>
|
||||
@@ -22,7 +22,7 @@
|
||||
<ul>
|
||||
|
||||
{{#each system.weapons as |weaponflag key|}}
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.weapons"}} {{key}}</label>
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.weapons"}} {{localize (concat "WH.conf." key)}}</label>
|
||||
<input type="checkbox" class="padd-right status-small-label color-class-common item-field-label-short"
|
||||
name="system.weapons.{{key}}" {{checked weaponflag}}/>
|
||||
|
||||
@@ -30,7 +30,7 @@
|
||||
{{/each}}
|
||||
|
||||
{{#each system.armors as |armorflag key|}}
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.armors"}} {{key}}</label>
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.armors"}} {{localize (concat "WH.conf." key "armor")}}</label>
|
||||
<input type="checkbox" class="padd-right status-small-label color-class-common item-field-label-short"
|
||||
name="system.armors.{{key}}" {{checked armorflag}}/>
|
||||
|
||||
@@ -38,7 +38,7 @@
|
||||
{{/each}}
|
||||
|
||||
{{#each system.shields as |shieldflag key|}}
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.shields"}} {{key}}</label>
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.shields"}} {{localize (concat "WH.conf." key "shield")}}</label>
|
||||
<input type="checkbox" class="padd-right status-small-label color-class-common item-field-label-short"
|
||||
name="system.shields.{{key}}" {{checked shieldflag}}/>
|
||||
|
||||
|
||||
@@ -16,6 +16,10 @@
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
<ul>
|
||||
|
||||
<li class="flexrow"><label class="item-field-label-medium ">{{localize "WH.ui.providedslot"}}</label>
|
||||
<input type="text" class="item-field-label-medium " name="system.providedslot" value="{{system.providedslot}}" data-dtype="Number"/>
|
||||
</li>
|
||||
|
||||
{{> systems/fvtt-warhero/templates/partial-item-common-equipment.html}}
|
||||
|
||||
</ul>
|
||||
|
||||
24
templates/item-genericitem-sheet.html
Normal file
24
templates/item-genericitem-sheet.html
Normal file
@@ -0,0 +1,24 @@
|
||||
<form class="{{cssClass}}" autocomplete="off">
|
||||
<header class="sheet-header">
|
||||
<img class="item-sheet-img" src="{{img}}" data-edit="img" title="{{name}}" />
|
||||
<div class="header-fields">
|
||||
<h1 class="charname"><input name="name" type="text" value="{{name}}" placeholder="Name" /></h1>
|
||||
</div>
|
||||
</header>
|
||||
{{> systems/fvtt-warhero/templates/partial-item-nav.html}}
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-warhero/templates/partial-item-description.html}}
|
||||
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
<ul>
|
||||
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</form>
|
||||
@@ -13,7 +13,7 @@
|
||||
<div class="tab details" data-group="primary" data-tab="description">
|
||||
|
||||
<label class="generic-label">Description</label>
|
||||
<div class="medium-editor item-text-long-line">
|
||||
<div class="editor item-text-long-line">
|
||||
{{editor description target="system.description" button=true owner=owner editable=editable}}
|
||||
</div>
|
||||
</div>
|
||||
@@ -64,7 +64,7 @@
|
||||
</li>
|
||||
|
||||
{{#each system.weapons as |weaponflag key|}}
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.weapons"}} {{key}}</label>
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.weapons"}} {{localize (concat "WH.conf." key)}}</label>
|
||||
<input type="checkbox" class="padd-right status-small-label color-class-common item-field-label-short"
|
||||
name="system.weapons.{{key}}" {{checked weaponflag}}/>
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
{{/each}}
|
||||
|
||||
{{#each system.armors as |armorflag key|}}
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.armors"}} {{key}}</label>
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.armors"}} {{localize (concat "WH.conf." key "armor")}}</label>
|
||||
<input type="checkbox" class="padd-right status-small-label color-class-common item-field-label-short"
|
||||
name="system.armors.{{key}}" {{checked armorflag}}/>
|
||||
|
||||
@@ -80,7 +80,7 @@
|
||||
{{/each}}
|
||||
|
||||
{{#each system.shields as |shieldflag key|}}
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.shields"}} {{key}}</label>
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.shields"}} {{localize (concat "WH.conf." key "shield")}}</label>
|
||||
<input type="checkbox" class="padd-right status-small-label color-class-common item-field-label-short"
|
||||
name="system.shields.{{key}}" {{checked shieldflag}}/>
|
||||
|
||||
|
||||
@@ -23,6 +23,10 @@
|
||||
<input type="checkbox" name="system.unlimited" {{checked system.unlimited}}/>
|
||||
</li>
|
||||
|
||||
<li class="flexrow"><label class="item-field-label-long ">{{localize "WH.ui.skilllevelacquired"}}</label>
|
||||
<input type="text" class="item-field-label-medium " name="system.acquiredatlevel" value="{{system.acquiredatlevel}}" data-dtype="Number"/>
|
||||
</li>
|
||||
|
||||
{{#if system.unlimited}}
|
||||
|
||||
{{else}}
|
||||
|
||||
@@ -34,11 +34,11 @@
|
||||
{{/if}}
|
||||
|
||||
{{#if hassave}}
|
||||
<span class="item-field-label-short" name="{{key}}">
|
||||
<h4 class="item-field-label-short">
|
||||
<span class="item-field-label-medium" name="{{key}}">
|
||||
<h4 class="item-field-label-medium">
|
||||
<i class="fa-solid fa-dice-d20"></i>
|
||||
<a class="roll-save stat-margin" data-type="{{path}}" data-key="{{key}}">
|
||||
{{localize "WH.ui.save"}}
|
||||
{{localize (concat "WH.ui.save" key)}}
|
||||
</a>
|
||||
</h4>
|
||||
</span>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
<div class="tab description" data-group="primary" data-tab="description">
|
||||
<div>
|
||||
<label class="generic-label">{{localize "WH.ui.description"}}</label>
|
||||
<div class="medium-editor item-text-long-line">
|
||||
<div class="editor item-text-long-line">
|
||||
{{editor description target="system.description" button=true owner=owner editable=editable}}
|
||||
</div>
|
||||
</div>
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
{{#if is2hands}}
|
||||
<span class="item-field-label-vlong">{{weapon.damageFormula2Hands}}</span>
|
||||
{{else}}
|
||||
<span class="item-field-label-vlong">{{weapon.damage}}</span>
|
||||
<span class="item-field-label-vlong">{{weapon.damageFormula}}</span>
|
||||
{{/if}}
|
||||
</div>
|
||||
{{/if}}
|
||||
@@ -54,7 +54,7 @@
|
||||
|
||||
{{#if stat.istxc}}
|
||||
<div class="flexrow">
|
||||
<span class="item-field-label-vlong">{{localize "WH.chat.mweaponmalus}}" ({{mWeaponMalus}})? </span>
|
||||
<span class="item-field-label-vlong">{{localize "WH.chat.mweaponmalus"}} ({{mWeaponMalus}})? </span>
|
||||
<span class="item-field-label-medium"><input type="checkbox" id="usemWeaponMalus" name="usemWeaponMalus" {{checked usemWeaponMalus}}/></span>
|
||||
{{/if}}
|
||||
</div>
|
||||
|
||||
Reference in New Issue
Block a user