feat: section Rites chamaniques sur la fiche de personnage
- Nouveau booléen system.identity.chaman (statut de Chaman). - Onglet Totem : case à cocher « Chaman » toujours visible ; quand elle est cochée, la section « Rites chamaniques » apparaît avec la liste des items de type rite maîtrisés (création, édition, suppression en mode édition). - i18n FR/EN (VERMINE.chaman).
This commit is contained in:
@@ -155,6 +155,7 @@
|
|||||||
"level": "Level",
|
"level": "Level",
|
||||||
"experience": "Experience",
|
"experience": "Experience",
|
||||||
"reputation": "Reputation",
|
"reputation": "Reputation",
|
||||||
|
"chaman": "Shaman",
|
||||||
"sheet": {
|
"sheet": {
|
||||||
"description": "Description"
|
"description": "Description"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -161,6 +161,7 @@
|
|||||||
"level": "Niveau",
|
"level": "Niveau",
|
||||||
"experience": "Expérience",
|
"experience": "Expérience",
|
||||||
"reputation": "Réputation",
|
"reputation": "Réputation",
|
||||||
|
"chaman": "Chaman",
|
||||||
"sheet": {
|
"sheet": {
|
||||||
"description": "Description"
|
"description": "Description"
|
||||||
},
|
},
|
||||||
|
|||||||
@@ -65,6 +65,7 @@ export default class VermineCharacterSheetV2 extends VermineBaseActorSheet {
|
|||||||
context.backgrounds = doc.itemTypes.background
|
context.backgrounds = doc.itemTypes.background
|
||||||
context.traumas = doc.itemTypes.trauma
|
context.traumas = doc.itemTypes.trauma
|
||||||
context.evolutions = doc.itemTypes.evolution
|
context.evolutions = doc.itemTypes.evolution
|
||||||
|
context.rites = doc.itemTypes.rite
|
||||||
break
|
break
|
||||||
case "equipment":
|
case "equipment":
|
||||||
context.tab = context.tabs.equipment
|
context.tab = context.tabs.equipment
|
||||||
|
|||||||
@@ -54,6 +54,8 @@ export default class VermineCharacterData extends foundry.abstract.TypeDataModel
|
|||||||
height: new fields.NumberField({ required: true, nullable: false, integer: true, initial: 0 }),
|
height: new fields.NumberField({ required: true, nullable: false, integer: true, initial: 0 }),
|
||||||
weight: new fields.NumberField({ required: true, nullable: false, integer: true, initial: 0 }),
|
weight: new fields.NumberField({ required: true, nullable: false, integer: true, initial: 0 }),
|
||||||
totem: new fields.StringField({ required: true, nullable: false, initial: "" }),
|
totem: new fields.StringField({ required: true, nullable: false, initial: "" }),
|
||||||
|
// Statut de Chaman : débloque l'affichage des Rites chamaniques maîtrisés.
|
||||||
|
chaman: new fields.BooleanField({ required: true, initial: false }),
|
||||||
age: new fields.StringField({ required: true, nullable: false, initial: "15" }),
|
age: new fields.StringField({ required: true, nullable: false, initial: "15" }),
|
||||||
ageType: new fields.NumberField({ required: true, nullable: false, integer: true, initial: 2 }),
|
ageType: new fields.NumberField({ required: true, nullable: false, integer: true, initial: 2 }),
|
||||||
profile: new fields.StringField({ required: true, nullable: false, initial: "" }),
|
profile: new fields.StringField({ required: true, nullable: false, initial: "" }),
|
||||||
|
|||||||
@@ -28,6 +28,11 @@
|
|||||||
|
|
||||||
{{/if}}
|
{{/if}}
|
||||||
|
|
||||||
|
<div class="chaman-toggle flexrow flex-group-center">
|
||||||
|
<label for="identity-chaman">{{ localize 'VERMINE.chaman' }}</label>
|
||||||
|
<input type="checkbox" id="identity-chaman" name="system.identity.chaman" data-dtype="Boolean" {{#if system.identity.chaman}}checked{{/if}} />
|
||||||
|
</div>
|
||||||
|
|
||||||
{{!-- Abstract Items --}}
|
{{!-- Abstract Items --}}
|
||||||
<div class="grid grid-2col">
|
<div class="grid grid-2col">
|
||||||
<div>
|
<div>
|
||||||
@@ -217,5 +222,43 @@
|
|||||||
{{/each}}
|
{{/each}}
|
||||||
</ol>
|
</ol>
|
||||||
</div>
|
</div>
|
||||||
|
{{#if system.identity.chaman}}
|
||||||
|
<div>
|
||||||
|
<h4>
|
||||||
|
<span>{{localize "ITEMS.rites"}}</span>
|
||||||
|
{{#if isEditMode}}
|
||||||
|
<a
|
||||||
|
class="item-control item-create"
|
||||||
|
title="Create item"
|
||||||
|
data-action="create"
|
||||||
|
data-type="rite"><i class="fas fa-plus"></i></a>
|
||||||
|
{{/if}}
|
||||||
|
</h4>
|
||||||
|
<ol class="list-item">
|
||||||
|
{{#each rites as |item id|}}
|
||||||
|
<li class="item flexrow" data-item-id="{{item._id}}">
|
||||||
|
<div class="item-name" style="flex:4;">
|
||||||
|
<a
|
||||||
|
class="item-control item-edit"
|
||||||
|
data-action="edit"
|
||||||
|
data-item-id="{{item._id}}"
|
||||||
|
title="Edit Item">{{item.name}}</a>
|
||||||
|
</div>
|
||||||
|
<div class="item-controls flexrow">
|
||||||
|
{{#if item.system.description}}
|
||||||
|
<i
|
||||||
|
class="fas fa-circle-question"
|
||||||
|
data-tooltip="{{item.system.description}}"></i>
|
||||||
|
{{/if}}
|
||||||
|
{{#if @root.isEditMode}}
|
||||||
|
<a class="item-control item-delete" data-action="delete" data-item-id="{{item._id}}" title="Delete Item"><i
|
||||||
|
class="fas fa-trash"></i></a>
|
||||||
|
{{/if}}
|
||||||
|
</div>
|
||||||
|
</li>
|
||||||
|
{{/each}}
|
||||||
|
</ol>
|
||||||
|
</div>
|
||||||
|
{{/if}}
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|||||||
Reference in New Issue
Block a user