Item structure

This commit is contained in:
sladecraven 2022-05-29 17:55:22 +02:00
parent 6ade49ac87
commit 0e7b87738a
13 changed files with 152 additions and 617 deletions

BIN
assets/ui/pc_sheet_bg.webp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 42 KiB

View File

@ -40,10 +40,9 @@ export class MournbladeActorSheet extends ActorSheet {
data: actorData,
effects: this.object.effects.map(e => foundry.utils.deepClone(e.data)),
limited: this.object.limited,
weapons: this.actor.checkAndPrepareWeapons( duplicate(this.actor.getWeapons()) ),
armors: this.actor.checkAndPrepareArmors( duplicate(this.actor.getArmors())),
shields: duplicate(this.actor.getShields()),
equipments: duplicate(this.actor.getEquipments()),
weapons: duplicate(this.actor.getWeapons()),
armors: duplicate(this.actor.getArmors()),
//equipments: duplicate(this.actor.getEquipments()),
options: this.options,
owner: this.document.isOwner,
editScore: this.options.editScore,

View File

@ -59,8 +59,7 @@ export class MournbladeItemSheet extends ItemSheet {
name: objectData.name,
editable: this.isEditable,
cssClass: this.isEditable ? "editable" : "locked",
optionsDiceList: MournbladeUtility.getOptionsDiceList(),
optionsStatusList: MournbladeUtility.getOptionsStatusList(),
attributs: MournbladeUtility.getAttributs(),
data: itemData,
limited: this.object.limited,
options: this.options,
@ -109,45 +108,6 @@ export class MournbladeItemSheet extends ItemSheet {
});
}
/* -------------------------------------------- */
async viewSubitem(ev) {
let field = $(ev.currentTarget).data('type');
let idx = Number($(ev.currentTarget).data('index'));
let itemData = this.object.data.data[field][idx];
if (itemData.name != 'None') {
let spec = await Item.create(itemData, { temporary: true });
spec.data.origin = "embeddedItem";
new MournbladeItemSheet(spec).render(true);
}
}
/* -------------------------------------------- */
async deleteSubitem(ev) {
let field = $(ev.currentTarget).data('type');
let idx = Number($(ev.currentTarget).data('index'));
let oldArray = this.object.data.data[field];
let itemData = this.object.data.data[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({ [`data.${field}`]: newArray });
}
}
/* -------------------------------------------- */
async manageSpec() {
let itemData = this.object.data.data.specialisation[0];
if (itemData.name != 'None') {
let spec = await Item.create(itemData, { temporary: true });
spec.data.origin = "embeddedItem";
new MournbladeItemSheet(spec).render(true);
}
}
/* -------------------------------------------- */
/** @override */
activateListeners(html) {
@ -196,308 +156,10 @@ export class MournbladeItemSheet extends ItemSheet {
}
/* -------------------------------------------- */
async addAbility(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
console.log("ABB", event, item, dataItem)
if (event.toElement.className == 'drop-abilities') {
let abilityArray = duplicate(this.object.data.data.abilities);
abilityArray.push(newItem);
await this.object.update({ 'data.abilities': abilityArray });
}
if (event.toElement.className == 'drop-optionnal-abilities') {
let abilityArray = duplicate(this.object.data.data.optionnalabilities);
abilityArray.push(newItem);
await this.object.update({ 'data.optionnalabilities': abilityArray });
}
}
/* -------------------------------------------- */
async addRacePerk(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
if (event.toElement.className == 'drop-race-perk') {
let perkArray = duplicate(this.object.data.data.perks);
perkArray.push(newItem);
await this.object.update({ 'data.perks': perkArray });
}
}
/* -------------------------------------------- */
async addSpecialisation(item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
let specArray = [newItem];
await this.object.update({ 'data.specialisation': specArray });
}
/* -------------------------------------------- */
async addRoleSpecialisation(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
console.log("Add spec", event, newItem);
if (event.toElement.className == 'drop-spec1') {
let specArray = duplicate(this.object.data.data.specialisationsplus1);
specArray.push(newItem);
await this.object.update({ 'data.specialisationsplus1': specArray });
}
if (event.toElement.className == 'drop-spec2') {
let specArray = duplicate(this.object.data.data.specincrease);
specArray.push(newItem);
await this.object.update({ 'data.specincrease': specArray });
}
}
/* -------------------------------------------- */
async addRolePerk(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
console.log("Add spec", event, newItem);
if (event.toElement.className == 'drop-perk2') {
let perkArray = duplicate(this.object.data.data.perks);
perkArray.push(newItem);
await this.object.update({ 'data.perks': perkArray });
}
if (event.toElement.className == 'drop-specialperk1') {
let perkArray = duplicate(this.object.data.data.specialperk);
perkArray.push(newItem);
await this.object.update({ 'data.specialperk': perkArray });
}
}
/* -------------------------------------------- */
async addPower(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
if (event.toElement.className == 'drop-spec-power') {
let powArray = duplicate(this.object.data.data.powers);
powArray.push(newItem);
await this.object.update({ 'data.powers': powArray });
}
}
/* -------------------------------------------- */
async addAbilityPower(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
if (event.toElement.className == 'drop-ability-power') {
let powArray = duplicate(this.object.data.data.powersgained);
powArray.push(newItem);
await this.object.update({ 'data.powersgained': powArray });
}
}
/* -------------------------------------------- */
async addAbilityEffect(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
if (event.toElement.className == 'drop-ability-effect') {
let powArray = duplicate(this.object.data.data.effectsgained);
powArray.push(newItem);
await this.object.update({ 'data.effectsgained': powArray });
}
}
/* -------------------------------------------- */
async addAbilitySpec(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
if (event.toElement.className == 'drop-ability-spec') {
let powArray = duplicate(this.object.data.data.specialisations);
powArray.push(newItem);
await this.object.update({ 'data.specialisations': powArray });
}
}
/* -------------------------------------------- */
async addAbilityWeaponArmor(event, item, dataItem) {
let newItem = duplicate(item.data);
newItem._id = randomID(dataItem.id.length);
if (event.toElement.className == 'drop-ability-weapon') {
let weaponArray = duplicate(this.object.data.data.attackgained);
weaponArray.push(newItem);
await this.object.update({ 'data.attackgained': weaponArray });
}
if (event.toElement.className == 'drop-ability-armor') {
let armorArray = duplicate(this.object.data.data.armorgained);
armorArray.push(newItem);
await this.object.update({ 'data.armorgained': armorArray });
}
}
/* -------------------------------------------- */
async addPerkSpecialisation(event, item, dataItem) {
let newItem = duplicate(item.data);
if (event.toElement.className == 'drop-spec-perk') {
//console.log("PER SPEC", event)
let key = event.toElement.dataset["key"];
if (key == 'affectedspec') {
await this.object.update({ 'data.features.affectedspec.value': newItem.name });
} else {
await this.object.update({ 'data.features.gainspecdice.value': newItem.name });
}
}
}
/* -------------------------------------------- */
async addPerkEffect(event, item, dataItem) {
let newItem = duplicate(item.data)
if (event.toElement.className == 'drop-perk-effect') {
let effectArray = duplicate(this.object.data.data.effectsgained)
effectArray.push(newItem)
await this.object.update({ 'data.effectsgained': effectArray })
}
}
/* -------------------------------------------- */
async addEffectPower(event, item, dataItem) {
let newItem = duplicate(item.data)
if (event.toElement.className == 'drop-power-effect') {
let effectArray = duplicate(this.object.data.data.effectsgained)
effectArray.push(newItem);
await this.object.update({ 'data.effectsgained': effectArray })
}
}
/* -------------------------------------------- */
async addEffectSpec(event, item, dataItem) {
let newItem = duplicate(item.data);
if (event.toElement.className == 'drop-effect-spec') {
let specArray = duplicate(this.object.data.data.recoveryrollspec);
specArray.push(newItem);
await this.object.update({ 'data.recoveryrollspec': specArray });
}
if (event.toElement.className == 'drop-effect-specaffected') {
let specArray = duplicate(this.object.data.data.specaffected);
specArray.push(newItem);
await this.object.update({ 'data.specaffected': specArray });
}
}
/* -------------------------------------------- */
async addEffectItem(event, item, dataItem) {
let newItem = duplicate(item.data);
if (event.toElement.className == 'drop-equipment-effect') {
let effectArray = duplicate(this.object.data.data.effects);
effectArray.push(newItem);
await this.object.update({ 'data.effects': effectArray });
}
}
/* -------------------------------------------- */
async _onDrop(event) {
if (this.object.type == 'weapon' || this.object.type == 'shield' || this.object.type == 'armor' || this.object.type == 'shield') {
let data = event.dataTransfer.getData('text/plain');
if (data) {
let dataItem = JSON.parse(data);
let item = await MournbladeUtility.searchItem(dataItem);
if (item.data.type == 'effect') {
return this.addEffectItem(event, item, dataItem);
}
}
}
if (this.object.type == 'power') {
let data = event.dataTransfer.getData('text/plain');
if (data) {
let dataItem = JSON.parse(data);
let item = await MournbladeUtility.searchItem(dataItem);
if (item.data.type == 'effect') {
return this.addEffectPower(event, item, dataItem);
}
}
}
if (this.object.type == 'effect') {
let data = event.dataTransfer.getData('text/plain');
if (data) {
let dataItem = JSON.parse(data);
let item = await MournbladeUtility.searchItem(dataItem);
if (item.data.type == 'specialisation') {
return this.addEffectSpec(event, item, dataItem);
}
}
}
if (this.object.type == 'race') {
let data = event.dataTransfer.getData('text/plain');
if (data) {
let dataItem = JSON.parse(data);
let item = await MournbladeUtility.searchItem(dataItem);
if (item.data.type == 'ability') {
return this.addAbility(event, item, dataItem);
}
if (item.data.type == 'perk') {
return this.addRacePerk(event, item, dataItem);
}
}
}
if (this.object.type == 'perk') {
let data = event.dataTransfer.getData('text/plain')
if (data) {
let dataItem = JSON.parse(data);
let item = await MournbladeUtility.searchItem(dataItem)
if (item.data.type == 'specialisation') {
return this.addPerkSpecialisation(event, item, dataItem)
}
if (item.data.type == 'effect') {
return this.addPerkEffect(event, item, dataItem);
}
}
}
if (this.object.type == 'specialisation') {
let data = event.dataTransfer.getData('text/plain');
if (data) {
let dataItem = JSON.parse(data);
let item = await MournbladeUtility.searchItem(dataItem);
if (item.data.type == 'power') {
return this.addPower(event, item, dataItem);
}
}
}
if (this.object.type == 'ability') {
let data = event.dataTransfer.getData('text/plain');
if (data) {
let dataItem = JSON.parse(data);
let item = await MournbladeUtility.searchItem(dataItem);
if (item.data.type == 'effect') {
return this.addAbilityEffect(event, item, dataItem);
}
if (item.data.type == 'power') {
return this.addAbilityPower(event, item, dataItem);
}
if (item.data.type == 'specialisation') {
return this.addAbilitySpec(event, item, dataItem);
}
if (item.data.type == 'weapon' || item.data.type == 'armor') {
return this.addAbilityWeaponArmor(event, item, dataItem);
}
}
}
if (this.object.type == 'role') {
let data = event.dataTransfer.getData('text/plain');
if (data) {
let dataItem = JSON.parse(data);
let item = await MournbladeUtility.searchItem(dataItem);
if (item.data.type == 'specialisation') {
return this.addRoleSpecialisation(event, item, dataItem);
}
if (item.data.type == 'perk') {
return this.addRolePerk(event, item, dataItem);
}
}
}
ui.notifications.warn("This item can not be dropped over another item");
}
/* -------------------------------------------- */
get template() {
let type = this.item.type;
return `systems/fvtt-Mournblade-rpg/templates/item-${type}-sheet.html`;
return `systems/fvtt-mournblade/templates/item-${type}-sheet.html`;
}
/* -------------------------------------------- */

View File

@ -39,6 +39,10 @@ export class MournbladeUtility {
}
/* -------------------------------------------- */
static getAttributs() {
return { adr: "Adresse", pui: "Puissance", cla: "Clairvoyance", pre: "Présence", tre: "Trempe"}
}
/* -------------------------------------------- */
static pushInitiativeOptions(html, options) {
}
@ -82,7 +86,8 @@ export class MournbladeUtility {
static async preloadHandlebarsTemplates() {
const templatePaths = [
'systems/fvtt-mournblade/templates/editor-notes-gm.html'
'systems/fvtt-mournblade/templates/editor-notes-gm.html',
'systems/fvtt-mournblade/templates/partial-item-description.html'
]
return loadTemplates(templatePaths);
}

View File

@ -193,7 +193,7 @@ table {border: 1px solid #7a7971;}
/* Styles limited to foundryvtt-vadentis sheets */
.fvtt-pegasus-rpg .sheet-header {
.fvtt-mournblade .sheet-header {
-webkit-box-flex: 0;
-ms-flex: 0 0 210px;
flex: 0 0 210px;
@ -213,7 +213,7 @@ table {border: 1px solid #7a7971;}
margin-bottom: 10px;
}
.fvtt-pegasus-rpg .sheet-header .profile-img {
.fvtt-mournblade .sheet-header .profile-img {
-webkit-box-flex: 0;
-ms-flex: 0 0 128px;
flex: 0 0 128px;
@ -253,34 +253,34 @@ table {border: 1px solid #7a7971;}
vertical-align: bottom;
}
.fvtt-pegasus-rpg .sheet-header .header-fields {
.fvtt-mournblade .sheet-header .header-fields {
-webkit-box-flex: 1;
-ms-flex: 1;
flex: 1;
}
.fvtt-pegasus-rpg .sheet-header h1.charname {
.fvtt-mournblade .sheet-header h1.charname {
height: 50px;
padding: 0px;
margin: 5px 0;
border-bottom: 0;
}
.fvtt-pegasus-rpg .sheet-header h1.charname input {
.fvtt-mournblade .sheet-header h1.charname input {
width: 100%;
height: 100%;
margin: 0;
}
.fvtt-pegasus-rpg .sheet-tabs {
.fvtt-mournblade .sheet-tabs {
-webkit-box-flex: 0;
-ms-flex: 0;
flex: 0;
}
.fvtt-pegasus-rpg .sheet-body,
.fvtt-pegasus-rpg .sheet-body .tab,
.fvtt-pegasus-rpg .sheet-body .tab .editor {
.fvtt-mournblade .sheet-body,
.fvtt-mournblade .sheet-body .tab,
.fvtt-mournblade .sheet-body .tab .editor {
height: 100%;
font-size: 0.8rem;
}
@ -303,70 +303,70 @@ table {border: 1px solid #7a7971;}
padding: 0 3px;
}
.fvtt-pegasus-rpg .tox .tox-editor-container {
.fvtt-mournblade .tox .tox-editor-container {
background: #fff;
}
.fvtt-pegasus-rpg .tox .tox-edit-area {
.fvtt-mournblade .tox .tox-edit-area {
padding: 0 8px;
}
.fvtt-pegasus-rpg .resource-label {
.fvtt-mournblade .resource-label {
font-weight: bold;
text-transform: uppercase;
}
.fvtt-pegasus-rpg .tabs {
.fvtt-mournblade .tabs {
height: 40px;
border-top: 1px solid #AAA;
border-bottom: 1px solid #AAA;
color: #000000;
}
.fvtt-pegasus-rpg .tabs .item {
.fvtt-mournblade .tabs .item {
line-height: 40px;
font-weight: bold;
}
.fvtt-pegasus-rpg .tabs .item.active {
.fvtt-mournblade .tabs .item.active {
text-decoration: underline;
text-shadow: none;
}
.fvtt-pegasus-rpg .items-list {
.fvtt-mournblade .items-list {
list-style: none;
margin: 1px 0;
padding: 0;
overflow-y: auto;
}
.fvtt-pegasus-rpg .items-list .item-header {
.fvtt-mournblade .items-list .item-header {
font-weight: bold;
}
.fvtt-pegasus-rpg .items-list .item {
.fvtt-mournblade .items-list .item {
height: 30px;
line-height: 24px;
padding: 1px 0;
border-bottom: 1px solid #BBB;
}
.fvtt-pegasus-rpg .items-list .item .item-image {
.fvtt-mournblade .items-list .item .item-image {
-webkit-box-flex: 0;
-ms-flex: 0 0 24px;
flex: 0 0 24px;
margin-right: 5px;
}
.fvtt-pegasus-rpg .items-list .item img {
.fvtt-mournblade .items-list .item img {
display: block;
}
.fvtt-pegasus-rpg .items-list .item-name {
.fvtt-mournblade .items-list .item-name {
margin: 0;
}
.fvtt-pegasus-rpg .items-list .item-controls {
.fvtt-mournblade .items-list .item-controls {
-webkit-box-flex: 0;
-ms-flex: 0 0 86px;
flex: 0 0 86px;
@ -377,10 +377,10 @@ table {border: 1px solid #7a7971;}
/* ======================================== */
/* Sheet */
.window-app.sheet .window-content .sheet-header{
background: url("../images/ui/pc_sheet_bg.webp")
/*background: #011d33 url("../images/ui/fond1.webp") repeat left top;*/
background: url("../assets/ui/pc_sheet_bg.webp")
/*color: rgba(168, 139, 139, 0.5);*/
}
/* background: #011d33 url("../images/ui/fond1.webp") repeat left top;*/
/*color: rgba(168, 139, 139, 0.5);*/
.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-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);
@ -391,7 +391,7 @@ table {border: 1px solid #7a7971;}
.window-app .window-content, .window-app.sheet .window-content .sheet-body{
font-size: 0.8rem;
background: url("../images/ui/pc_sheet_bg.webp") repeat left top;
background: url("../assets/ui/pc_sheet_bg.webp") repeat left top;
}
/* background: rgba(245,245,240,0.6) url("../images/ui/sheet_background.webp") left top;*/

View File

@ -40,9 +40,9 @@
"styles": [
"styles/simple.css"
],
"templateVersion": 1,
"templateVersion": 2,
"title": "Mournblade",
"url": "",
"version": "0.0.1",
"version": "0.0.2",
"background": "./images/ui/mournblade_welcome.webp"
}

View File

@ -102,6 +102,17 @@
},
"types": [ "arme", "competence", "protection", "pacte", "traitchaotique", "monnaie", "don", "tendance", "rune"],
"arme": {
"typearme": "",
"bonusmaniementoff": 0,
"bonusmaniementdef": 0,
"degats": "",
"deuxmains": false,
"courte": 0,
"moyenne": 0,
"longue": 0,
"tr": 0,
"rarete": 0,
"prix": 0,
"templates": [ "base" ]
},
"predilection": {
@ -110,10 +121,17 @@
},
"competence": {
"niveau": 0,
"attribut": "",
"attribut1": "",
"attribut2": "",
"attribut3": "",
"templates": [ "base" ]
},
"protection": {
"typeprotection": "",
"protection": 0,
"bonusmaniementdef": 0,
"rarete": 0,
"prix": 0,
"templates": [ "base" ]
},
"pacte": {
@ -126,12 +144,19 @@
"templates": [ "base" ]
},
"don": {
"allegeance": "",
"prerequis": "",
"sacrifice": "",
"templates": [ "base" ]
},
"tendance": {
"templates": [ "base" ]
},
"rune": {
"formule": "",
"seuil": 0,
"prononcee": "",
"tracee": "",
"templates": [ "base" ]
}
}

View File

@ -1,29 +0,0 @@
<span class="flexrow">
<h4 class="ame-margin ame-subtitle">{{typedata.label}}</h4>
<div class="item-filler">&nbsp;</div>
<span class="ame-checkbox-label">-1<input class="ame-checkbox" type="checkbox" data-ame-key="{{typeame}}"></span>
<span class="ame-checkbox-label">-2<input class="ame-checkbox" type="checkbox" data-ame-key="{{typeame}}"></span>
<span class="ame-checkbox-label">-3<input class="ame-checkbox" type="checkbox" data-ame-key="{{typeame}}"></span>
<input type="text" class="input-numeric-short padd-right status-small-label color-class-common cohesion-input"
name="data.amestype.{{typeame}}.cohesion" value="{{typedata.cohesion}}" data-dtype="Number" {{#unless
@root.editScore}}disabled{{/unless}} /> /
<input type="text" class="input-numeric-short padd-right status-small-label color-class-common cohesion-input"
name="data.amestype.{{typeame}}.cohesionmax" value="{{typedata.cohesionmax}}" data-dtype="Number" {{#unless
@root.editScore}}disabled{{/unless}}>
</span>
<ul class="ame-margin">
{{#each data.ames as |ame key|}}
{{#if (eq ame.type ../typeame)}}
<li class="ame-padding item stat flexrow item-ame-roll" data-attr-key="{{key}}">
<input type="text" class="input-numeric-short padd-right status-small-label color-class-common"
name="data.ames.{{key}}.value" value="{{ame.value}}" data-dtype="Number" {{#unless
@root.editScore}}disabled{{/unless}} />
<span class="ame-label ame-margin" name="{{key}}">
<a class="roll-ame" data-stat-key="{{key}}">{{ame.label}}</a>
</span>
</li>
{{/if}}
{{/each}}
</ul>

View File

@ -1,22 +0,0 @@
{{#each data.paradigmes as |para key|}}
<li class="item stat flexrow" data-attr-key="{{key}}">
<input type="text" class="input-numeric-short padd-right status-small-label color-class-common"
name="data.paradigmes.{{key}}.value" value="{{para.value}}" data-dtype="Number" {{#unless
@root.editScore}}disabled{{/unless}} />
<span class="stat-label stat-margin" name="{{key}}">
{{#if para.editable}}
<h4 class="ame-margin">
<input type="text" class="color-class-common" name="data.paradigmes.{{key}}.label" value="{{para.label}}"
data-dtype="String" {{#unless @root.editScore}}disabled{{/unless}} />
</h4>
{{else}}
<h4 class="ame-margin"><a class="roll-ame ame-margin" data-stat-key="{{key}}">{{para.label}}</a></h4>
{{/if}}
</span>
<input type="checkbox">
</li>
{{/each}}

View File

@ -9,8 +9,11 @@
{{!-- Sheet Tab Navigation --}}
<nav class="sheet-tabs tabs" data-group="primary">
<a class="item" data-tab="principal">Principal</a>
<a class="item" data-tab="ressources">Ressources</a>
<a class="item" data-tab="biodata">Bio</a>
<a class="item" data-tab="competences">Compétences</a>
<a class="item" data-tab="combat">Combat</a>
<a class="item" data-tab="traits">Traits/Pactes</a>
<a class="item" data-tab="equipement">Equipement</a>
<a class="item" data-tab="biodata">Bio&Notes</a>
</nav>
</div>
<img class="profile-img" src="{{img}}" data-edit="img" title="{{name}}" />
@ -21,7 +24,7 @@
{{!-- Sheet Body --}}
<section class="sheet-body">
{{!-- Combat Tab --}}
{{!-- Main Tab --}}
<div class="tab principal" data-group="primary" data-tab="principal">
<div class="flexrow">
@ -29,140 +32,41 @@
<div class="flexrow">
<div class="sheet-box color-bg-ame color-text-ame">
<span class="flexrow">
<img class="ame-icon" src="systems/fvtt-imperium5/images/icons/ame_transparent.webp">
<h4 class="ame-margin title-font">AMES</h4>
<h4 class="ame-margin title-font">Attributs</h4>
</span>
{{>systems/fvtt-imperium5/templates/actor-partial-ames.html typeame="physique" typedata=data.amestype.physique}}
{{>systems/fvtt-imperium5/templates/actor-partial-ames.html typeame="social" typedata=data.amestype.social}}
{{>systems/fvtt-imperium5/templates/actor-partial-ames.html typeame="mental" typedata=data.amestype.mental}}
</div>
{{#each data.attributs as |attr key|}}
<span><label>{{attr.label}}</label><label>{{attr.value}}</label></span>
{{/each}}
</div>
<div class="flexrow">
<div class="sheet-box color-bg-archetype">
<div class="sheet-box color-bg-ame color-text-ame">
<span class="flexrow">
<img class="ame-icon" src="systems/fvtt-imperium5/images/icons/archetype_transparent.webp">
<h4 class="ame-margin title-font">ARCHETYPE</h4>
<h4 class="ame-margin title-font">Bonne Aventure</h4>
</span>
<h4 class="ame-margin"></h4>
<ul>
<li class="item stat flexrow" data-item-id="{{archetype._id}}">
<img class="sheet-competence-img" src="{{archetype.img}}" /></a>
<span class="item-name-label">{{archetype.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
</ul>
<h4 class="ame-margin">Spécialités</h4>
<ul>
{{#each specialites as |spec key|}}
<li class="item stat flexrow " data-item-id="{{spec._id}}">
<img class="sheet-competence-img" src="{{spec.img}}" /></a>
<span class="item-name-label">{{spec.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
<h4 class="ame-margin">Familiarités :</h4>
<ul>
{{#each familiarites as |fami key|}}
<li class="item stat flexrow " data-item-id="{{fami._id}}">
<img class="sheet-competence-img" src="{{fami.img}}" /></a>
<span class="item-name-label">{{fami.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
</div>
<span><label>Base</label><label>{{data.bonneaventure.base}}</label></span>
<span><label>Actuelle</label><label>{{data.bonneaventure.actuelle}}</label></span>
</div>
<div class="flexrow">
<div class="sheet-box color-bg-paradigme">
<div class="sheet-box color-bg-ame color-text-ame">
<span class="flexrow">
<img class="ame-icon" src="systems/fvtt-imperium5/images/icons/paradigme_transparent.webp">
<h4 class="ame-margin title-font">PARADIGMES</h4>
<h4 class="ame-margin title-font">Eclat</h4>
</span>
<ul>
{{> systems/fvtt-imperium5/templates/actor-partial-paradigmes.html}}
</ul>
<span><label>Valeur</label><label>{{data.eclat.value}}</label></span>
</div>
<div class="sheet-box color-bg-archetype">
<div class="sheet-box color-bg-ame color-text-ame">
<span class="flexrow">
<img class="ame-icon" src="systems/fvtt-imperium5/images/icons/nature_transparent.webp">
<h4 class="ame-margin title-font">NATURE PROFONDE</h4>
<h4 class="ame-margin title-font">Expérience</h4>
</span>
<ul>
<li class="item stat flexrow " data-item-id="{{nature._id}}">
<img class="sheet-competence-img" src="{{nature.img}}" />
<span class="item-name-label">{{nature.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
<span><label>Valeur</label><label>{{data.experience.value}}</label></span>
</div>
</li>
</ul>
<h4 class="ame-margin">Traits</h4>
<ul>
{{#each traits as |trait key|}}
<li class="item stat flexrow " data-item-id="{{trait._id}}">
<img class="sheet-competence-img" src="{{trait.img}}" />
<span class="item-name-label">{{trait.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
<h4 class="ame-margin">Symbioses :</h4>
<ul>
{{#each symbioses as |symbiose key|}}
<li class="item stat flexrow " data-item-id="{{symbiose._id}}">
<img class="sheet-competence-img" src="{{symbiose.img}}" />
<span class="item-name-label">{{symbiose.name}}</span>
<div class="item-filler">&nbsp;</div>
<div class="item-controls item-controls-fixed">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-edit"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</div>
</div>
</div>
{{!-- Equipement Tab --}}
<div class="tab ressources" data-group="primary" data-tab="ressources">
{{!-- Competence Tab --}}
<div class="tab competences" data-group="primary" data-tab="competences">
<div class="flexrow">

View File

@ -0,0 +1,56 @@
<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>
{{!-- Sheet Body --}}
<section class="sheet-body">
<div class="flexcol">
<span class="flexrow">
<label class="generic-label">Niveau : </label>
<input type="text" class="padd-right status-small-label color-class-common" name="data.type" value="{{data.type}}"
data-dtype="String" />
</span>
<span class="flexrow">
<label class="generic-label">Attribut 1 : </label>
<select class="status-small-label color-class-common" type="text" name="data.attribut1" value="{{data.attribut1}}" data-dtype="string" >
{{#select data.attribut1}}
{{#each attributs as |attrLabel attrKey|}}
<option value="{{attrKey}}">{{attrLabel}}</option>
{{/each}}
{{/select}}
</select>
</span>
<span class="flexrow">
<label class="generic-label">Attribut 2 : </label>
<select class="status-small-label color-class-common" type="text" name="data.attribut2" value="{{data.attribut2}}" data-dtype="string" >
<option value="none">Aucun</option>
{{#select data.attribut2}}
{{#each attributs as |attrLabel attrKey|}}
<option value="{{attrKey}}">{{attrLabel}}</option>
{{/each}}
{{/select}}
</select>
</span>
<span class="flexrow">
<label class="generic-label">Attribut 3 : </label>
<select class="status-small-label color-class-common" type="text" name="data.attribut3" value="{{data.attribut3}}" data-dtype="string" >
<option value="none">Aucun</option>
{{#select data.attribut3}}
{{#each attributs as |attrLabel attrKey|}}
<option value="{{attrKey}}">{{attrLabel}}</option>
{{/each}}
{{/select}}
</select>
</span>
{{> systems/fvtt-mournblade/templates/partial-item-description.html}}
</div>
</section>
</form>

View File

@ -1,49 +0,0 @@
<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>
{{!-- Sheet Body --}}
<section class="sheet-body">
<div class="flexcol">
{{#if (exists data.type)}}
<span>
<label class="generic-label">Type : </label>
<input type="text" class="padd-right status-small-label color-class-common" name="data.type" value="{{data.type}}"
data-dtype="String" />
</span>
{{/if}}
{{#if (exists data.value)}}
<span>
<label class="generic-label">Valeur : </label>
<input type="text" class="input-numeric-short padd-right status-small-label color-class-common" name="data.value" value="{{data.value}}"
data-dtype="Number" />
</span>
{{/if}}
{{#if (exists data.aide)}}
<span class="generic-label">
<label>Aide : </label>
<input type="text" class="input-numeric-short padd-right status-small-label color-class-common" name="data.aide" value="{{data.aide}}"
data-dtype="Number" />
</span>
{{/if}}
{{#if (exists data.ressource)}}
<span class="generic-label">
<label>Resource : </label>
<input type="text" class="input-numeric-short padd-right status-small-label color-class-common" name="data.ressource" value="{{data.ressource}}"
data-dtype="Number" />
</span>
{{/if}}
{{> systems/fvtt-imperium5/templates/partial-item-description.html}}
</div>
</section>
</form>

View File

@ -1,16 +0,0 @@
<li class="flexrow"><label class="generic-label">Effects</label>
</li>
<li>
<ul class="ul-level1">
<li class="flexrow"><div class="drop-equipment-effect"><label>Drop Effects here !</label></div>
</li>
{{#each data.effects as |effect idx|}}
<li class="flexrow">
<label name="data.effects[{{idx}}].name"><a class="view-subitem" data-type="effects" data-index="{{idx}}">{{effect.name}}</a></label>
<div class="item-controls padd-left">
<a class="item-control delete-subitem padd-left" data-type="effects" data-index="{{idx}}" title="Delete Effect"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/each}}
</ul>
</li>