Compare commits
14 Commits
fvtt-avd12
...
fvtt-avd12
Author | SHA1 | Date | |
---|---|---|---|
46f50bf4b4 | |||
c5a962936c | |||
56ff013178 | |||
8785a38a10 | |||
0b3a82f4b7 | |||
2b00991e16 | |||
e796fac928 | |||
be555d5adc | |||
85f4ba0e99 | |||
17bfd3eecd | |||
5f0973290a | |||
88b869f5e5 | |||
1ec8ee6451 | |||
66ed4c12cc |
Binary file not shown.
Before Width: | Height: | Size: 31 KiB |
BIN
images/icons/skill1.webp
Normal file
BIN
images/icons/skill1.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 17 KiB |
Binary file not shown.
Before Width: | Height: | Size: 30 KiB |
BIN
images/icons/spell1.webp
Normal file
BIN
images/icons/spell1.webp
Normal file
Binary file not shown.
After Width: | Height: | Size: 15 KiB |
@ -7,10 +7,15 @@
|
||||
"TypeWeapon": "Weapon",
|
||||
"TypeShield": "Shield",
|
||||
"TypeArmor": "Armor",
|
||||
"TypeSkill": "Skill",
|
||||
"TypeSpell": "Spell",
|
||||
"TypeModule": "Module",
|
||||
"TypeMoney": "Money",
|
||||
"TypeEquipment": "Equipment"
|
||||
"TypeEquipment": "Equipment",
|
||||
"TypeAction": "Action",
|
||||
"TypeFreeaction": "Free Action",
|
||||
"TypeReaction": "Reaction",
|
||||
"TypeStance": "Stance",
|
||||
"TypeTrait": "Trait",
|
||||
"TypeCondition": "Condition"
|
||||
}
|
||||
}
|
@ -13,7 +13,7 @@ export class Avd12ActorSheet extends ActorSheet {
|
||||
|
||||
return mergeObject(super.defaultOptions, {
|
||||
classes: ["fvtt-avd12", "sheet", "actor"],
|
||||
template: "systems/fvtt-avd12/templates/actor-sheet.html",
|
||||
template: "systems/fvtt-avd12/templates/actors/actor-sheet.hbs",
|
||||
width: 960,
|
||||
height: 720,
|
||||
tabs: [{ navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "skills" }],
|
||||
@ -35,11 +35,12 @@ export class Avd12ActorSheet extends ActorSheet {
|
||||
cssClass: this.isEditable ? "editable" : "locked",
|
||||
system: duplicate(this.object.system),
|
||||
limited: this.object.limited,
|
||||
skills: this.actor.getSkills( ),
|
||||
modules: this.actor.getModules(),
|
||||
traits: this.actor.getTraits(),
|
||||
weapons: this.actor.checkAndPrepareEquipments( duplicate(this.actor.getWeapons()) ),
|
||||
armors: this.actor.checkAndPrepareEquipments( duplicate(this.actor.getArmors())),
|
||||
shields: this.actor.checkAndPrepareEquipments( duplicate(this.actor.getShields())),
|
||||
spells: this.actor.checkAndPrepareEquipments( duplicate(this.actor.getLore())),
|
||||
spells: this.actor.checkAndPrepareEquipments( duplicate(this.actor.getSpells())),
|
||||
equipments: this.actor.checkAndPrepareEquipments(duplicate(this.actor.getEquipmentsOnly()) ),
|
||||
equippedWeapons: this.actor.checkAndPrepareEquipments(duplicate(this.actor.getEquippedWeapons()) ),
|
||||
equippedArmor: this.actor.getEquippedArmor(),
|
||||
@ -81,7 +82,7 @@ export class Avd12ActorSheet extends ActorSheet {
|
||||
// Delete Inventory Item
|
||||
html.find('.item-delete').click(ev => {
|
||||
const li = $(ev.currentTarget).parents(".item")
|
||||
CrucibleUtility.confirmDelete(this, li)
|
||||
Avd12Utility.confirmDelete(this, li)
|
||||
})
|
||||
html.find('.item-add').click(ev => {
|
||||
let dataType = $(ev.currentTarget).data("type")
|
||||
@ -129,14 +130,10 @@ export class Avd12ActorSheet extends ActorSheet {
|
||||
this.actor.incDecAmmo( li.data("item-id"), +1 )
|
||||
} );
|
||||
|
||||
html.find('.roll-ability').click((event) => {
|
||||
const abilityKey = $(event.currentTarget).data("ability-key");
|
||||
this.actor.rollAbility(abilityKey);
|
||||
});
|
||||
html.find('.roll-skill').click((event) => {
|
||||
const li = $(event.currentTarget).parents(".item")
|
||||
const skillId = li.data("item-id")
|
||||
this.actor.rollSkill(skillId)
|
||||
let attrKey = $(event.currentTarget).data("attr-key")
|
||||
let skillKey = $(event.currentTarget).data("skill-key")
|
||||
this.actor.rollSkill(attrKey, skillKey)
|
||||
});
|
||||
|
||||
html.find('.roll-weapon').click((event) => {
|
||||
|
@ -36,8 +36,6 @@ export class Avd12Actor extends Actor {
|
||||
}
|
||||
|
||||
if (data.type == 'character') {
|
||||
const skills = await Avd12Utility.loadCompendium("fvtt-avd12.skills")
|
||||
data.items = skills.map(i => i.toObject())
|
||||
}
|
||||
if (data.type == 'npc') {
|
||||
}
|
||||
@ -51,13 +49,32 @@ export class Avd12Actor extends Actor {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async prepareData() {
|
||||
super.prepareData();
|
||||
|
||||
super.prepareData()
|
||||
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
computeHitPoints() {
|
||||
if (this.type == "character") {
|
||||
}
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
rebuildSkills() {
|
||||
for (let attrKey in this.system.attributes) {
|
||||
let attr = this.system.attributes[attrKey]
|
||||
for (let skillKey in attr.skills) {
|
||||
let dataPath = attrKey + ".skills." + skillKey + ".modifier"
|
||||
let skill = attr.skills[skillKey]
|
||||
skill.modifier = 0
|
||||
let availableTraits = this.items.filter(t => t.type == "trait" && t.system.computebonus && t.system.bonusdata == dataPath)
|
||||
for (let trait of availableTraits) {
|
||||
skill.modifier += Number(trait.system.bonusvalue)
|
||||
}
|
||||
skill.finalvalue = skill.modifier + attr.value
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
@ -67,7 +84,8 @@ export class Avd12Actor extends Actor {
|
||||
this.system.encCapacity = this.getEncumbranceCapacity()
|
||||
this.buildContainerTree()
|
||||
this.computeHitPoints()
|
||||
this.computeEffortPoints()
|
||||
|
||||
this.rebuildSkills()
|
||||
}
|
||||
|
||||
super.prepareDerivedData();
|
||||
@ -79,6 +97,11 @@ export class Avd12Actor extends Actor {
|
||||
super._preUpdate(changed, options, user);
|
||||
}
|
||||
|
||||
/*_onUpdateEmbeddedDocuments( embeddedName, ...args ) {
|
||||
this.rebuildSkills()
|
||||
super._onUpdateEmbeddedDocuments(embeddedName, ...args)
|
||||
}*/
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getEncumbranceCapacity() {
|
||||
return 1;
|
||||
@ -108,6 +131,10 @@ export class Avd12Actor extends Actor {
|
||||
}
|
||||
return undefined
|
||||
}
|
||||
getSpells() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'spell') || []);
|
||||
return comp
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
getShields() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'shield') || []);
|
||||
@ -155,15 +182,14 @@ export class Avd12Actor extends Actor {
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getSkills() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'skill') || [])
|
||||
for (let skill of comp) {
|
||||
Avd12Utility.updateSkill(skill)
|
||||
}
|
||||
Avd12Utility.sortArrayObjectsByName(comp)
|
||||
getModules() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'module') || [])
|
||||
return comp
|
||||
}
|
||||
getTraits() {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'trait') || [])
|
||||
return comp
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getRelevantAttribute(attrKey) {
|
||||
let comp = duplicate(this.items.filter(item => item.type == 'skill' && item.system.attribute == attrKey) || []);
|
||||
@ -214,6 +240,31 @@ export class Avd12Actor extends Actor {
|
||||
return duplicate(this.items.filter(item => item.type == "equipment") || [])
|
||||
}
|
||||
|
||||
/* ------------------------------------------- */
|
||||
async addModuleLevel(moduleId, levelChoice) {
|
||||
for (let itemId in levelChoice.features) {
|
||||
let itemData = duplicate(levelChoice.features[itemId])
|
||||
itemData.system.moduleId = moduleId
|
||||
itemData.system.originalId = itemId
|
||||
//let item = await Item.create(itemData, { temporary: true });
|
||||
await this.createEmbeddedDocuments('Item', [itemData])
|
||||
}
|
||||
}
|
||||
/* ------------------------------------------- */
|
||||
async deleteModuleLevel(moduleId, levelChoice) {
|
||||
let toDelete = []
|
||||
for (let itemId in levelChoice.features) {
|
||||
let item = this.items.find(it => Avd12Utility.isModuleItemAllowed(it.type) && it.system.moduleId == moduleId && it.system.originalId == itemId)
|
||||
if (item) {
|
||||
toDelete.push(item.id)
|
||||
}
|
||||
}
|
||||
console.log("toele", toDelete, moduleId, levelChoice)
|
||||
if (toDelete.length > 0) {
|
||||
await this.deleteEmbeddedDocuments('Item', toDelete)
|
||||
}
|
||||
}
|
||||
|
||||
/* ------------------------------------------- */
|
||||
async buildContainerTree() {
|
||||
let equipments = duplicate(this.items.filter(item => item.type == "equipment") || [])
|
||||
@ -453,59 +504,13 @@ export class Avd12Actor extends Actor {
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
getCommonRollData(abilityKey = undefined) {
|
||||
let noAction = this.isNoAction()
|
||||
if (noAction) {
|
||||
ui.notifications.warn("You can't do any actions du to the condition : " + noAction.name)
|
||||
return
|
||||
}
|
||||
getCommonRollData() {
|
||||
|
||||
let rollData = Avd12Utility.getBasicRollData()
|
||||
rollData.alias = this.name
|
||||
rollData.actorImg = this.img
|
||||
rollData.actorId = this.id
|
||||
rollData.img = this.img
|
||||
rollData.featsDie = this.getFeatsWithDie()
|
||||
rollData.featsSL = this.getFeatsWithSL()
|
||||
rollData.armors = this.getArmors()
|
||||
rollData.conditions = this.getConditions()
|
||||
rollData.featDieName = "none"
|
||||
rollData.featSLName = "none"
|
||||
rollData.rollAdvantage = "none"
|
||||
rollData.advantage = "none"
|
||||
rollData.disadvantage = "none"
|
||||
rollData.forceAdvantage = this.isForcedAdvantage()
|
||||
rollData.forceDisadvantage = this.isForcedDisadvantage()
|
||||
rollData.forceRollAdvantage = this.isForcedRollAdvantage()
|
||||
rollData.forceRollDisadvantage = this.isForcedRollDisadvantage()
|
||||
rollData.noAdvantage = this.isNoAdvantage()
|
||||
if (rollData.defenderTokenId) {
|
||||
let defenderToken = game.canvas.tokens.get(rollData.defenderTokenId)
|
||||
let defender = defenderToken.actor
|
||||
|
||||
// Distance management
|
||||
let token = this.token
|
||||
if (!token) {
|
||||
let tokens = this.getActiveTokens()
|
||||
token = tokens[0]
|
||||
}
|
||||
if (token) {
|
||||
const ray = new Ray(token.object?.center || token.center, defenderToken.center)
|
||||
rollData.tokensDistance = canvas.grid.measureDistances([{ ray }], { gridSpaces: false })[0] / canvas.grid.grid.options.dimensions.distance
|
||||
} else {
|
||||
ui.notifications.info("No token connected to this actor, unable to compute distance.")
|
||||
return
|
||||
}
|
||||
if (defender) {
|
||||
rollData.forceAdvantage = defender.isAttackerAdvantage()
|
||||
rollData.advantageFromTarget = true
|
||||
}
|
||||
}
|
||||
|
||||
if (abilityKey) {
|
||||
rollData.ability = this.getAbility(abilityKey)
|
||||
rollData.selectedKill = undefined
|
||||
}
|
||||
|
||||
console.log("ROLLDATA", rollData)
|
||||
|
||||
@ -520,28 +525,22 @@ export class Avd12Actor extends Actor {
|
||||
ui.notifications.warn("You are targetting a token with a skill : please use a Weapon instead.")
|
||||
return
|
||||
}
|
||||
Avd12Utility.rollCrucible(rollData)
|
||||
Avd12Utility.rollAvd12(rollData)
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
rollSkill(skillId) {
|
||||
let skill = this.items.get(skillId)
|
||||
rollSkill(attrKey, skillKey) {
|
||||
let attr = this.system.attributes[attrKey]
|
||||
let skill = attr.skills[skillKey]
|
||||
if (skill) {
|
||||
if (skill.system.islore && skill.system.level == 0) {
|
||||
ui.notifications.warn("You can't use Lore Skills with a SL of 0.")
|
||||
return
|
||||
}
|
||||
skill = duplicate(skill)
|
||||
Avd12Utility.updateSkill(skill)
|
||||
let abilityKey = skill.system.ability
|
||||
let rollData = this.getCommonRollData(abilityKey)
|
||||
skill.name = Avd12Utility.upperFirst(skillKey)
|
||||
skill.attr = duplicate(attr)
|
||||
let rollData = this.getCommonRollData()
|
||||
rollData.mode = "skill"
|
||||
rollData.skill = skill
|
||||
rollData.title = "Roll Skill " + skill.name
|
||||
rollData.img = skill.img
|
||||
if (rollData.target) {
|
||||
ui.notifications.warn("You are targetting a token with a skill : please use a Weapon instead.")
|
||||
return
|
||||
}
|
||||
this.startRoll(rollData)
|
||||
}
|
||||
}
|
||||
@ -611,7 +610,7 @@ export class Avd12Actor extends Actor {
|
||||
let rollData = this.getCommonRollData()
|
||||
rollData.defenderTokenId = undefined // Cleanup
|
||||
rollData.mode = "rangeddefense"
|
||||
if ( attackRollData) {
|
||||
if (attackRollData) {
|
||||
rollData.attackRollData = duplicate(attackRollData)
|
||||
rollData.effectiveRange = Avd12Utility.getWeaponRange(attackRollData.weapon)
|
||||
rollData.tokensDistance = attackRollData.tokensDistance // QoL copy
|
||||
@ -701,27 +700,10 @@ export class Avd12Actor extends Actor {
|
||||
return { armorIgnored: true, nbSuccess: 0, messages: ["No armor equipped."] }
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
rollSave(saveKey) {
|
||||
let saves = this.getSaveRoll()
|
||||
let save = saves[saveKey]
|
||||
if (save) {
|
||||
save = duplicate(save)
|
||||
let rollData = this.getCommonRollData()
|
||||
rollData.mode = "save"
|
||||
rollData.save = save
|
||||
if (rollData.target) {
|
||||
ui.notifications.warn("You are targetting a token with a save roll - Not authorized.")
|
||||
return
|
||||
}
|
||||
this.startRoll(rollData)
|
||||
}
|
||||
|
||||
}
|
||||
/* -------------------------------------------- */
|
||||
async startRoll(rollData) {
|
||||
this.syncRoll(rollData)
|
||||
let rollDialog = await CrucibleRollDialog.create(this, rollData)
|
||||
let rollDialog = await Avd12RollDialog.create(this, rollData)
|
||||
rollDialog.render(true)
|
||||
}
|
||||
|
||||
|
@ -14,11 +14,12 @@ export class Avd12ItemSheet extends ItemSheet {
|
||||
template: "systems/fvtt-avd12/templates/item-sheet.hbs",
|
||||
dragDrop: [{ dragSelector: null, dropSelector: null }],
|
||||
width: 620,
|
||||
height: 550,
|
||||
tabs: [{navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "description"}]
|
||||
height: 480,
|
||||
tabs: [{ navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "description" }]
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
/* -------------------------------------------- */
|
||||
_getHeaderButtons() {
|
||||
let buttons = super._getHeaderButtons();
|
||||
@ -48,7 +49,16 @@ export class Avd12ItemSheet extends ItemSheet {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async getData() {
|
||||
|
||||
|
||||
// Specific case for formating descriptions of sub-items
|
||||
if (this.object.type == "module") {
|
||||
for (let level of this.object.system.levels) {
|
||||
for (let id in level.features) {
|
||||
level.features[id].descriptionHTML = await TextEditor.enrichHTML(level.features[id].system.description, { async: true })
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
let formData = {
|
||||
title: this.title,
|
||||
id: this.id,
|
||||
@ -61,6 +71,8 @@ export class Avd12ItemSheet extends ItemSheet {
|
||||
limited: this.object.limited,
|
||||
options: this.options,
|
||||
owner: this.document.isOwner,
|
||||
bonusList: Avd12Utility.buildBonusList(),
|
||||
description: await TextEditor.enrichHTML(this.object.system.description, { async: true }),
|
||||
isGM: game.user.isGM
|
||||
}
|
||||
|
||||
@ -83,7 +95,7 @@ export class Avd12ItemSheet extends ItemSheet {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
postItem() {
|
||||
let chatData = duplicate(CrucibleUtility.data(this.item));
|
||||
let chatData = duplicate(this.item)
|
||||
if (this.actor) {
|
||||
chatData.actor = { id: this.actor.id };
|
||||
}
|
||||
@ -99,11 +111,91 @@ export class Avd12ItemSheet extends ItemSheet {
|
||||
});
|
||||
|
||||
renderTemplate('systems/avd12/templates/post-item.html', chatData).then(html => {
|
||||
let chatOptions = CrucibleUtility.chatDataSetup(html);
|
||||
let chatOptions = Avd12Utility.chatDataSetup(html);
|
||||
ChatMessage.create(chatOptions)
|
||||
});
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async _onDrop(event) {
|
||||
|
||||
let li = $(event.toElement).parents(".item")
|
||||
const levelIndex = Number(li.data("level-index"))
|
||||
const choiceIndex = Number(li.data("choice-index"))
|
||||
let data = event.dataTransfer.getData('text/plain')
|
||||
let dataItem = JSON.parse(data)
|
||||
let item = fromUuidSync(dataItem.uuid)
|
||||
if (item.pack) {
|
||||
item = await Avd12Utility.searchItem(item)
|
||||
}
|
||||
if (!item) {
|
||||
ui.notifications.warn("Unable to find relevant item - Aborting drag&drop " + data.uuid)
|
||||
return
|
||||
}
|
||||
if (this.object.type == "module" && Avd12Utility.isModuleItemAllowed(item.type) ) {
|
||||
let levels = duplicate(this.object.system.levels)
|
||||
levels[levelIndex].choices[choiceIndex].features[item.id] = duplicate(item)
|
||||
this.object.update({ 'system.levels': levels })
|
||||
return
|
||||
}
|
||||
ui.notifications.warn("This item is not allowed dropped here")
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async viewSubitem(ev) {
|
||||
let levelIndex = Number($(ev.currentTarget).parents(".item").data("level-index"))
|
||||
let choiceIndex = Number($(ev.currentTarget).parents(".item").data("choice-index"))
|
||||
let featureId = $(ev.currentTarget).parents(".item").data("feature-id")
|
||||
|
||||
let itemData = this.object.system.levels[levelIndex].choices[choiceIndex].features[featureId]
|
||||
|
||||
if (itemData.name != 'None') {
|
||||
let item = await Item.create(itemData, { temporary: true });
|
||||
item.system.origin = "embeddedItem";
|
||||
new Avd12ItemSheet(item).render(true);
|
||||
}
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async deleteSubitem(ev) {
|
||||
let field = $(ev.currentTarget).data('type');
|
||||
let idx = Number($(ev.currentTarget).data('index'));
|
||||
let oldArray = this.object.system[field];
|
||||
let itemData = this.object.system[field][idx];
|
||||
if (itemData.name != 'None') {
|
||||
let newArray = [];
|
||||
for (var i = 0; i < oldArray.length; i++) {
|
||||
if (i != idx) {
|
||||
newArray.push(oldArray[i]);
|
||||
}
|
||||
}
|
||||
this.object.update({ [`system.${field}`]: newArray });
|
||||
}
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async processChoiceLevelSelection(ev) {
|
||||
let levels = duplicate(this.object.system.levels)
|
||||
let levelIndex = Number($(ev.currentTarget).parents(".item").data("level-index"))
|
||||
let choiceIndex = Number($(ev.currentTarget).parents(".item").data("choice-index"))
|
||||
for (let choice of levels[levelIndex].choices) {
|
||||
choice.selected = false // Everybody to false
|
||||
}
|
||||
levels[levelIndex].choices[choiceIndex].selected = ev.currentTarget.checked
|
||||
//console.log("Added", obj, levels, this.object.actor)
|
||||
if ( this.object.actor ) {
|
||||
let obj = await this.object.actor.updateEmbeddedDocuments('Item', [{ _id: this.object.id, 'system.levels': levels }]);
|
||||
if ( ev.currentTarget.checked ) {
|
||||
console.log("Added", obj, levels)
|
||||
this.object.actor.addModuleLevel( this.object.id, levels[levelIndex].choices[choiceIndex] )
|
||||
} else {
|
||||
this.object.actor.deleteModuleLevel( this.object.id, levels[levelIndex].choices[choiceIndex] )
|
||||
}
|
||||
} else {
|
||||
this.object.update({ 'system.levels': levels })
|
||||
}
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
/** @override */
|
||||
activateListeners(html) {
|
||||
@ -120,10 +212,6 @@ export class Avd12ItemSheet extends ItemSheet {
|
||||
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);
|
||||
});
|
||||
@ -135,18 +223,34 @@ export class Avd12ItemSheet extends ItemSheet {
|
||||
let itemType = li.data("item-type");
|
||||
});
|
||||
|
||||
html.find('.view-subitem').click(ev => {
|
||||
html.find('.module-feature-view').click(ev => {
|
||||
this.viewSubitem(ev);
|
||||
});
|
||||
|
||||
html.find('.view-spec').click(ev => {
|
||||
this.manageSpec();
|
||||
});
|
||||
html.find('.add-module-level').click(ev => {
|
||||
let levels = duplicate(this.object.system.levels)
|
||||
if ( (levels.length+1) % 2 == 0) {
|
||||
levels.push({ choices: [ {selected: false, features: {} }, {selected: false, features: {} } ] })
|
||||
}else {
|
||||
levels.push({ choices: [ {selected: false, features: {} } ] })
|
||||
}
|
||||
this.object.update({ 'system.levels': levels })
|
||||
})
|
||||
|
||||
html.find('.module-feature-delete').click(ev => {
|
||||
let levels = duplicate(this.object.system.levels)
|
||||
let levelIndex = Number($(ev.currentTarget).parents(".item").data("level-index"))
|
||||
let choiceIndex = Number($(ev.currentTarget).parents(".item").data("choice-index"))
|
||||
let featureId = $(ev.currentTarget).parents(".item").data("feature-id")
|
||||
levels[levelIndex].choices[choiceIndex].features[featureId] = undefined
|
||||
this.object.update({ 'system.levels': levels })
|
||||
})
|
||||
|
||||
html.find('.choice-level-selected').change(ev => {
|
||||
this.processChoiceLevelSelection(ev)
|
||||
})
|
||||
}
|
||||
|
||||
|
||||
|
||||
/* -------------------------------------------- */
|
||||
get template() {
|
||||
let type = this.item.type;
|
||||
|
@ -1,7 +1,7 @@
|
||||
import { Avd12Utility } from "./avd12-utility.js";
|
||||
|
||||
export const defaultItemImg = {
|
||||
skill: "systems/fvtt-avd12/images/icons/skill1.webp",
|
||||
//skill: "systems/fvtt-avd12/images/icons/skill1.webp",
|
||||
armor: "systems/fvtt-avd12/images/icons/chest2.webp",
|
||||
shield: "systems/fvtt-avd12/images/icons/shield2.webp",
|
||||
weapon: "systems/fvtt-avd12/images/icons/weapon2.webp",
|
||||
|
@ -86,7 +86,7 @@ export class Avd12NPCSheet extends ActorSheet {
|
||||
// Delete Inventory Item
|
||||
html.find('.item-delete').click(ev => {
|
||||
const li = $(ev.currentTarget).parents(".item")
|
||||
CrucibleUtility.confirmDelete(this, li)
|
||||
Avd12Utility.confirmDelete(this, li)
|
||||
})
|
||||
html.find('.item-add').click(ev => {
|
||||
let dataType = $(ev.currentTarget).data("type")
|
||||
|
@ -5,10 +5,10 @@ export class Avd12RollDialog extends Dialog {
|
||||
/* -------------------------------------------- */
|
||||
static async create(actor, rollData) {
|
||||
|
||||
let options = { classes: ["Avd12Dialog"], width: 540, height: 340, 'z-index': 99999 };
|
||||
let html = await renderTemplate('systems/fvtt-avd12/templates/dialogs/roll-dialog-generic.html', rollData);
|
||||
let options = { classes: ["Avd12Dialog"], width: 540, height: 'fit-content', 'z-index': 99999 };
|
||||
let html = await renderTemplate('systems/fvtt-avd12/templates/dialogs/roll-dialog-generic.hbs', rollData);
|
||||
|
||||
return new CrucibleRollDialog(actor, rollData, html, options);
|
||||
return new Avd12RollDialog(actor, rollData, html, options);
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
@ -44,7 +44,7 @@ export class Avd12RollDialog extends Dialog {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
async refreshDialog() {
|
||||
const content = await renderTemplate("systems/fvtt-avd12/templates/dialogs/roll-dialog-generic.html", this.rollData)
|
||||
const content = await renderTemplate("systems/fvtt-avd12/templates/dialogs/roll-dialog-generic.hbs", this.rollData)
|
||||
this.data.content = content
|
||||
this.render(true)
|
||||
}
|
||||
@ -58,27 +58,12 @@ export class Avd12RollDialog extends Dialog {
|
||||
}
|
||||
$(function () { onLoad(); });
|
||||
|
||||
html.find('#advantage').change((event) => {
|
||||
this.rollData.advantage = event.currentTarget.value
|
||||
html.find('#bonusMalusRoll').change((event) => {
|
||||
this.rollData.bonusMalusRoll = event.currentTarget.value
|
||||
})
|
||||
html.find('#disadvantage').change((event) => {
|
||||
this.rollData.disadvantage = event.currentTarget.value
|
||||
html.find('#targetCheck').change((event) => {
|
||||
this.rollData.targetCheck = event.currentTarget.value
|
||||
})
|
||||
html.find('#rollAdvantage').change((event) => {
|
||||
this.rollData.rollAdvantage = event.currentTarget.value
|
||||
})
|
||||
html.find('#useshield').change((event) => {
|
||||
this.rollData.useshield = event.currentTarget.checked
|
||||
})
|
||||
html.find('#hasCover').change((event) => {
|
||||
this.rollData.hasCover = event.currentTarget.value
|
||||
})
|
||||
html.find('#situational').change((event) => {
|
||||
this.rollData.situational = event.currentTarget.value
|
||||
})
|
||||
html.find('#distanceBonusDice').change((event) => {
|
||||
this.rollData.distanceBonusDice = Number(event.currentTarget.value)
|
||||
})
|
||||
|
||||
|
||||
}
|
||||
}
|
@ -2,6 +2,9 @@
|
||||
import { Avd12Combat } from "./avd12-combat.js";
|
||||
import { Avd12Commands } from "./avd12-commands.js";
|
||||
|
||||
/* -------------------------------------------- */
|
||||
const __ALLOWED_MODULE_TYPES = { "action": 1, "reaction": 1, "freeaction": 1, "trait": 1 }
|
||||
|
||||
|
||||
/* -------------------------------------------- */
|
||||
export class Avd12Utility {
|
||||
@ -41,6 +44,9 @@ export class Avd12Utility {
|
||||
Handlebars.registerHelper('mul', function (a, b) {
|
||||
return parseInt(a) * parseInt(b);
|
||||
})
|
||||
Handlebars.registerHelper('add', function (a, b) {
|
||||
return parseInt(a) + parseInt(b);
|
||||
})
|
||||
}
|
||||
|
||||
/*-------------------------------------------- */
|
||||
@ -62,6 +68,32 @@ export class Avd12Utility {
|
||||
return duplicate(this.shieldSkills)
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static isModuleItemAllowed(type) {
|
||||
return __ALLOWED_MODULE_TYPES[type]
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static buildBonusList() {
|
||||
let bonusList = []
|
||||
for(let key in game.system.model.Actor.character.bonus) {
|
||||
let bonuses = game.system.model.Actor.character.bonus[key]
|
||||
for (let bonus in bonuses) {
|
||||
bonusList.push( key + "." + bonus )
|
||||
}
|
||||
}
|
||||
for(let key in game.system.model.Actor.character.attributes) {
|
||||
let attrs = game.system.model.Actor.character.attributes[key]
|
||||
for(let skillKey in attrs.skills) {
|
||||
bonusList.push( key + ".skills." + skillKey + ".modifier" )
|
||||
}
|
||||
}
|
||||
for(let key in game.system.model.Actor.character.universal.skills) {
|
||||
bonusList.push( "universal.skills." + key + ".modifier" )
|
||||
}
|
||||
return bonusList
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static async ready() {
|
||||
const skills = await Avd12Utility.loadCompendium("fvtt-avd12.skills")
|
||||
@ -128,11 +160,18 @@ export class Avd12Utility {
|
||||
'systems/fvtt-avd12/templates/items/partial-item-nav.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-item-description.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-common-item-fields.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-damage-types.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-weapon-types.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-weapon-categories.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-attributes.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-equipment-types.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-armor-types.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-spell-types.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-spell-levels.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-spell-schools.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-focus-bond.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-focus-treatment.hbs',
|
||||
'systems/fvtt-avd12/templates/items/partial-options-focus-core.hbs',
|
||||
]
|
||||
return loadTemplates(templatePaths);
|
||||
}
|
||||
@ -435,95 +474,17 @@ export class Avd12Utility {
|
||||
|
||||
let actor = game.actors.get(rollData.actorId)
|
||||
|
||||
// ability/save/size => 0
|
||||
let diceFormula
|
||||
let startFormula = "0d6cs>=5"
|
||||
if (rollData.ability) {
|
||||
startFormula = String(rollData.ability.value) + "d6cs>=5"
|
||||
}
|
||||
if (rollData.save) {
|
||||
startFormula = String(rollData.save.value) + "d6cs>=5"
|
||||
}
|
||||
if (rollData.sizeDice) {
|
||||
let nb = rollData.sizeDice.nb + rollData.distanceBonusDice + this.getDiceFromCover(rollData.hasCover) + this.getDiceFromSituational(rollData.situational)
|
||||
startFormula = String(nb) + String(rollData.sizeDice.dice) + "cs>=5"
|
||||
}
|
||||
diceFormula = startFormula
|
||||
|
||||
// skill => 2
|
||||
// feat => 4
|
||||
// bonus => 6
|
||||
// Build the dice formula
|
||||
let diceFormula = "1d12"
|
||||
if (rollData.skill) {
|
||||
let level = rollData.skill.system.level
|
||||
if (rollData.skill.system.issl2) {
|
||||
rollData.hasSLBonus = true
|
||||
level += 2
|
||||
if (level > 7) { level = 7 }
|
||||
}
|
||||
rollData.skill.system.skilldice = __skillLevel2Dice[level]
|
||||
diceFormula += "+" + String(rollData.skill.system.skilldice) + "cs>=5"
|
||||
|
||||
if (rollData.skill.system.skilltype == "complex" && rollData.skill.system.level == 0) {
|
||||
rollData.complexSkillDisadvantage = true
|
||||
rollData.rollAdvantage = "roll-disadvantage"
|
||||
}
|
||||
|
||||
if (rollData.skill.system.isfeatdie) {
|
||||
rollData.hasFeatDie = true
|
||||
diceFormula += "+ 1d10cs>=5"
|
||||
} else {
|
||||
diceFormula += `+ 0d10cs>=5`
|
||||
}
|
||||
if (rollData.skill.system.bonusdice != "none") {
|
||||
rollData.hasBonusDice = rollData.skill.system.bonusdice
|
||||
diceFormula += `+ ${rollData.hasBonusDice}cs>=5`
|
||||
} else {
|
||||
diceFormula += `+ 0d6cs>=5`
|
||||
}
|
||||
} else {
|
||||
diceFormula += `+ 0d8cs=>5 + 0d10cs>=5 + 0d6cs>=5`
|
||||
diceFormula += "+"+rollData.skill.finalvalue
|
||||
}
|
||||
|
||||
// advantage => 8
|
||||
let advFormula = "+ 0d8cs>=5"
|
||||
if (rollData.advantage == "advantage1" || rollData.forceAdvantage) {
|
||||
advFormula = "+ 1d8cs>=5"
|
||||
}
|
||||
if (rollData.advantage == "advantage2") {
|
||||
advFormula = "+ 2d8cs>=5"
|
||||
}
|
||||
diceFormula += advFormula
|
||||
|
||||
// disadvantage => 10
|
||||
let disFormula = "- 0d8cs>=5"
|
||||
if (rollData.disadvantage == "disadvantage1" || rollData.forceDisadvantage) {
|
||||
disFormula = "- 1d8cs>=5"
|
||||
}
|
||||
if (rollData.disadvantage == "disadvantage2") {
|
||||
disFormula = "- 2d8cs>=5"
|
||||
}
|
||||
diceFormula += disFormula
|
||||
|
||||
// armor => 12
|
||||
let skillArmorPenalty = 0
|
||||
for (let armor of rollData.armors) {
|
||||
if (armor.system.equipped) {
|
||||
skillArmorPenalty += armor.system.skillpenalty
|
||||
}
|
||||
}
|
||||
if (rollData.skill && rollData.skill.system.armorpenalty && skillArmorPenalty > 0) {
|
||||
rollData.skillArmorPenalty = skillArmorPenalty
|
||||
diceFormula += `- ${skillArmorPenalty}d8cs>=5`
|
||||
} else {
|
||||
diceFormula += `- 0d8cs>=5`
|
||||
}
|
||||
|
||||
// shield => 14
|
||||
if (rollData.useshield && rollData.shield) {
|
||||
diceFormula += "+ 1" + String(rollData.shield.system.shielddie) + "cs>=5"
|
||||
} else {
|
||||
diceFormula += " + 0d6cs>=5"
|
||||
diceFormula += "+"+rollData.bonusMalusRoll
|
||||
|
||||
if (rollData.skill && rollData.skill.good) {
|
||||
diceFormula += "+1d4"
|
||||
}
|
||||
rollData.diceFormula = diceFormula
|
||||
|
||||
// Performs roll
|
||||
console.log("Roll formula", diceFormula)
|
||||
@ -532,74 +493,21 @@ export class Avd12Utility {
|
||||
myRoll = new Roll(diceFormula).roll({ async: false })
|
||||
await this.showDiceSoNice(myRoll, game.settings.get("core", "rollMode"))
|
||||
}
|
||||
rollData.rollOrder = 0
|
||||
rollData.roll = myRoll
|
||||
rollData.nbSuccess = myRoll.total
|
||||
|
||||
if (rollData.rollAdvantage == "none" && rollData.forceRollAdvantage) {
|
||||
rollData.rollAdvantage = "roll-advantage"
|
||||
}
|
||||
if (rollData.rollAdvantage == "none" && rollData.forceRollDisadvantage) {
|
||||
rollData.rollAdvantage = "roll-disadvantage"
|
||||
}
|
||||
if (rollData.rollAdvantage != "none") {
|
||||
|
||||
rollData.rollOrder = 1
|
||||
rollData.rollType = (rollData.rollAdvantage == "roll-advantage") ? "Advantage" : "Disadvantage"
|
||||
this.createChatWithRollMode(rollData.alias, {
|
||||
content: await renderTemplate(`systems/fvtt-avd12/templates/chat-generic-result.html`, rollData)
|
||||
})
|
||||
|
||||
rollData.rollOrder = 2
|
||||
let myRoll2 = new Roll(diceFormula).roll({ async: false })
|
||||
await this.showDiceSoNice(myRoll2, game.settings.get("core", "rollMode"))
|
||||
|
||||
rollData.roll = myRoll2 // Tmp switch to display the proper results
|
||||
rollData.nbSuccess = myRoll2.total
|
||||
this.createChatWithRollMode(rollData.alias, {
|
||||
content: await renderTemplate(`systems/fvtt-avd12/templates/chat-generic-result.html`, rollData)
|
||||
})
|
||||
rollData.roll = myRoll // Revert the tmp switch
|
||||
rollData.nbSuccess = myRoll.total
|
||||
|
||||
if (rollData.rollAdvantage == "roll-advantage") {
|
||||
if (myRoll2.total > rollData.nbSuccess) {
|
||||
hasChanged = true
|
||||
rollData.roll = myRoll2
|
||||
rollData.nbSuccess = myRoll2.total
|
||||
}
|
||||
} else {
|
||||
if (myRoll2.total < rollData.nbSuccess) {
|
||||
rollData.roll = myRoll2
|
||||
rollData.nbSuccess = myRoll2.total
|
||||
}
|
||||
}
|
||||
rollData.rollOrder = 3
|
||||
}
|
||||
rollData.nbSuccess = Math.max(0, rollData.nbSuccess)
|
||||
|
||||
rollData.isFirstRollAdvantage = false
|
||||
// Manage exp
|
||||
if (rollData.skill && rollData.skill.system.level > 0) {
|
||||
let nbSkillSuccess = rollData.roll.terms[2].total
|
||||
if (nbSkillSuccess == 0 || nbSkillSuccess == rollData.skill.system.level) {
|
||||
actor.incrementSkillExp(rollData.skill.id, 1)
|
||||
|
||||
rollData.isSuccess = false
|
||||
if ( rollData.targetCheck != "none") {
|
||||
if( myRoll.total >= Number(rollData.targetCheck)) {
|
||||
rollData.isSuccess = true
|
||||
}
|
||||
}
|
||||
|
||||
this.saveRollData(rollData)
|
||||
actor.lastRoll = rollData
|
||||
|
||||
this.createChatWithRollMode(rollData.alias, {
|
||||
content: await renderTemplate(`systems/fvtt-avd12/templates/chat-generic-result.html`, rollData)
|
||||
let msg = await this.createChatWithRollMode(rollData.alias, {
|
||||
content: await renderTemplate(`systems/fvtt-avd12/templates/chat/chat-generic-result.hbs`, rollData)
|
||||
})
|
||||
msg.setFlag("world", "rolldata", rollData)
|
||||
|
||||
console.log("Rolldata result", rollData)
|
||||
|
||||
// Message response
|
||||
this.displayDefenseMessage(rollData)
|
||||
|
||||
// Manage defense result
|
||||
this.processAttackDefense(rollData)
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
@ -693,15 +601,16 @@ export class Avd12Utility {
|
||||
break;
|
||||
}
|
||||
chatOptions.alias = chatOptions.alias || name;
|
||||
ChatMessage.create(chatOptions);
|
||||
return ChatMessage.create(chatOptions);
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static getBasicRollData() {
|
||||
let rollData = {
|
||||
rollId: randomID(16),
|
||||
rollMode: game.settings.get("core", "rollMode"),
|
||||
advantage: "none"
|
||||
bonusMalusRoll: 0,
|
||||
targetCheck : "none",
|
||||
rollMode: game.settings.get("core", "rollMode")
|
||||
}
|
||||
Avd12Utility.updateWithTarget(rollData)
|
||||
return rollData
|
||||
@ -717,7 +626,7 @@ export class Avd12Utility {
|
||||
|
||||
/* -------------------------------------------- */
|
||||
static createChatWithRollMode(name, chatOptions) {
|
||||
this.createChatMessage(name, game.settings.get("core", "rollMode"), chatOptions)
|
||||
return this.createChatMessage(name, game.settings.get("core", "rollMode"), chatOptions)
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
|
@ -385,15 +385,19 @@ table {border: 1px solid #7a7971;}
|
||||
/* ======================================== */
|
||||
/* Sheet */
|
||||
.window-app.sheet .window-content .sheet-header{
|
||||
/*color: rgba(168, 139, 139, 0.5);*/
|
||||
color: rgba(228, 240, 240, 0.75);
|
||||
/*background: url("../images/ui/pc_sheet_bg.webp");*/
|
||||
background: #494e6b;
|
||||
}
|
||||
|
||||
input[type="text"], select[type="text"] {
|
||||
background:white;
|
||||
color: #494e6b;
|
||||
}
|
||||
|
||||
select {
|
||||
background:white;
|
||||
}
|
||||
/* background: #011d33 url("../images/ui/fond1.webp") repeat left top;*/
|
||||
/*color: rgba(168, 139, 139, 0.5);*/
|
||||
.window-app.sheet .window-content .sheet-header select[type="text"], .window-app.sheet .window-content .sheet-header input[type="text"], .window-app.sheet .window-content .sheet-header input[type="number"], .window-app.sheet .window-content .sheet-body input[type="text"], .window-app.sheet .window-content .sheet-body input[type="number"], .window-app.sheet .window-content .sheet-body select[type="text"] {
|
||||
@ -401,7 +405,7 @@ input[type="text"], select[type="text"] {
|
||||
}
|
||||
|
||||
.window-app.sheet .window-content .sheet-header input[type="password"], .window-app.sheet .window-content .sheet-header input[type="date"], .window-app.sheet .window-content .sheet-header input[type="time"] {
|
||||
color: rgba(36, 37, 37, 0.75);
|
||||
color: rgba(228, 240, 240, 0.75);
|
||||
background: #494e6b;
|
||||
border: 1 none;
|
||||
margin-bottom: 0.25rem;
|
||||
@ -409,7 +413,7 @@ input[type="text"], select[type="text"] {
|
||||
}
|
||||
|
||||
.window-app.sheet .window-content .sheet-body input[type="password"], .window-app.sheet .window-content .sheet-body input[type="date"], .window-app.sheet .window-content .sheet-body input[type="time"] {
|
||||
color: rgba(36, 37, 37, 0.75);
|
||||
color: rgba(228, 240, 240, 0.75);
|
||||
background: #494e6b;
|
||||
border: 1 none;
|
||||
margin-bottom: 0.25rem;
|
||||
@ -417,7 +421,7 @@ input[type="text"], select[type="text"] {
|
||||
}
|
||||
|
||||
.window-app.sheet .window-content .sheet-body select, .window-app.sheet .window-content .sheet-header select {
|
||||
color: rgba(36, 37, 37, 0.75);
|
||||
color: rgba(228, 240, 240, 0.75);
|
||||
background: #494e6b;
|
||||
border: 1 none;
|
||||
margin-bottom: 0.25rem;
|
||||
@ -428,6 +432,7 @@ input[type="text"], select[type="text"] {
|
||||
font-size: 0.8rem;
|
||||
/*background: url("../images/ui/pc_sheet_bg.webp") repeat left top;*/
|
||||
background: #494e6b;
|
||||
color: rgba(228, 240, 240, 0.75);
|
||||
}
|
||||
|
||||
/* background: rgba(245,245,240,0.6) url("../images/ui/sheet_background.webp") left top;*/
|
||||
@ -558,6 +563,7 @@ ul, li {
|
||||
padding: 0.125rem;
|
||||
flex: 1 1 5rem;
|
||||
display: flex !important;
|
||||
color: rgba(228, 240, 240, 0.75);
|
||||
}
|
||||
.list-item-shadow {
|
||||
background:rgba(87, 60, 32, 0.35);
|
||||
@ -800,6 +806,10 @@ ul, li {
|
||||
text-align: center;
|
||||
}
|
||||
|
||||
.skill-good-checkbox {
|
||||
height: 14px;
|
||||
width: 14px;
|
||||
}
|
||||
|
||||
.flex-actions-bar {
|
||||
flex-grow: 2;
|
||||
@ -1299,3 +1309,10 @@ ul, li {
|
||||
min-width:2rem;
|
||||
max-width: 2rem;
|
||||
}
|
||||
|
||||
.drop-module-step {
|
||||
background: linear-gradient(to bottom, #6c95b9fc 5%, #105177ab 100%);
|
||||
background-color: #7d5d3b00;
|
||||
border-radius: 3px;
|
||||
border: 2px ridge #846109;
|
||||
}
|
||||
|
14
system.json
14
system.json
@ -3,8 +3,8 @@
|
||||
"esmodules": [
|
||||
"modules/avd12-main.js"
|
||||
],
|
||||
"gridDistance": 5,
|
||||
"gridUnits": "m",
|
||||
"gridDistance": 1,
|
||||
"gridUnits": "u",
|
||||
"languages": [
|
||||
{
|
||||
"lang": "en",
|
||||
@ -20,15 +20,13 @@
|
||||
}
|
||||
],
|
||||
"license": "LICENSE.txt",
|
||||
"manifest": "https://www.uberwald.me/gitea/uberwald/fvtt-avd12/raw/branch/master/system.json",
|
||||
"manifest": "https://www.uberwald.me/gitea/public/fvtt-avd12/raw/branch/master/system.json",
|
||||
"compatibility": {
|
||||
"minimum": "10",
|
||||
"verified": "10",
|
||||
"maximum": "10"
|
||||
},
|
||||
"id": "fvtt-avd12",
|
||||
"packs": [
|
||||
],
|
||||
"primaryTokenAttribute": "secondary.health",
|
||||
"secondaryTokenAttribute": "secondary.delirium",
|
||||
"socket": true,
|
||||
@ -36,8 +34,8 @@
|
||||
"styles/simple.css"
|
||||
],
|
||||
"title": "AnyVenture D12 RPG",
|
||||
"url": "https://www.uberwald.me/gitea/uberwald/fvtt-avd12",
|
||||
"version": "10.0.0",
|
||||
"download": "https://www.uberwald.me/gitea/uberwald/fvtt-avd12/archive/fvtt-avd12-v10.0.0.zip",
|
||||
"url": "https://www.uberwald.me/gitea/public/fvtt-avd12",
|
||||
"version": "10.0.11",
|
||||
"download": "https://www.uberwald.me/gitea/public/fvtt-avd12/archive/fvtt-avd12-v10.0.11.zip",
|
||||
"background": "systems/fvtt-avd12/images/ui/avd12_welcome_page.webp"
|
||||
}
|
170
template.json
170
template.json
@ -26,7 +26,24 @@
|
||||
"value": 0,
|
||||
"bonuseffect": 0,
|
||||
"mod": 0,
|
||||
"col": 1
|
||||
"col": 1,
|
||||
"skills": {
|
||||
"athletics": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"block": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"strength": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"agility": {
|
||||
"label": "Agility",
|
||||
@ -34,7 +51,24 @@
|
||||
"value": 0,
|
||||
"bonuseffect": 0,
|
||||
"col": 1,
|
||||
"mod": 0
|
||||
"mod": 0,
|
||||
"skills": {
|
||||
"acrobatics": {
|
||||
"modifier": 0 ,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"stealth": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"dodge": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"willpower": {
|
||||
"label": "Willpower",
|
||||
@ -42,7 +76,24 @@
|
||||
"value": 0,
|
||||
"bonuseffect": 0,
|
||||
"col": 1,
|
||||
"mod": 0
|
||||
"mod": 0,
|
||||
"skills": {
|
||||
"concentration": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"endurance": {
|
||||
"modifier": 0 ,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"resistance": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"knowledge": {
|
||||
"label": "Knowledge",
|
||||
@ -50,7 +101,34 @@
|
||||
"value": 0,
|
||||
"bonuseffect": 0,
|
||||
"col": 1,
|
||||
"mod": 0
|
||||
"mod": 0,
|
||||
"skills": {
|
||||
"wilderness": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"academic": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"arcanum": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"medicine": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"thievery": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"social": {
|
||||
"label": "Social",
|
||||
@ -58,7 +136,43 @@
|
||||
"value": 0,
|
||||
"bonuseffect": 0,
|
||||
"col": 1,
|
||||
"mod": 0
|
||||
"mod": 0,
|
||||
"skills": {
|
||||
"persuasion": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"insight": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"performance": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"animals": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"universal": {
|
||||
"skills": {
|
||||
"search": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
},
|
||||
"initiative": {
|
||||
"modifier": 0,
|
||||
"finalvalue": 0,
|
||||
"good": false
|
||||
}
|
||||
}
|
||||
},
|
||||
"size": {
|
||||
@ -220,7 +334,6 @@
|
||||
},
|
||||
"Item": {
|
||||
"types": [
|
||||
"skill",
|
||||
"spell",
|
||||
"armor",
|
||||
"shield",
|
||||
@ -228,7 +341,12 @@
|
||||
"weapon",
|
||||
"module",
|
||||
"money",
|
||||
"condition"
|
||||
"condition",
|
||||
"action",
|
||||
"freeaction",
|
||||
"reaction",
|
||||
"stance",
|
||||
"trait"
|
||||
],
|
||||
"templates": {
|
||||
"commonitem": {
|
||||
@ -272,19 +390,49 @@
|
||||
"value": 0
|
||||
}
|
||||
},
|
||||
"focus": {
|
||||
"isfocus": false,
|
||||
"core": "",
|
||||
"treatment": "",
|
||||
"bond": ""
|
||||
},
|
||||
"weight": 0,
|
||||
"cost": 0,
|
||||
"health": 0,
|
||||
"movespeed": 0
|
||||
}
|
||||
},
|
||||
"skill": {
|
||||
"attribute": "",
|
||||
"value": 0,
|
||||
"action": {
|
||||
"description": ""
|
||||
},
|
||||
"reaction": {
|
||||
"description": ""
|
||||
},
|
||||
"freeaction": {
|
||||
"description": ""
|
||||
},
|
||||
"stance": {
|
||||
"active": false,
|
||||
"description": ""
|
||||
},
|
||||
"trait": {
|
||||
"traittype": "",
|
||||
"computebonus": false,
|
||||
"bonusdata": "",
|
||||
"bonusvalue": 0,
|
||||
"description": ""
|
||||
},
|
||||
"spell": {
|
||||
"spelltype": "",
|
||||
"actions": "",
|
||||
"chargeeffect": "",
|
||||
"school": "",
|
||||
"damage": "",
|
||||
"damagetype": "",
|
||||
"range": 0,
|
||||
"components": "",
|
||||
"reaction": false,
|
||||
"sustained": false,
|
||||
"level":"",
|
||||
"value": 0,
|
||||
"description": ""
|
||||
@ -294,6 +442,7 @@
|
||||
"commonitem"
|
||||
],
|
||||
"equipped": false,
|
||||
"category": "",
|
||||
"description": ""
|
||||
},
|
||||
"shield": {
|
||||
@ -352,6 +501,7 @@
|
||||
"description": ""
|
||||
},
|
||||
"module": {
|
||||
"levels": [],
|
||||
"description": ""
|
||||
},
|
||||
"condition": {
|
||||
|
@ -9,68 +9,26 @@
|
||||
<div class="flexcol">
|
||||
|
||||
<div class="flexrow">
|
||||
<div class="ability-item">
|
||||
<ul>
|
||||
{{#each system.attributes as |attribute key|}}
|
||||
{{#if (eq attribute.col 1)}}
|
||||
{{> systems/fvtt-crucible-rpg/templates/actors/partial-actor-attribute-block.html attribute=attribute key=key}}
|
||||
{{/if}}
|
||||
{{/each}}
|
||||
</ul>
|
||||
|
||||
<li class="item flexrow list-item" data-attr-key="class">
|
||||
<span class="ability-label " name="class">
|
||||
<h4 class="ability-text-white ability-margin">Class</h4>
|
||||
</span>
|
||||
<select class="competence-base flexrow" type="text" name="system.biodata.class" value="{{data.biodata.class}}" data-dtype="String">
|
||||
{{#select data.biodata.class}}
|
||||
<option value="chaplain">Chaplain</option>
|
||||
<option value="magus">Magus</option>
|
||||
<option value="martial">Martial</option>
|
||||
<option value="skalawag">Skalawag</option>
|
||||
<option value="warden">Warden</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</li>
|
||||
|
||||
</div>
|
||||
{{#each system.attributes as |attr attrKey|}}
|
||||
<div class="flexcol">
|
||||
<div class="flerow">
|
||||
<span>{{attr.label}}</span>
|
||||
<input type="text" class="item-field-label-short" name="system.attributes.{{attrKey}}.value" value="{{attr.value}}" data-dtype="Number"/>
|
||||
</div>
|
||||
{{#each attr.skills as |skill skillKey|}}
|
||||
<div class="flexrow">
|
||||
<span class="item-field-label-medium"><a class="roll-skill" data-attr-key="{{attrKey}}" data-skill-key="{{skillKey}}">{{upperFirst skillKey}} : {{skill.finalvalue}}</a></span>
|
||||
<input type="checkbox" class="skill-good-checkbox" name="system.attributes.{{attrKey}}.skills.{{skillKey}}.good" {{checked skill.good}} />
|
||||
</div>
|
||||
{{/each}}
|
||||
</div>
|
||||
{{/each}}
|
||||
</div>
|
||||
|
||||
<div class="ability-item">
|
||||
<ul>
|
||||
{{#each data.abilities as |ability key|}}
|
||||
{{#if (eq ability.col 2)}}
|
||||
{{> systems/fvtt-crucible-rpg/templates/partial-actor-ability-block.html ability=ability key=key}}
|
||||
{{/if}}
|
||||
{{/each}}
|
||||
|
||||
{{#if equippedArmor}}
|
||||
<li class="item flexrow list-item" data-attr-key="class">
|
||||
<img class="sheet-competence-img" src="{{equippedArmor.img}}" />
|
||||
<span class="ability-label " name="class">
|
||||
<h4 class="ability-text-white ability-margin"><a class="roll-armor-die ability-margin">{{equippedArmor.name}}</a></h4>
|
||||
</span>
|
||||
</li>
|
||||
{{/if}}
|
||||
{{#if equippedShield}}
|
||||
<li class="item flexrow list-item" data-attr-key="class">
|
||||
<img class="sheet-competence-img" src="{{equippedShield.img}}" />
|
||||
<span class="ability-label " name="equippedShield">
|
||||
<h4 class="ability-text-white ability-margin"><a class="roll-shield-die ability-margin">{{equippedShield.name}}</a></h4>
|
||||
</span>
|
||||
</li>
|
||||
{{/if}}
|
||||
<li class="item flexrow list-item" data-attr-key="class">
|
||||
<img class="sheet-competence-img" src="systems/fvtt-crucible-rpg/images/icons/feats/Marksman (Ballistic).webp" />
|
||||
<span class="ability-label " name="rollTarget">
|
||||
<h4 class="ability-text-white ability-margin"><a class="roll-target-die ability-margin">Target Roll</a></h4>
|
||||
</span>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div class="ability-item status-block">
|
||||
{{> systems/fvtt-crucible-rpg/templates/partial-actor-status.html}}
|
||||
</div>
|
||||
|
||||
</div>
|
||||
@ -81,10 +39,13 @@
|
||||
|
||||
{{!-- Sheet Tab Navigation --}}
|
||||
<nav class="sheet-tabs tabs" data-group="primary">
|
||||
<a class="item" data-tab="skills">Skills</a>
|
||||
<a class="item" data-tab="combat">Combat</a>
|
||||
<a class="item" data-tab="lore">Lore</a>
|
||||
<a class="item" data-tab="main">Main</a>
|
||||
<a class="item" data-tab="modules">Modules</a>
|
||||
<a class="item" data-tab="spells">Spells</a>
|
||||
<a class="item" data-tab="moves">Moves</a>
|
||||
<a class="item" data-tab="traits">Traits</a>
|
||||
<a class="item" data-tab="equipment">Equipment</a>
|
||||
<a class="item" data-tab="crafting">Crafting</a>
|
||||
<a class="item" data-tab="biodata">Biography</a>
|
||||
</nav>
|
||||
|
||||
@ -92,7 +53,7 @@
|
||||
<section class="sheet-body">
|
||||
|
||||
{{!-- Skills Tab --}}
|
||||
<div class="tab skills" data-group="primary" data-tab="skills">
|
||||
<div class="tab main" data-group="primary" data-tab="main">
|
||||
|
||||
<ul class="stat-list alternate-list item-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
@ -127,31 +88,20 @@
|
||||
</div>
|
||||
|
||||
{{!-- Combat Tab --}}
|
||||
<div class="tab combat" data-group="primary" data-tab="combat">
|
||||
<div class="tab modules" data-group="primary" data-tab="modules">
|
||||
|
||||
<div class="flexcol">
|
||||
|
||||
<div>
|
||||
<ul class="stat-list alternate-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
<span class="item-name-label-header-long">
|
||||
<h3><label class="items-title-text">Weapons</label></h3>
|
||||
</span>
|
||||
<span class="item-field-label-short">
|
||||
<label class="short-label">Ability</label>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">Range</label>
|
||||
<h3><label class="items-title-text">Modules</label></h3>
|
||||
</span>
|
||||
</li>
|
||||
{{#each equippedWeapons as |weapon key|}}
|
||||
<li class="item flexrow list-item list-item-shadow" data-item-id="{{weapon._id}}">
|
||||
{{#each modules as |module key|}}
|
||||
<li class="item flexrow list-item list-item-shadow" data-item-id="{{module._id}}">
|
||||
<a class="item-edit item-name-img" title="Edit Item"><img class="sheet-competence-img"
|
||||
src="{{weapon.img}}" /></a>
|
||||
<span class="item-name-label-long"><a class ="roll-weapon">{{weapon.name}}</a></span>
|
||||
|
||||
<span class="item-field-label-short">{{weapon.system.ability}}</span>
|
||||
|
||||
<span class="item-field-label-medium">{{perk.system.range}}</span>
|
||||
src="{{module.img}}" /></a>
|
||||
<span class="item-name-label-long"><a class ="item-edit">{{module.name}}</a></span>
|
||||
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
@ -162,84 +112,24 @@
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<ul class="stat-list alternate-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
<span class="item-name-label-header-long">
|
||||
<h3><label class="items-title-text">Feats</label></h3>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">Feature Die?</label>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">SL?</label>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">SL</label>
|
||||
</span>
|
||||
</li>
|
||||
{{#each feats as |feat key|}}
|
||||
<li class="item flexrow list-item list-item-shadow" data-item-id="{{feat._id}}">
|
||||
<a class="item-edit item-name-img" title="Edit Item"><img class="sheet-competence-img"
|
||||
src="{{feat.img}}" /></a>
|
||||
<span class="item-name-label-long">{{feat.name}}</span>
|
||||
|
||||
<span class="item-field-label-medium">{{upperFirst feat.system.isfeatdie}}</span>
|
||||
<span class="item-field-label-medium">{{upperFirst feat.system.issl}}</span>
|
||||
<span class="item-field-label-medium">{{feat.system.sl}}</span>
|
||||
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{/each}}
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<ul class="stat-list alternate-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
<span class="item-name-label-header-long">
|
||||
<h3><label class="items-title-text">Conditions</label></h3>
|
||||
</span>
|
||||
</li>
|
||||
{{#each conditions as |condition key|}}
|
||||
<li class="item flexrow list-item list-item-shadow" data-item-id="{{condition._id}}">
|
||||
<a class="item-edit item-name-img" title="Edit Item"><img class="sheet-competence-img"
|
||||
src="{{condition.img}}" /></a>
|
||||
<span class="item-name-label-long">{{condition.name}}</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{/each}}
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
|
||||
{{!-- Lore Tab --}}
|
||||
<div class="tab lore" data-group="primary" data-tab="lore">
|
||||
{{!-- Spells Tab --}}
|
||||
<div class="tab spells" data-group="primary" data-tab="spells">
|
||||
|
||||
<div class="flexcol">
|
||||
|
||||
<ul class="stat-list alternate-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
<span class="item-name-label-header">
|
||||
<h3><label class="items-title-text">Lore</label></h3>
|
||||
<h3><label class="items-title-text">Name</label></h3>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">Lore</label>
|
||||
</span>
|
||||
<span class="item-field-label-short">
|
||||
<label class="short-label">Circle</label>
|
||||
<label class="short-label">Type</label>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">Range</label>
|
||||
<label class="short-label">Level</label>
|
||||
</span>
|
||||
</li>
|
||||
|
||||
@ -248,11 +138,88 @@
|
||||
<a class="item-edit item-name-img" title="Edit Item"><img class="sheet-competence-img"
|
||||
src="{{spell.img}}" /></a>
|
||||
<span class="item-name-label">
|
||||
<a class="power-roll">{{spell.name}}</a>
|
||||
<a class="spell-roll">{{spell.name}}</a>
|
||||
</span>
|
||||
<span class="item-field-label-medium">{{upperFirst spell.system.lore}}</span>
|
||||
<span class="item-field-label-short">{{upperFirst spell.system.circle}}</span>
|
||||
<span class="item-field-label-medium">{{upperFirst spell.system.range}}</span>
|
||||
<span class="item-field-label-medium">{{upperFirst spell.system.spelltype}}</span>
|
||||
<span class="item-field-label-medium">{{upperFirst spell.system.level}}</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{/each}}
|
||||
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{!-- moves Tab --}}
|
||||
<div class="tab moves" data-group="primary" data-tab="moves">
|
||||
|
||||
<div class="flexcol">
|
||||
|
||||
<ul class="stat-list alternate-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
<span class="item-name-label-header">
|
||||
<h3><label class="items-title-text">Name</label></h3>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">Type</label>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">Level</label>
|
||||
</span>
|
||||
</li>
|
||||
|
||||
{{#each spells as |spell key|}}
|
||||
<li class="item stat flexrow list-item list-item-shadow" data-item-id="{{spell._id}}">
|
||||
<a class="item-edit item-name-img" title="Edit Item"><img class="sheet-competence-img"
|
||||
src="{{spell.img}}" /></a>
|
||||
<span class="item-name-label">
|
||||
<a class="spell-roll">{{spell.name}}</a>
|
||||
</span>
|
||||
<span class="item-field-label-medium">{{upperFirst spell.system.spelltype}}</span>
|
||||
<span class="item-field-label-medium">{{upperFirst spell.system.level}}</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{/each}}
|
||||
|
||||
</ul>
|
||||
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{!-- traits Tab --}}
|
||||
<div class="tab traits" data-group="primary" data-tab="traits">
|
||||
|
||||
<div class="flexcol">
|
||||
|
||||
<ul class="stat-list alternate-list">
|
||||
<li class="item flexrow list-item items-title-bg">
|
||||
<span class="item-name-label-header">
|
||||
<h3><label class="items-title-text">Name</label></h3>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">Type</label>
|
||||
</span>
|
||||
<span class="item-field-label-medium">
|
||||
<label class="short-label">Level</label>
|
||||
</span>
|
||||
</li>
|
||||
|
||||
{{#each traits as |trait key|}}
|
||||
<li class="item stat flexrow list-item list-item-shadow" data-item-id="{{trait._id}}">
|
||||
<a class="item-edit item-name-img" title="Edit Item"><img class="sheet-competence-img"
|
||||
src="{{trait.img}}" /></a>
|
||||
<span class="item-name-label">
|
||||
<a class="spell-roll">{{trait.name}}</a>
|
||||
</span>
|
||||
<span class="item-field-label-medium">{{upperFirst trait.system.spelltype}}</span>
|
||||
<span class="item-field-label-medium">{{upperFirst trait.system.level}}</span>
|
||||
<div class="item-filler"> </div>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
|
||||
|
@ -18,131 +18,22 @@
|
||||
|
||||
<div>
|
||||
<ul>
|
||||
{{#if (eq rollOrder 1)}}
|
||||
<li><strong>Roll with {{rollType}} - Roll 1</strong></li>
|
||||
{{/if}}
|
||||
{{#if (eq rollOrder 2)}}
|
||||
<li><strong>Roll with {{rollType}} - Roll 2</strong></li>
|
||||
{{/if}}
|
||||
{{#if (eq rollOrder 3)}}
|
||||
<li><strong>Roll with {{rollType}} - Final result !</strong></li>
|
||||
{{/if}}
|
||||
|
||||
{{#if save}}
|
||||
<li>Save : {{save.label}} - {{save.value}}d6
|
||||
({{#each roll.terms.0.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if sizeDice}}
|
||||
<li>Size/Range/Cover/Situational dices
|
||||
({{#each roll.terms.0.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if ability}}
|
||||
<li>Ability : {{ability.label}} - {{ability.value}}d6
|
||||
({{#each roll.terms.0.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if skill}}
|
||||
<li>Skill : {{skill.name}} - {{skill.data.skilldice}}
|
||||
{{#if featSL}}
|
||||
- with Feat SL +{{featSL}}
|
||||
{{/if}}
|
||||
({{#each roll.terms.2.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
<li>Skill : {{skill.name}} ({{skill.finalvalue}})
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if noAdvantage}}
|
||||
<li>No advantage due to condition : {{noAdvantage.name}}</li>
|
||||
{{else}}
|
||||
{{#if (or (eq advantage "advantage1") forceAdvantage)}}
|
||||
<li>1 Advantage Die !
|
||||
({{#each roll.terms.8.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
{{#if (eq advantage "advantage2") }}
|
||||
<li>2 Advantage Dice !
|
||||
({{#each roll.terms.8.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
<li>Dice Formula {{diceFormula}} </li>
|
||||
<li>Result {{roll.total}} </li>
|
||||
|
||||
{{#if (ne targetCheck "none")}}
|
||||
{{#if isSuccess}}
|
||||
<li><strong>Success !</strong></li>
|
||||
{{else}}
|
||||
<li><strong>Failure !</strong></li>
|
||||
{{/if}}
|
||||
{{/if}}
|
||||
|
||||
{{#if (or (eq disadvantage "disadvantage1") forceDisadvantage)}}
|
||||
<li>1 Disadvantage Die !
|
||||
({{#each roll.terms.10.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
{{#if (eq disadvantage "disadvantage2")}}
|
||||
<li>2 Disadvantage Dice !
|
||||
({{#each roll.terms.10.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
{{#if (eq rollAdvantage "roll-advantage")}}
|
||||
<li>Roll with Advantage !</li>
|
||||
{{/if}}
|
||||
{{#if (eq rollAdvantage "roll-disadvantage")}}
|
||||
<li>Roll with Disadvantage !</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if skillArmorPenalty}}
|
||||
<li>Armor Penalty : {{skillArmorPenalty}} Disadvantage Dice
|
||||
({{#each roll.terms.12.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if hasBonusDice}}
|
||||
<li>Skill bonus dice : {{hasBonusDice}}
|
||||
({{#each roll.terms.6.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if complexSkillDisadvantage}}
|
||||
<li>Roll with Disadvantage because of Complex Skill at SL 0 !</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if hasFeatDie}}
|
||||
<li>Feat Die : d10
|
||||
({{#each roll.terms.4.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
{{#if useshield}}
|
||||
<li>Shield : {{shield.name}} - {{shield.data.shielddie}}
|
||||
({{#each roll.terms.14.results as |die idx|}}
|
||||
{{die.result}}
|
||||
{{/each}})
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
<li><strong>Number of successes</strong> {{nbSuccess}} </li>
|
||||
|
||||
<!-- <button class="chat-card-button reroll-level-remaining" data-roll-id="{{rollId}}">Reroll</button> -->
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
|
||||
|
@ -8,160 +8,44 @@
|
||||
|
||||
<div class="flexcol">
|
||||
|
||||
{{#if sizeDice}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Size basic dices : </span>
|
||||
<span class="roll-dialog-label">{{sizeDice.nb}}{{sizeDice.dice}}</span>
|
||||
</div>
|
||||
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Distance bonus dice(s) : </span>
|
||||
<select class="status-small-label color-class-common" type="text" id="distanceBonusDice" value="{{distanceBonusDice}}" data-dtype="String" >
|
||||
{{#select distanceBonusDice}}
|
||||
<option value="0">0</option>
|
||||
<option value="1">1</option>
|
||||
<option value="2">2</option>
|
||||
<option value="3">3</option>
|
||||
<option value="4">4</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if hasCover}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Cover : </span>
|
||||
<select class="status-small-label color-class-common" type="text" id="hasCover" value="{{hasCover}}" data-dtype="String" >
|
||||
{{#select hasCover}}
|
||||
<option value="none">None</option>
|
||||
<option value="cover50">Cover at 50% (+1 dice)</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if situational}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Situational : </span>
|
||||
<select class="status-small-label color-class-common" type="text" id="situational" value="{{situational}}" data-dtype="String" >
|
||||
{{#select situational}}
|
||||
<option value="none">None</option>
|
||||
<option value="dodge">Dodge (+1 dice)</option>
|
||||
<option value="prone">Prone (+1 dice)</option>
|
||||
<option value="moving">Moving (+1 dice)</option>
|
||||
<option value="Engaged">Engaged (+1 dice)</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
|
||||
{{#if save}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">{{save.label}} : </span>
|
||||
<span class="roll-dialog-label">{{save.value}}d6</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if ability}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Ability : </span>
|
||||
<span class="roll-dialog-label">{{ability.value}}d6</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if weapon}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Weapon : </span>
|
||||
<span class="roll-dialog-label">{{weapon.name}}</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if shield}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Use shield ? : </span>
|
||||
<span class="roll-dialog-label"><input type="checkbox" id="useshield" name="useshield" {{checked useshield}}/></span>
|
||||
</div>
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">{{shield.name}} : </span>
|
||||
<span class="roll-dialog-label">{{shield.data.shielddie}}</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if skill}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Skill : </span>
|
||||
<span class="roll-dialog-label">{{skill.name}} - {{skill.data.skilldice}}</span>
|
||||
</div>
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Feature die or SL+2? : </span>
|
||||
<span class="roll-dialog-label">{{#if skill.data.isfeatdie}} Yes {{else}} No {{/if}}</span>
|
||||
<span class="roll-dialog-label">{{skill.name}} ({{skill.finalvalue}})</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
{{#if noAdvantage}}
|
||||
<div>
|
||||
<span class="roll-dialog-label">No advantage due to condition : {{noAdvantage.name}}</span>
|
||||
</div>
|
||||
{{else}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Advantage : </span>
|
||||
<select class="status-small-label color-class-common" type="text" id="advantage" value="{{advantage}}" data-dtype="String" >
|
||||
{{#select advantage}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Bonus/Malus : </span>
|
||||
<select id="bonusMalusRoll" name="bonusMalusRoll">
|
||||
{{#select bonusMalusRoll}}
|
||||
<option value="-4">-4</option>
|
||||
<option value="-3">-3</option>
|
||||
<option value="-2">-2</option>
|
||||
<option value="-1">-1</option>
|
||||
<option value="0">0</option>
|
||||
<option value="1">+1</option>
|
||||
<option value="2">+2</option>
|
||||
<option value="3">+3</option>
|
||||
<option value="4">+4</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Target check : </span>
|
||||
<select id="targetCheck" name="targetCheck">
|
||||
{{#select targetCheck}}
|
||||
<option value="none">None</option>
|
||||
<option value="advantage1">1 Advantage</option>
|
||||
<option value="advantage2">2 Advantages</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Disadvantage : </span>
|
||||
<select class="status-small-label color-class-common" type="text" id="disadvantage" value="{{disadvantage}}" data-dtype="String" >
|
||||
{{#select disadvantage}}
|
||||
<option value="none">None</option>
|
||||
<option value="disadvantage1">1 Disadvantage</option>
|
||||
<option value="disadvantage2">2 Disadvantages</option>
|
||||
<option value="5">5 (Trivial)</option>
|
||||
<option value="7">7 (Easy)</option>
|
||||
<option value="10">10 (Regular)</option>
|
||||
<option value="14">14 (Difficult)</option>
|
||||
<option value="20">20 (Heroic)</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</select>
|
||||
</div>
|
||||
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Roll with Advantage/Disadvantage : </span>
|
||||
<select class="status-small-label color-class-common" type="text" id="rollAdvantage" value="{{rollAdvantage}}" data-dtype="String" >
|
||||
{{#select rollAdvantage}}
|
||||
<option value="none">None</option>
|
||||
<option value="roll-advantage">Roll with Advantage</option>
|
||||
<option value="roll-disadvantage">Roll with Disadvantage</option>
|
||||
{{/select}}
|
||||
</select>
|
||||
</div>
|
||||
|
||||
{{#if forceAdvantage}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">1 Advantage from condition : {{forceAdvantage.name}}
|
||||
{{#if advantageFromTarget}} (Provided by targetted actor) {{/if}}
|
||||
</span>
|
||||
</div>
|
||||
{{/if}}
|
||||
{{#if forceDisadvantage}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">1 Disadvantage from condition : {{forceDisadvantage.name}} </span>
|
||||
</div>
|
||||
{{/if}}
|
||||
{{#if forceRollAdvantage}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Roll Advantage from condition : {{forceRollAdvantage.name}} </span>
|
||||
</div>
|
||||
{{/if}}
|
||||
{{#if forceRollDisadvantage}}
|
||||
<div class="flexrow">
|
||||
<span class="roll-dialog-label">Roll Disadvantage from condition : {{forceRollDisadvantage.name}} </span>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
|
||||
</div>
|
||||
|
||||
</form>
|
30
templates/items/item-action-sheet.hbs
Normal file
30
templates/items/item-action-sheet.hbs
Normal file
@ -0,0 +1,30 @@
|
||||
<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-avd12/templates/items/partial-item-nav.hbs}}
|
||||
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-avd12/templates/items/partial-item-description.hbs}}
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
|
||||
<div class="tab" data-group="primary">
|
||||
<ul>
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Selected</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.selected" {{checked system.selected}} />
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</form>
|
@ -21,6 +21,15 @@
|
||||
|
||||
{{> systems/fvtt-avd12/templates/items/partial-common-item-fields.hbs}}
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Armor type</label>
|
||||
<select class="item-field-label-long" type="text" name="system.category" value="{{system.category}}" data-dtype="String">
|
||||
{{#select system.category}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-armor-types.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Equipped</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.equipped" {{checked system.equipped}} />
|
||||
|
30
templates/items/item-freeaction-sheet.hbs
Normal file
30
templates/items/item-freeaction-sheet.hbs
Normal file
@ -0,0 +1,30 @@
|
||||
<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-avd12/templates/items/partial-item-nav.hbs}}
|
||||
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-avd12/templates/items/partial-item-description.hbs}}
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
|
||||
<div class="tab" data-group="primary">
|
||||
<ul>
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Selected</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.selected" {{checked system.selected}} />
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</form>
|
@ -6,21 +6,63 @@
|
||||
</div>
|
||||
</header>
|
||||
|
||||
{{> systems/fvtt-avd12/templates/items/partial-item-nav.hbs}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-item-nav.hbs builder=true}}
|
||||
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-avd12/templates/items/partial-item-description.hbs}}
|
||||
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
|
||||
<div class="tab" data-group="primary">
|
||||
<ul>
|
||||
|
||||
</ul>
|
||||
TODO : The tre of module choices will be displayed here for players, with the "selected" option only
|
||||
</div>
|
||||
|
||||
{{#if isGM}}
|
||||
<div class="tab builder" data-group="primary" data-tab="builder">
|
||||
|
||||
<div class="tab" data-group="primary">
|
||||
<ul>
|
||||
{{#each system.levels as |level index|}}
|
||||
<hr>
|
||||
<li class="flexrow">
|
||||
<h2 class="item-field-label-long">Level {{add index 1}}</h2>
|
||||
</li>
|
||||
|
||||
<ul class="ul-level1">
|
||||
{{#each level.choices as |choice choiceIndex|}}
|
||||
<li class="">
|
||||
<h3 class="item-field-label-long">Level choice {{add choiceIndex 1}}</h3>
|
||||
</li>
|
||||
<li class="item flexrow" data-level-index="{{@../index}}" data-choice-index="{{choiceIndex}}">
|
||||
<div class="drop-module-step">
|
||||
<label>Drop traits/actions/... here !</label>
|
||||
</div>
|
||||
<span class="item-field-label-short"> </span>
|
||||
<label class="item-field-label-short">Selected</label>
|
||||
<input type="checkbox" class="item-field-label-short choice-level-selected" {{checked choice.selected}} />
|
||||
</li>
|
||||
{{#each choice.features as |feature id|}}
|
||||
<li class="flexrow item" data-level-index="{{@../../index}}" data-choice-index="{{choiceIndex}}" data-feature-id="{{feature._id}}" >
|
||||
<label class="item-field-label-long2">{{feature.name}}</label>
|
||||
<div class="item-controls item-controls-fixed">
|
||||
<a class="item-control module-feature-view" title="Edit Feature"><i class="fas fa-edit"></i></a>
|
||||
<a class="item-control module-feature-delete" title="Delete Feature"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
</li>
|
||||
{{/each}}
|
||||
{{/each}}
|
||||
</ul>
|
||||
{{/each}}
|
||||
|
||||
<li class="flexrow item">
|
||||
<button class="chat-card-button add-module-level">Add a level</button>
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
{{/if}}
|
||||
|
||||
</div>
|
||||
|
||||
</section>
|
||||
|
@ -19,18 +19,8 @@
|
||||
<div class="tab" data-group="primary">
|
||||
<ul>
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Attribute</label>
|
||||
<select class="item-field-label-long" type="text" name="system.attribute" value="{{system.attribute}}" data-dtype="String">
|
||||
{{#select system.attribute}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-attributes.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Level</label>
|
||||
<input type="text" class="item-field-label-short" name="system.value" value="{{system.value}}" data-dtype="Number"/>
|
||||
<label class="item-field-label-long">Selected</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.selected" {{checked system.selected}} />
|
||||
</li>
|
||||
|
||||
</ul>
|
@ -25,7 +25,6 @@
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-spell-types.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
@ -37,6 +36,59 @@
|
||||
</select>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Actions</label>
|
||||
<input type="text" class="item-field-label-long2" name="system.actions" value="{{system.actions}}" data-dtype="String"/>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Charge Effect</label>
|
||||
<input type="text" class="item-field-label-long2" name="system.chargeeffect" value="{{system.chargeeffect}}" data-dtype="String"/>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">School</label>
|
||||
<select class="item-field-label-long" type="text" name="system.school" value="{{system.school}}" data-dtype="String">
|
||||
{{#select system.school}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-spell-schools.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Damage</label>
|
||||
<input type="text" class="item-field-label-short" name="system.damage" value="{{system.damage}}" data-dtype="String"/>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Damage Type</label>
|
||||
<select class="item-field-label-long" type="text" name="system.damagetype" value="{{system.damagetype}}" data-dtype="String">
|
||||
{{#select system.damagetype}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-damage-types.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Range</label>
|
||||
<input type="text" class="item-field-label-short" name="system.range" value="{{system.range}}" data-dtype="Number"/>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Components</label>
|
||||
<input type="text" class="item-field-label-long2" name="system.components" value="{{system.components}}" data-dtype="String"/>
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Reaction?</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.reaction" {{checked system.reaction}} />
|
||||
</li>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Sustained?</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.sustained" {{checked system.sustained}} />
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
31
templates/items/item-stance-sheet.hbs
Normal file
31
templates/items/item-stance-sheet.hbs
Normal file
@ -0,0 +1,31 @@
|
||||
<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-avd12/templates/items/partial-item-nav.hbs}}
|
||||
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-avd12/templates/items/partial-item-description.hbs}}
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
|
||||
<div class="tab" data-group="primary">
|
||||
<ul>
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Active</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.active" {{checked system.active}} />
|
||||
</li>
|
||||
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</form>
|
53
templates/items/item-trait-sheet.hbs
Normal file
53
templates/items/item-trait-sheet.hbs
Normal file
@ -0,0 +1,53 @@
|
||||
<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-avd12/templates/items/partial-item-nav.hbs}}
|
||||
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
<section class="sheet-body">
|
||||
|
||||
{{> systems/fvtt-avd12/templates/items/partial-item-description.hbs}}
|
||||
|
||||
<div class="tab details" data-group="primary" data-tab="details">
|
||||
|
||||
<div class="tab" data-group="primary">
|
||||
<ul>
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Bonus automation</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.computebonus" {{checked system.computebonus}} />
|
||||
</li>
|
||||
{{#if system.computebonus}}
|
||||
<li class="flexrow">
|
||||
|
||||
<label class="item-field-label-long">Bonus path</label>
|
||||
<select class="item-field-label-long" type="text" name="system.bonusdata" value="{{system.bonusdata}}" data-dtype="String">
|
||||
{{#select system.bonusdata}}
|
||||
{{#each bonusList as |bonus idx|}}
|
||||
<option value="{{bonus}}">{{bonus}}</option>
|
||||
{{/each}}
|
||||
{{/select}}
|
||||
</select>
|
||||
</li>
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Bonus value</label>
|
||||
<input type="text" class="item-field-label-short" name="system.bonusvalue" value="{{system.bonusvalue}}" data-dtype="Number"/>
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
<li class="flexrow">
|
||||
<label class="item-field-label-long">Selected</label>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.selected" {{checked system.selected}} />
|
||||
</li>
|
||||
</ul>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
</section>
|
||||
</form>
|
@ -90,7 +90,11 @@
|
||||
<label class="item-field-label-long">{{upperFirst key}}</label>
|
||||
<div class="flexrow">
|
||||
<label class="item-field-label-short">Type</label>
|
||||
<input type="text" class="item-field-label-short" name="system.damages.{{key}}.damagetype" value="{{damage.damagetype}}" data-dtype="Number"/>
|
||||
<select class="item-field-label-long" type="text" name="system.damages.{{key}}.damagetype" value="{{system.damagetype}}" data-dtype="String">
|
||||
{{#select system.damagetype}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-damage-types.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
</div>
|
||||
<div class="flexrow">
|
||||
<label class="item-field-label-short">Dice</label>
|
||||
|
@ -91,6 +91,33 @@
|
||||
{{/each}}
|
||||
</li>
|
||||
|
||||
<li class='flexrow'>
|
||||
<h3 class='item-field-label-long'>
|
||||
Focus
|
||||
</h3>
|
||||
<input type="checkbox" class="item-field-label-short" name="system.focus.isfocus" {{checked system.focus.isfocus}} />
|
||||
</li>
|
||||
|
||||
{{#if system.focus.isfocus}}
|
||||
<li class='flexrow'>
|
||||
<select class="item-field-label-long" type="text" name="system.focus.core" value="{{system.focus.core}}" data-dtype="String">
|
||||
{{#select system.focus.core}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-focus-core.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
<select class="item-field-label-long" type="text" name="system.focus.treatment" value="{{system.focus.treatment}}" data-dtype="String">
|
||||
{{#select system.focus.treatment}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-focus-treatment.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
<select class="item-field-label-long" type="text" name="system.focus.bond" value="{{system.focus.bond}}" data-dtype="String">
|
||||
{{#select system.focus.bond}}
|
||||
{{> systems/fvtt-avd12/templates/items/partial-options-focus-bond.hbs}}
|
||||
{{/select}}
|
||||
</select>
|
||||
</li>
|
||||
{{/if}}
|
||||
|
||||
<li class='flexrow'>
|
||||
<h3 class='item-field-label-long'>
|
||||
Various
|
||||
|
@ -2,4 +2,7 @@
|
||||
<nav class="sheet-tabs tabs" data-group="primary">
|
||||
<a class="item" data-tab="description">Description</a>
|
||||
<a class="item" data-tab="details">Details</a>
|
||||
{{#if builder}}
|
||||
<a class="item" data-tab="builder">Builder (GM only)</a>
|
||||
{{/if}}
|
||||
</nav>
|
||||
|
5
templates/items/partial-options-armor-types.hbs
Normal file
5
templates/items/partial-options-armor-types.hbs
Normal file
@ -0,0 +1,5 @@
|
||||
<option value="unarmed">Unarmed</option>
|
||||
<option value="light">Light Armor</option>
|
||||
<option value="medium">Medium Armor</option>
|
||||
<option value="heavy">Heavy Armor</option>
|
||||
<option value="ultraheavy">Ultra-Heavy Armor</option>
|
8
templates/items/partial-options-damage-types.hbs
Normal file
8
templates/items/partial-options-damage-types.hbs
Normal file
@ -0,0 +1,8 @@
|
||||
<option value="physical">Physical</option>
|
||||
<option value="psychic">Psychic</option>
|
||||
<option value="fire">Fire</option>
|
||||
<option value="lightning">Lightning</option>
|
||||
<option value="cold">Cold</option>
|
||||
<option value="dark">Dark</option>
|
||||
<option value="divine">Divine</option>
|
||||
<option value="arcane">Arcane</option>
|
8
templates/items/partial-options-focus-bond.hbs
Normal file
8
templates/items/partial-options-focus-bond.hbs
Normal file
@ -0,0 +1,8 @@
|
||||
<option value="bondnone">Bond: None</option>
|
||||
<option value="bondeasy">Bond: Easy</option>
|
||||
<option value="bondcommon">Bond: Common</option>
|
||||
<option value="bonduncommon">Bond: Uncommon</option>
|
||||
<option value="bondrare">Bond: Rare</option>
|
||||
<option value="bondlegendary">Bond: Legendary</option>
|
||||
<option value="bondmythic">Bond: Mythic</option>
|
||||
<option value="bonddivine">Bond: Divine</option>
|
9
templates/items/partial-options-focus-core.hbs
Normal file
9
templates/items/partial-options-focus-core.hbs
Normal file
@ -0,0 +1,9 @@
|
||||
<option value="corenone">Core: None</option>
|
||||
<option value="core1gp">Core: 1GP</option>
|
||||
<option value="core5gp">Core: 5GP</option>
|
||||
<option value="core50gp">Core: 50GP</option>
|
||||
<option value="core100gp">Core: 100GP</option>
|
||||
<option value="core300gp">Core: 300GP</option>
|
||||
<option value="core500gp">Core: 500GP</option>
|
||||
<option value="core800gp">Core: 800GP</option>
|
||||
<option value="core1000gp">Core: 1000GP</option>
|
9
templates/items/partial-options-focus-treatment.hbs
Normal file
9
templates/items/partial-options-focus-treatment.hbs
Normal file
@ -0,0 +1,9 @@
|
||||
<option value="treatmentnone">Treatment: None</option>
|
||||
<option value="treatment1gp">Treatment: Tin [1 GP]</option>
|
||||
<option value="treatment4gp">Treatment: Copper [4 GP]</option>
|
||||
<option value="treatment20gp">Treatment: Iron [20 GP]</option>
|
||||
<option value="treatment50gp">Treatment: Silver [50 GP]</option>
|
||||
<option value="treatment500gp">Treatment: Gold [500 GP]</option>
|
||||
<option value="treatment1000gp">Treatment: Platinum [1000 GP]</option>
|
||||
<option value="treatment5000gp">Treatment: Mithral [5000 GP]</option>
|
||||
<option value="treatment10000gp">Treatment: Starsteel [10000 GP]</option>
|
12
templates/items/partial-options-spell-schools.hbs
Normal file
12
templates/items/partial-options-spell-schools.hbs
Normal file
@ -0,0 +1,12 @@
|
||||
<option value="abjuration">Abjuration</option>
|
||||
<option value="evocation">Evocation</option>
|
||||
<option value="tansmutation">Transmutation</option>
|
||||
<option value="divine">Divine</option>
|
||||
<option value="druidic">Druidic</option>
|
||||
<option value="necromancy">Necromancy</option>
|
||||
<option value="auguration">Auguration</option>
|
||||
<option value="illusion">Illusion</option>
|
||||
<option value="draconic">Draconic</option>
|
||||
<option value="cosmic">Cosmic</option>
|
||||
<option value="fiend">Fiend</option>
|
||||
<option value="fey">Fey</option>
|
@ -5,3 +5,4 @@
|
||||
<option value="sonic">Sonic</option>
|
||||
<option value="vision">Vision</option>
|
||||
<option value="touchmelee">Touch/Melee Attack</option>
|
||||
<option value="utility">Utility</option>
|
||||
|
@ -1,3 +1,4 @@
|
||||
<option value="unarmed">Unarmed</option>
|
||||
<option value="ranged">Ranged</option>
|
||||
<option value="blunt">Blunt</option>
|
||||
<option value="slash">Slash</option>
|
||||
|
Reference in New Issue
Block a user