This commit is contained in:
François-Xavier Guillois
2023-09-04 11:17:46 +02:00
parent 5600e37991
commit e1238a1ad1
11 changed files with 139 additions and 89 deletions
+3 -18
View File
@@ -1,21 +1,6 @@
# CHANGELOG
## 0.0.5
- design de la feuille de personnage
## 0.0.4
- dialog box pour lancer les dés
## 0.0.3
- ajout de la variable de setting Mode de Jeu
- lancement des dés pour les compétences des PJ
- affichage de la rareté
## 0.0.2
- Ajout du logo
## 0.0.1
- Création du dépôt
## 0.1.5
- début de mise en forme des feuilles créature et pnj
- possibilité de changer le type de capacité (pour ajouter des capacités de totem)
+17 -15
View File
@@ -92,7 +92,11 @@
"reaction": "Réaction",
"pools":"Réserves",
"gear": "Matériel",
"protection": "Protection"
"protection": "Protection",
"skills": "Compétences",
"pattern": "Gabarit",
"size": "Taille",
"pack": "Groupe"
},
"VERMINE": {
@@ -182,7 +186,7 @@
"will":{ "name": "Volonté"},
"empathy":{ "name": "Empathie"}
},
"SKILLS_LEVELS": {
"SKILL_LEVELS": {
"beginner": "Débutant",
"proficient": "Confirmé",
"expert":"Expert",
@@ -197,19 +201,16 @@
},
"ROLE_LEVELS": {
"minor": "Mineur",
"secondaray": "Secondaire",
"secondary": "Secondaire",
"important":"Important",
"major":"Majeur"
},
"VERMINE.effect_treate": "Create Effect",
"VERMINE.effect_toggle": "Toggle Effect",
"VERMINE.effect_edit": "Edit Effect",
"VERMINE.effect_delete": "Delete Effect",
"VERMINE.Add": "Ajouter",
"PATTERN_LEVELS": {
"insect": "Insecte",
"rat": "Rat",
"dog":"Chien",
"bear":"Ours"
},
"TOTEMS": {
"human": {
"name": "L'Humain",
@@ -347,7 +348,8 @@
"toxics": { "name": "Toxiques"},
"ruins": { "name": "Vestiges"}
},
"VERMINE.sexes.male":"Masculin",
"VERMINE.sexes.female":"Féminin"
"SEXES": {
"male": "Masculin",
"female":"Féminin"
}
}
+19
View File
@@ -48,6 +48,25 @@ VERMINE.RoleLevels = {
4:{ "label":"ROLE_LEVELS.major", "reaction":4, "reaction_bonus":2, "pools":4, "gear":10, "gear_hindrance":2, "protection":3},
}
VERMINE.PatternLevels = {
1:{ "label":"PATTERN_LEVELS.insect", "attack":2, "damage":0, "minorWound":0, "majorWound":0, "deadlyWound":1},
2:{ "label":"PATTERN_LEVELS.rat", "attack":3, "damage":1, "minorWound":0, "majorWound":1, "deadlyWound":1},
3:{ "label":"PATTERN_LEVELS.dog", "attack":4, "damage":3, "minorWound":1, "majorWound":1, "deadlyWound":1},
4:{ "label":"PATTERN_LEVELS.bear", "attack":6, "damage":6, "minorWound":2, "majorWound":2, "deadlyWound":2},
}
VERMINE.SizeLevels = {
1:{ "attack":2, "vigor":1, "minorWound":0, "majorWound":0, "deadlyWound":1},
2:{ "attack":3, "vigor":2, "minorWound":0, "majorWound":1, "deadlyWound":1},
3:{ "attack":4, "vigor":3, "minorWound":1, "majorWound":1, "deadlyWound":1}
}
VERMINE.PackLevels = {
1:{ "attack":1, "damage":1, "minorWound":0, "majorWound":0, "deadlyWound":1},
2:{ "attack":2, "damage":2, "minorWound":2, "majorWound":2, "deadlyWound":2},
3:{ "attack":5, "damage":5, "minorWound":3, "majorWound":3, "deadlyWound":3}
}
VERMINE.abilityCategories = {
"physical": {
"label":"VERMINE.ability_category.physical"
+40 -3
View File
@@ -63,7 +63,7 @@ export const registerHandlebarsHelpers = function () {
// return threat level information
Handlebars.registerHelper('threatLevel', function (property, level, options) {
if (level < 1 || level > 5)
if (level < 1 || level > 4)
return "";
let levelData = CONFIG.VERMINE.ThreatLevels[level];
if (property == 'label'){
@@ -75,7 +75,7 @@ export const registerHandlebarsHelpers = function () {
// return experience level information
Handlebars.registerHelper('experienceLevel', function (property, level, options) {
if (level < 1 || level > 5)
if (level < 1 || level > 4)
return "";
let levelData = CONFIG.VERMINE.ExperienceLevels[level];
if (property == 'label'){
@@ -87,7 +87,7 @@ export const registerHandlebarsHelpers = function () {
// return role level information
Handlebars.registerHelper('roleLevel', function (property, level, options) {
if (level < 1 || level > 5)
if (level < 1 || level > 4)
return "";
let levelData = CONFIG.VERMINE.RoleLevels[level];
if (property == 'label'){
@@ -97,6 +97,43 @@ export const registerHandlebarsHelpers = function () {
}
});
// return pattern level information
Handlebars.registerHelper('patternLevel', function (property, level, options) {
if (level < 1 || level > 4)
return "";
let levelData = CONFIG.VERMINE.PatternLevels[level];
if (property == 'label'){
return (levelData !== undefined) ? game.i18n.localize(levelData[property]) : "";
} else {
return (levelData !== undefined) ? levelData[property] : "";
}
});
// return size level information
Handlebars.registerHelper('sizeLevel', function (property, level, options) {
if (level < 1 || level > 4)
return "";
let levelData = CONFIG.VERMINE.SizeLevels[level];
if (property == 'label'){
return (levelData !== undefined) ? game.i18n.localize(levelData[property]) : "";
} else {
return (levelData !== undefined) ? levelData[property] : "";
}
});
// return pack level information
Handlebars.registerHelper('packLevel', function (property, level, options) {
if (level < 0 || level > 3)
return "";
let levelData = CONFIG.VERMINE.PackLevels[level];
if (property == 'label'){
return (levelData !== undefined) ? game.i18n.localize(levelData[property]) : "";
} else {
return (levelData !== undefined) ? levelData[property] : "";
}
});
// return skill level information
Handlebars.registerHelper('skillLevel', function (property, level, options) {
if (level < 1 || level > 5)
+1 -1
View File
@@ -2,7 +2,7 @@
"id": "vermine2047",
"title": "Vermine 2047",
"description": "The Vermine 2047 system for FoundryVTT!",
"version": "0.1.4",
"version": "0.1.5",
"compatibility": {
"minimum": "10",
"verified": "10.287",
+8 -2
View File
@@ -331,6 +331,7 @@
"npc": {
"templates": ["base"],
"age": 15,
"skills": "",
"threat": {
"value": 1,
"min": 1,
@@ -384,8 +385,8 @@
},
"creature": {
"templates": ["base"],
"age": 15,
"template": {
"skills": "",
"pattern": {
"value": 1,
"min": 1,
"max": 4
@@ -399,6 +400,11 @@
"value": 1,
"min": 1,
"max": 4
},
"pack": {
"value": 0,
"min": 0,
"max": 3
}
}
},
+28 -35
View File
@@ -1,42 +1,39 @@
<form class="{{cssClass}} {{actor.type}} flexcol" autocomplete="off">
<form class="{{cssClass}} {{actor.type}} flexcol form" autocomplete="off">
{{!-- Sheet Header --}}
<header class="sheet-header">
<img class="profile-img" src="{{actor.img}}" data-edit="img" title="{{actor.name}}" height="100" width="100"/>
<div class="header-fields">
<h1 class="charname"><input name="name" type="text" value="{{actor.name}}" placeholder="Name"/></h1>
{{!-- The grid classes are defined in scss/global/_grid.scss. To use,
use both the "grid" and "grid-Ncol" class where "N" can be any number
from 1 to 12 and will create that number of columns. --}}
<div class="resources grid grid-3col">
{{!-- "flex-group-center" is also defined in the _grid.scss file
and it will add a small amount of padding, a border, and will
center all of its child elements content and text. --}}
<h1 class="charname">
<input name="name" type="text" value="{{actor.name}}" placeholder="Nom"/>
</h1>
<div class="resource-content flexrow row text-right">
<label for="system.pack.value" class="resource-label">{{ localize 'ADVERSITY.pack'}}</label>
<input type="number" name="system.pack.value" value="{{system.pack.value}}" data-dtype="Number" min="0" max="3" />
</div>
</div>
<div class="resources grid grid-3col">
<div class="resource flex-group-center">
<label for="system.health.value" class="resource-label">Health</label>
<div class="resource-content flexrow flex-center flex-between">
<input type="text" name="system.health.value" value="{{system.health.value}}" data-dtype="Number"/>
<span> / </span>
<input type="text" name="system.health.max" value="{{system.health.max}}" data-dtype="Number"/>
<label for="system.threat.value" class="resource-label">{{ localize 'ADVERSITY.pattern'}}</label>
<div class="resource-content">
<input type="number" name="system.pattern.value" value="{{system.pattern.value}}" data-dtype="Number" min="1" max="4" />
<span>({{ patternLevel "label" system.pattern.value }})</span>
</div>
</div>
<div class="resource flex-group-center">
<label for="system.power.value" class="resource-label">Power</label>
<div class="resource-content flexrow flex-center flex-between">
<input type="text" name="system.power.value" value="{{system.power.value}}" data-dtype="Number"/>
<span> / </span>
<input type="text" name="system.power.max" value="{{system.power.max}}" data-dtype="Number"/>
<label for="system.experience.value" class="resource-label">{{ localize 'ADVERSITY.size'}}</label>
<div class="resource-content">
<input type="number" name="system.size.value" value="{{system.size.value}}" data-dtype="Number" min="0" max="3" />
</div>
</div>
<div class="resource flex-group-center">
<label for="system.cr" class="resource-label">CR / XP</label>
<div class="resource-content flexrow flex-center flex-between">
<input type="text" name="system.cr" value="{{system.cr}}" data-dtype="Number"/>
<span> / </span>
<input type="text" disabled="true" name="system.xp" value="{{system.xp}}" data-dtype="Number"/>
<label for="system.cr" class="resource-label">{{ localize 'ADVERSITY.role'}}</label>
<div class="resource-content">
<input type="number" name="system.role.value" value="{{system.role.value }}" data-dtype="Number" min="1" max="3"/>
<span>({{ roleLevel "label" system.role.value }})</span>
</div>
</div>
@@ -47,23 +44,19 @@
{{!-- Sheet Tab Navigation --}}
<nav class="sheet-tabs tabs" data-group="primary">
{{!-- Default tab is specified in actor-sheet.mjs --}}
<a class="item" data-tab="description">Description</a>
<a class="item" data-tab="items">Items</a>
<a class="item" data-tab="effects">Effects</a>
<a class="item" data-tab="description">{{ localize 'VERMINE.abilities'}}</a>
<a class="item" data-tab="effects">{{ localize 'VERMINE.combat'}}</a>
</nav>
{{!-- Sheet Body --}}
<section class="sheet-body">
{{!-- Biography Tab --}}
<div class="tab biography" data-group="primary" data-tab="description">
{{!-- If you want TinyMCE editors to output inline rolls when rendered, you need to pass the actor's roll data to the rollData property. --}}
{{editor system.biography target="system.biography" rollData=rollData button=true owner=owner editable=editable}}
</div>
{{!-- Owned Items Tab --}}
<div class="tab items" data-group="primary" data-tab="items">
{{> "systems/vermine2047/templates/actor/parts/actor-items.html"}}
<div class="tab stats" data-group="primary" data-tab="description">
<section class="flexcol col gap-md">
<h4 class="align-center">{{ localize 'IDENTITY.notes'}}</h4>
{{editor system.biography target="system.biography" button=true owner=owner editable=editable}}
</section>
</div>
{{!-- Active Effects Tab --}}
+16 -12
View File
@@ -8,22 +8,25 @@
<div class="resources grid grid-3col">
<div class="resource flex-group-center">
<label for="system.threat.value" class="resource-label">{{ localize 'ADVERSITY.threat'}}</label>
<div class="resource-content flexrow flex-center flex-between">
<input type="number" name="system.threat.value" value="{{system.threat.value}}" data-dtype="Number" min="1" max="4" />
<div class="resource-content">
<input type="number" name="system.threat.value" value="{{system.threat.value}}" data-dtype="Number" min="1" max="4" />
<span>({{ threatLevel "label" system.threat.value }})</span>
</div>
</div>
<div class="resource flex-group-center">
<label for="system.experience.value" class="resource-label">{{ localize 'ADVERSITY.experience'}}</label>
<div class="resource-content flexrow flex-center flex-between">
<div class="resource-content">
<input type="number" name="system.experience.value" value="{{system.experience.value}}" data-dtype="Number" min="1" max="4" />
<span>({{ experienceLevel "label" system.experience.value }})</span>
</div>
</div>
<div class="resource flex-group-center">
<label for="system.cr" class="resource-label">{{ localize 'ADVERSITY.role'}}</label>
<div class="resource-content flexrow flex-center flex-between">
<div class="resource-content">
<input type="number" name="system.role.value" value="{{system.role.value }}" data-dtype="Number" min="1" max="4"/>
<span>({{ roleLevel "label" system.role.value }})</span>
</div>
</div>
@@ -34,24 +37,21 @@
{{!-- Sheet Tab Navigation --}}
<nav class="sheet-tabs tabs" data-group="primary">
{{!-- Default tab is specified in actor-sheet.mjs --}}
<a class="item" data-tab="description">Description</a>
<a class="item" data-tab="items">Items</a>
<a class="item" data-tab="effects">Effects</a>
<a class="item" data-tab="description">{{ localize 'VERMINE.abilities'}}</a>
<a class="item" data-tab="items">{{ localize 'VERMINE.equipment'}}</a>
<a class="item" data-tab="effects">{{ localize 'VERMINE.combat'}}</a>
</nav>
{{!-- Sheet Body --}}
<section class="sheet-body">
{{!-- Biography Tab --}}
<div class="tab biography" data-group="primary" data-tab="description">
<div class="tab stats" data-group="primary" data-tab="description">
<section class="grid grid-3col gap-md">
<div class="mdb">
<h4 class="align-center">{{ localize 'ADVERSITY.threat'}}</h4>
<ul class="unstyled">
<li>{{ localize 'ADVERSITY.attack'}} {{ threatLevel "attack" system.threat.value }}</li>
<li><input type="text" name="system.identity.skills" value="{{ system.identity.skills }}" data-dtype="String"/></li>
<li>{{ localize 'ADVERSITY.damage'}}</li>
<li>{{ localize 'ADVERSITY.weapon'}}</li>
<li>{{ localize 'ADVERSITY.vigor'}} {{ threatLevel "vigor" system.threat.value }}</li>
<li>{{ localize 'ADVERSITY.wounds'}} {{ threatLevel "minorWound" system.threat.value }}/{{ threatLevel "majorWound" system.threat.value }}/{{ threatLevel "deadlyWound" system.threat.value }}</li>
</ul>
@@ -60,6 +60,10 @@
<div class="mdb">
<h4 class="align-center">{{ localize 'ADVERSITY.experience'}}</h4>
<ul class="unstyled">
<li>
<label for="system.skills" class="">{{ localize "ADVERSITY.skills" }}</label>
<input type="text" name="system.skills" value="{{ system.skills }}" data-dtype="String"/>
</li>
<li>{{ localize 'ADVERSITY.action'}} {{ experienceLevel "action" system.experience.value }}</li>
<li>{{ localize 'ADVERSITY.specialties'}} {{ experienceLevel "specialties" system.experience.value }}</li>
<li>{{ localize 'ADVERSITY.rerolls'}} {{ experienceLevel "rerolls" system.experience.value }}</li>
@@ -76,7 +80,7 @@
</ul>
</div>
</section>
<section class="grid grid-1col gap-md">
<section class="flexcol col gap-md">
<h4 class="align-center">{{ localize 'IDENTITY.notes'}}</h4>
{{editor system.biography target="system.biography" button=true owner=owner editable=editable}}
</section>
@@ -48,7 +48,6 @@
<a class="item-control item-edit" title="Edit Item">{{item.name}}</a>
</div>
<div class="item-controls flexrow">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-eye"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
@@ -67,7 +66,6 @@
<a class="item-control item-edit" title="Edit Item">{{item.name}}</a>
</div>
<div class="item-controls flexrow">
<a class="item-control item-edit" title="Edit Item"><i class="fas fa-eye"></i></a>
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
+2
View File
@@ -6,6 +6,7 @@
</h4>
<ol class="list-item">
{{#each abilities as |item id|}}
{{#if (ne item.type 'totem')}}
<li class="item flexrow" data-item-id="{{item._id}}">
<div class="item-name" style="flex:4;">
<a class="item-control item-edit" title="Edit Item">{{item.name}}</a>
@@ -14,6 +15,7 @@
<a class="item-control item-delete" title="Delete Item"><i class="fas fa-trash"></i></a>
</div>
</li>
{{/if}}
{{/each}}
</ol>
</div>
+5 -1
View File
@@ -18,7 +18,11 @@
</div>
<div class="resource">
<label class="resource-label">{{ localize "VERMINE.type"}}</label>
<input type="number" name="system.type" value="{{system.type}}" data-dtype="Number"/>
<select name="system.type" value="{{system.type}}" data-dtype="String">
<option value="character" {{#if (eq system.type "character")}}selected{{/if}}>Personnage</option>
<option value="group" {{#if (eq system.type "group")}}selected{{/if}}>Groupe</option>
<option value="totem" {{#if (eq system.type "totem")}}selected{{/if}}>Totem</option>
</select>
</div>
</aside>
<main class="editor-wrapper" style="flex:10">