Compare commits
21 Commits
| Author | SHA1 | Date |
|---|---|---|
|
|
f03d350768 | |
|
|
4df687637a | |
|
|
c5f752331a | |
|
|
b3e7085f93 | |
|
|
ed945f1311 | |
|
|
794d62f48b | |
|
|
dcaaa4206a | |
|
|
93e2702915 | |
|
|
81ba365c57 | |
|
|
7ffdaa2c4c | |
|
|
51b349e625 | |
|
|
06c7cdc9c0 | |
|
|
0cb17abdd6 | |
|
|
aa141a36e5 | |
|
|
8fccdd9f10 | |
|
|
f4a6c3e835 | |
|
|
a5c611f1f8 | |
|
|
a8f400e090 | |
|
|
1decf3aa34 | |
|
|
c9abbb1c90 | |
|
|
7b746c6bee |
|
|
@ -1,2 +1,3 @@
|
|||
# Ravenous RPG system for Foundry Virtual Tabletop
|
||||
---------------------
|
||||
test
|
||||
|
|
|
|||
|
|
@ -0,0 +1,9 @@
|
|||
# List of tasks at hand
|
||||
* Designer une feuille de perso
|
||||
* Reverse engineer la facon d'utiliser le meta langage de FVTT ou lire la doc, si on est faible
|
||||
* Implementer la feuille en html
|
||||
* Implementer les jets de des
|
||||
* Implementer les items
|
||||
* Implementer la liste d'items (modules?)
|
||||
* Implementer les metiers
|
||||
* Implemnter les classes et listes de compétences (modules ?)
|
||||
|
|
@ -10,8 +10,8 @@ export class SimpleActorSheet extends ActorSheet {
|
|||
/** @inheritdoc */
|
||||
static get defaultOptions() {
|
||||
return foundry.utils.mergeObject(super.defaultOptions, {
|
||||
classes: ["worldbuilding", "sheet", "actor"],
|
||||
template: "systems/worldbuilding/templates/actor-sheet.html",
|
||||
classes: ["vtt_sys_ravenous", "sheet", "actor"],
|
||||
template: "systems/vtt_sys_ravenous/templates/actor-sheet.html",
|
||||
width: 600,
|
||||
height: 600,
|
||||
tabs: [{navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "description"}],
|
||||
|
|
@ -26,7 +26,7 @@ export class SimpleActorSheet extends ActorSheet {
|
|||
getData() {
|
||||
const context = super.getData();
|
||||
EntitySheetHelper.getAttributeData(context.data);
|
||||
context.shorthand = !!game.settings.get("worldbuilding", "macroShorthand");
|
||||
context.shorthand = !!game.settings.get("vtt_sys_ravenous", "macroShorthand");
|
||||
context.systemData = context.data.data;
|
||||
context.dtypes = ATTRIBUTE_TYPES;
|
||||
return context;
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ export class SimpleActor extends Actor {
|
|||
* @type {boolean}
|
||||
*/
|
||||
get isTemplate() {
|
||||
return !!this.getFlag("worldbuilding", "isTemplate");
|
||||
return !!this.getFlag("vtt_sys_ravenous", "isTemplate");
|
||||
}
|
||||
|
||||
/* -------------------------------------------- */
|
||||
|
|
@ -40,7 +40,7 @@ export class SimpleActor extends Actor {
|
|||
|
||||
// Copy the actor's system data
|
||||
const data = this.toObject(false).data;
|
||||
const shorthand = game.settings.get("worldbuilding", "macroShorthand");
|
||||
const shorthand = game.settings.get("vtt_sys_ravenous", "macroShorthand");
|
||||
const formulaAttributes = [];
|
||||
const itemAttributes = [];
|
||||
|
||||
|
|
|
|||
|
|
@ -173,7 +173,7 @@ export class EntitySheetHelper {
|
|||
const button = event.currentTarget;
|
||||
const label = button.closest(".attribute").querySelector(".attribute-label")?.value;
|
||||
const chatLabel = label ?? button.parentElement.querySelector(".attribute-key").value;
|
||||
const shorthand = game.settings.get("worldbuilding", "macroShorthand");
|
||||
const shorthand = game.settings.get("vtt_sys_ravenous", "macroShorthand");
|
||||
|
||||
// Use the actor for rollData so that formulas are always in reference to the parent actor.
|
||||
const rollData = this.actor.getRollData();
|
||||
|
|
@ -537,7 +537,7 @@ export class EntitySheetHelper {
|
|||
|
||||
// Identify the template Actor types
|
||||
const collection = game.collections.get(this.documentName);
|
||||
const templates = collection.filter(a => a.getFlag("worldbuilding", "isTemplate"));
|
||||
const templates = collection.filter(a => a.getFlag("vtt_sys_ravenous", "isTemplate"));
|
||||
const defaultType = this.metadata.types[0];
|
||||
const types = {
|
||||
[defaultType]: game.i18n.localize("SIMPLE.NoTemplate")
|
||||
|
|
@ -547,7 +547,7 @@ export class EntitySheetHelper {
|
|||
}
|
||||
|
||||
// Render the document creation form
|
||||
const useEntity = game.worldbuilding.useEntity;
|
||||
const useEntity = game.vtt_sys_ravenous.useEntity;
|
||||
const template = `templates/sidebar/${useEntity ? "entity" : "document" }-create.html`;
|
||||
const html = await renderTemplate(template, {
|
||||
name: data.name || game.i18n.format("DOCUMENT.New", {type: label}),
|
||||
|
|
@ -576,7 +576,7 @@ export class EntitySheetHelper {
|
|||
if ( template ) {
|
||||
createData = foundry.utils.mergeObject(template.toObject(), createData);
|
||||
createData.type = template.data.type;
|
||||
delete createData.flags.worldbuilding.isTemplate;
|
||||
delete createData.flags.vtt_sys_ravenous.isTemplate;
|
||||
}
|
||||
|
||||
// Merge provided override data
|
||||
|
|
|
|||
|
|
@ -10,8 +10,8 @@ export class SimpleItemSheet extends ItemSheet {
|
|||
/** @inheritdoc */
|
||||
static get defaultOptions() {
|
||||
return foundry.utils.mergeObject(super.defaultOptions, {
|
||||
classes: ["worldbuilding", "sheet", "item"],
|
||||
template: "systems/worldbuilding/templates/item-sheet.html",
|
||||
classes: ["vtt_sys_ravenous", "sheet", "item"],
|
||||
template: "systems/vtt_sys_ravenous/templates/item-sheet.html",
|
||||
width: 520,
|
||||
height: 480,
|
||||
tabs: [{navSelector: ".sheet-tabs", contentSelector: ".sheet-body", initial: "description"}],
|
||||
|
|
|
|||
|
|
@ -28,6 +28,6 @@ export class SimpleItem extends Item {
|
|||
* @type {boolean}
|
||||
*/
|
||||
get isTemplate() {
|
||||
return !!this.getFlag("worldbuilding", "isTemplate");
|
||||
return !!this.getFlag("vtt_sys_ravenous", "isTemplate");
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,11 +1,11 @@
|
|||
/**
|
||||
* Create a Macro from an attribute drop.
|
||||
* Get an existing worldbuilding macro if one exists, otherwise create a new one.
|
||||
* Get an existing vtt_sys_ravenous macro if one exists, otherwise create a new one.
|
||||
* @param {Object} data The dropped data
|
||||
* @param {number} slot The hotbar slot to use
|
||||
* @returns {Promise}
|
||||
*/
|
||||
export async function createWorldbuildingMacro(data, slot) {
|
||||
export async function createvtt_sys_ravenousMacro(data, slot) {
|
||||
if ( !data.roll || !data.label ) return false;
|
||||
const command = `const roll = new Roll("${data.roll}", actor ? actor.getRollData() : {});
|
||||
roll.toMessage({speaker, flavor: "${data.label}"});`;
|
||||
|
|
@ -15,7 +15,7 @@ export async function createWorldbuildingMacro(data, slot) {
|
|||
name: data.label,
|
||||
type: "script",
|
||||
command: command,
|
||||
flags: { "worldbuilding.attrMacro": true }
|
||||
flags: { "vtt_sys_ravenous.attrMacro": true }
|
||||
});
|
||||
}
|
||||
game.user.assignHotbarMacro(macro, slot);
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@ import { SimpleItem } from "./item.js";
|
|||
import { SimpleItemSheet } from "./item-sheet.js";
|
||||
import { SimpleActorSheet } from "./actor-sheet.js";
|
||||
import { preloadHandlebarsTemplates } from "./templates.js";
|
||||
import { createWorldbuildingMacro } from "./macro.js";
|
||||
import { createvtt_sys_ravenousMacro } from "./macro.js";
|
||||
import { SimpleToken, SimpleTokenDocument } from "./token.js";
|
||||
|
||||
/* -------------------------------------------- */
|
||||
|
|
@ -20,7 +20,7 @@ import { SimpleToken, SimpleTokenDocument } from "./token.js";
|
|||
* Init hook.
|
||||
*/
|
||||
Hooks.once("init", async function() {
|
||||
console.log(`Initializing Simple Worldbuilding System`);
|
||||
console.log(`Initializing Simple vtt_sys_ravenous System`);
|
||||
|
||||
/**
|
||||
* Set an initiative formula for the system. This will be updated later.
|
||||
|
|
@ -31,9 +31,9 @@ Hooks.once("init", async function() {
|
|||
decimals: 2
|
||||
};
|
||||
|
||||
game.worldbuilding = {
|
||||
game.vtt_sys_ravenous = {
|
||||
SimpleActor,
|
||||
createWorldbuildingMacro,
|
||||
createvtt_sys_ravenousMacro,
|
||||
useEntity: foundry.utils.isNewerVersion("9", game.version ?? game.data.version)
|
||||
};
|
||||
|
||||
|
|
@ -45,12 +45,12 @@ Hooks.once("init", async function() {
|
|||
|
||||
// Register sheet application classes
|
||||
Actors.unregisterSheet("core", ActorSheet);
|
||||
Actors.registerSheet("worldbuilding", SimpleActorSheet, { makeDefault: true });
|
||||
Actors.registerSheet("vtt_sys_ravenous", SimpleActorSheet, { makeDefault: true });
|
||||
Items.unregisterSheet("core", ItemSheet);
|
||||
Items.registerSheet("worldbuilding", SimpleItemSheet, { makeDefault: true });
|
||||
Items.registerSheet("vtt_sys_ravenous", SimpleItemSheet, { makeDefault: true });
|
||||
|
||||
// Register system settings
|
||||
game.settings.register("worldbuilding", "macroShorthand", {
|
||||
game.settings.register("vtt_sys_ravenous", "macroShorthand", {
|
||||
name: "SETTINGS.SimpleMacroShorthandN",
|
||||
hint: "SETTINGS.SimpleMacroShorthandL",
|
||||
scope: "world",
|
||||
|
|
@ -60,7 +60,7 @@ Hooks.once("init", async function() {
|
|||
});
|
||||
|
||||
// Register initiative setting.
|
||||
game.settings.register("worldbuilding", "initFormula", {
|
||||
game.settings.register("vtt_sys_ravenous", "initFormula", {
|
||||
name: "SETTINGS.SimpleInitFormulaN",
|
||||
hint: "SETTINGS.SimpleInitFormulaL",
|
||||
scope: "world",
|
||||
|
|
@ -71,7 +71,7 @@ Hooks.once("init", async function() {
|
|||
});
|
||||
|
||||
// Retrieve and assign the initiative formula setting.
|
||||
const initFormula = game.settings.get("worldbuilding", "initFormula");
|
||||
const initFormula = game.settings.get("vtt_sys_ravenous", "initFormula");
|
||||
_simpleUpdateInit(initFormula);
|
||||
|
||||
/**
|
||||
|
|
@ -102,13 +102,13 @@ Hooks.once("init", async function() {
|
|||
/**
|
||||
* Macrobar hook.
|
||||
*/
|
||||
Hooks.on("hotbarDrop", (bar, data, slot) => createWorldbuildingMacro(data, slot));
|
||||
Hooks.on("hotbarDrop", (bar, data, slot) => createvtt_sys_ravenousMacro(data, slot));
|
||||
|
||||
/**
|
||||
* Adds the actor template context menu.
|
||||
*/
|
||||
Hooks.on("getActorDirectoryEntryContext", (html, options) => {
|
||||
const idAttr = game.worldbuilding.useEntity ? "entityId" : "documentId";
|
||||
const idAttr = game.vtt_sys_ravenous.useEntity ? "entityId" : "documentId";
|
||||
// Define an actor as a template.
|
||||
options.push({
|
||||
name: game.i18n.localize("SIMPLE.DefineTemplate"),
|
||||
|
|
@ -119,7 +119,7 @@ Hooks.on("getActorDirectoryEntryContext", (html, options) => {
|
|||
},
|
||||
callback: li => {
|
||||
const actor = game.actors.get(li.data(idAttr));
|
||||
actor.setFlag("worldbuilding", "isTemplate", true);
|
||||
actor.setFlag("vtt_sys_ravenous", "isTemplate", true);
|
||||
}
|
||||
});
|
||||
|
||||
|
|
@ -133,7 +133,7 @@ Hooks.on("getActorDirectoryEntryContext", (html, options) => {
|
|||
},
|
||||
callback: li => {
|
||||
const actor = game.actors.get(li.data(idAttr));
|
||||
actor.setFlag("worldbuilding", "isTemplate", false);
|
||||
actor.setFlag("vtt_sys_ravenous", "isTemplate", false);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
|
@ -142,7 +142,7 @@ Hooks.on("getActorDirectoryEntryContext", (html, options) => {
|
|||
* Adds the item template context menu.
|
||||
*/
|
||||
Hooks.on("getItemDirectoryEntryContext", (html, options) => {
|
||||
const idAttr = game.worldbuilding.useEntity ? "entityId" : "documentId";
|
||||
const idAttr = game.vtt_sys_ravenous.useEntity ? "entityId" : "documentId";
|
||||
// Define an item as a template.
|
||||
options.push({
|
||||
name: game.i18n.localize("SIMPLE.DefineTemplate"),
|
||||
|
|
@ -153,7 +153,7 @@ Hooks.on("getItemDirectoryEntryContext", (html, options) => {
|
|||
},
|
||||
callback: li => {
|
||||
const item = game.items.get(li.data(idAttr));
|
||||
item.setFlag("worldbuilding", "isTemplate", true);
|
||||
item.setFlag("vtt_sys_ravenous", "isTemplate", true);
|
||||
}
|
||||
});
|
||||
|
||||
|
|
@ -167,7 +167,7 @@ Hooks.on("getItemDirectoryEntryContext", (html, options) => {
|
|||
},
|
||||
callback: li => {
|
||||
const item = game.items.get(li.data(idAttr));
|
||||
item.setFlag("worldbuilding", "isTemplate", false);
|
||||
item.setFlag("vtt_sys_ravenous", "isTemplate", false);
|
||||
}
|
||||
});
|
||||
});
|
||||
|
|
|
|||
|
|
@ -8,8 +8,8 @@ export const preloadHandlebarsTemplates = async function() {
|
|||
// Define template paths to load
|
||||
const templatePaths = [
|
||||
// Attribute list partial.
|
||||
"systems/worldbuilding/templates/parts/sheet-attributes.html",
|
||||
"systems/worldbuilding/templates/parts/sheet-groups.html"
|
||||
"systems/vtt_sys_ravenous/templates/parts/sheet-attributes.html",
|
||||
"systems/vtt_sys_ravenous/templates/parts/sheet-groups.html"
|
||||
];
|
||||
|
||||
// Load the template parts
|
||||
|
|
|
|||
|
|
@ -1,7 +1,7 @@
|
|||
{
|
||||
"name": "worldbuilding",
|
||||
"name": "vtt_sys_ravenous",
|
||||
"version": "1.0.0",
|
||||
"description": "CSS compiler for the Worldbuilding system",
|
||||
"description": "CSS compiler for the vtt_sys_ravenous system",
|
||||
"scripts": {
|
||||
"css": "gulp css",
|
||||
"watch": "gulp",
|
||||
|
|
|
|||
|
|
@ -1,18 +1,18 @@
|
|||
.worldbuilding {
|
||||
.vtt_sys_ravenous {
|
||||
/* Sheet Tabs */
|
||||
/* Items List */
|
||||
/* Attributes */
|
||||
}
|
||||
.worldbuilding .window-content {
|
||||
.vtt_sys_ravenous .window-content {
|
||||
height: 100%;
|
||||
padding: 5px;
|
||||
overflow-y: hidden;
|
||||
}
|
||||
.worldbuilding form {
|
||||
.vtt_sys_ravenous form {
|
||||
height: 100%;
|
||||
}
|
||||
.worldbuilding .sheet-header {
|
||||
flex: 0 0 100px;
|
||||
.vtt_sys_ravenous .sheet-header {
|
||||
flex: 0 0 auto;
|
||||
overflow: hidden;
|
||||
display: flex;
|
||||
flex-direction: row;
|
||||
|
|
@ -20,85 +20,94 @@
|
|||
justify-content: flex-start;
|
||||
margin-bottom: 10px;
|
||||
}
|
||||
.worldbuilding .sheet-header .profile-img {
|
||||
flex: 0 0 100px;
|
||||
height: 100px;
|
||||
.vtt_sys_ravenous .sheet-header .header-container {
|
||||
display: grid;
|
||||
grid-template: "a a a" auto "b c d" auto / fit-content(100%) auto auto;
|
||||
}
|
||||
|
||||
.vtt_sys_ravenous .sheet-header .header-container .pc-name {
|
||||
width: 160px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.worldbuilding .sheet-header .header-fields {
|
||||
flex: 1;
|
||||
height: 100px;
|
||||
|
||||
.vtt_sys_ravenous .sheet-header .header-container .caracs {
|
||||
display: grid;
|
||||
grid-area: b;
|
||||
grid-template: "a a a a" "b b c c" "d d e e" "f f g g" "h h i i" / 30px 50px 30px 50px;
|
||||
}
|
||||
.worldbuilding .sheet-header h1.charname {
|
||||
height: 50px;
|
||||
padding: 0px;
|
||||
margin: 5px 0;
|
||||
border-bottom: 0;
|
||||
|
||||
.vtt_sys_ravenous .sheet-header .header-container .caracs .caracs-header {
|
||||
grid-area: a;
|
||||
align-self: center;
|
||||
justify-self: center;
|
||||
text-decoration: underline;
|
||||
}
|
||||
.worldbuilding .sheet-header h1.charname input {
|
||||
width: 100%;
|
||||
height: 100%;
|
||||
margin: 0;
|
||||
.vtt_sys_ravenous .sheet-header .header-container .caracs input {
|
||||
width: 35px;
|
||||
}
|
||||
.worldbuilding .resource {
|
||||
|
||||
.vtt_sys_ravenous .sheet-header .header-container .caracs label {
|
||||
}
|
||||
|
||||
.vtt_sys_ravenous .resource {
|
||||
width: 50%;
|
||||
height: 40px;
|
||||
margin-top: 10px;
|
||||
float: left;
|
||||
text-align: center;
|
||||
}
|
||||
.worldbuilding .resource input {
|
||||
.vtt_sys_ravenous .resource input {
|
||||
width: 100px;
|
||||
height: 28px;
|
||||
}
|
||||
.worldbuilding .tabs {
|
||||
.vtt_sys_ravenous .tabs {
|
||||
flex: 0 0 40px;
|
||||
border-top: 1px solid #AAA;
|
||||
border-bottom: 1px solid #AAA;
|
||||
}
|
||||
.worldbuilding .tabs .item {
|
||||
.vtt_sys_ravenous .tabs .item {
|
||||
line-height: 40px;
|
||||
font-weight: bold;
|
||||
}
|
||||
.worldbuilding .tabs .item.active {
|
||||
.vtt_sys_ravenous .tabs .item.active {
|
||||
text-decoration: underline;
|
||||
text-shadow: none;
|
||||
}
|
||||
.worldbuilding .sheet-body {
|
||||
.vtt_sys_ravenous .sheet-body {
|
||||
overflow: hidden;
|
||||
}
|
||||
.worldbuilding .sheet-body .tab {
|
||||
.vtt_sys_ravenous .sheet-body .tab {
|
||||
height: 100%;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.worldbuilding .editor,
|
||||
.worldbuilding .editor-content {
|
||||
.vtt_sys_ravenous .editor,
|
||||
.vtt_sys_ravenous .editor-content {
|
||||
height: 100%;
|
||||
}
|
||||
.worldbuilding .item-list {
|
||||
.vtt_sys_ravenous .item-list {
|
||||
list-style: none;
|
||||
margin: 7px 0;
|
||||
padding: 0;
|
||||
overflow-y: auto;
|
||||
}
|
||||
.worldbuilding .item-list .item {
|
||||
.vtt_sys_ravenous .item-list .item {
|
||||
min-height: 30px;
|
||||
line-height: 24px;
|
||||
padding: 3px 0;
|
||||
border-bottom: 1px solid #BBB;
|
||||
align-items: stretch;
|
||||
}
|
||||
.worldbuilding .item-list .item img {
|
||||
.vtt_sys_ravenous .item-list .item img {
|
||||
flex: 0 0 24px;
|
||||
margin-right: 5px;
|
||||
}
|
||||
.worldbuilding .item-list .item-name {
|
||||
.vtt_sys_ravenous .item-list .item-name {
|
||||
margin: 0;
|
||||
}
|
||||
.worldbuilding .item-list .item-controls {
|
||||
.vtt_sys_ravenous .item-list .item-controls {
|
||||
flex: 0 0 36px;
|
||||
}
|
||||
.worldbuilding .item-list .item-buttons {
|
||||
.vtt_sys_ravenous .item-list .item-buttons {
|
||||
display: flex;
|
||||
flex-wrap: wrap;
|
||||
flex-direction: row;
|
||||
|
|
@ -106,23 +115,23 @@
|
|||
flex: 2;
|
||||
justify-content: flex-start;
|
||||
}
|
||||
.worldbuilding .item-list .item-button {
|
||||
.vtt_sys_ravenous .item-list .item-button {
|
||||
line-height: 1;
|
||||
font-size: 11px;
|
||||
flex: none;
|
||||
width: auto;
|
||||
}
|
||||
.worldbuilding .attributes {
|
||||
.vtt_sys_ravenous .attributes {
|
||||
position: relative;
|
||||
}
|
||||
.worldbuilding .attributes .attribute-control,
|
||||
.worldbuilding .attributes .group-control {
|
||||
.vtt_sys_ravenous .attributes .attribute-control,
|
||||
.vtt_sys_ravenous .attributes .group-control {
|
||||
flex: 0 0 20px;
|
||||
text-align: center;
|
||||
line-height: 28px;
|
||||
border: none;
|
||||
}
|
||||
.worldbuilding .attributes .attribute-roll {
|
||||
.vtt_sys_ravenous .attributes .attribute-roll {
|
||||
flex: 0 0 20px;
|
||||
text-align: center;
|
||||
border-bottom: none;
|
||||
|
|
@ -130,11 +139,11 @@
|
|||
align-items: center;
|
||||
justify-content: center;
|
||||
}
|
||||
.worldbuilding .attributes .group-prefix {
|
||||
.vtt_sys_ravenous .attributes .group-prefix {
|
||||
height: 31px;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.worldbuilding .attributes .button {
|
||||
.vtt_sys_ravenous .attributes .button {
|
||||
width: 100%;
|
||||
flex: 1;
|
||||
margin: 0;
|
||||
|
|
@ -145,11 +154,11 @@
|
|||
line-height: 28px;
|
||||
display: block;
|
||||
}
|
||||
.worldbuilding .attributes .attribute-key {
|
||||
.vtt_sys_ravenous .attributes .attribute-key {
|
||||
background: transparent;
|
||||
border: none;
|
||||
}
|
||||
.worldbuilding .attributes-header {
|
||||
.vtt_sys_ravenous .attributes-header {
|
||||
position: sticky;
|
||||
top: 0;
|
||||
left: 0;
|
||||
|
|
@ -162,12 +171,12 @@
|
|||
text-align: left;
|
||||
font-weight: bold;
|
||||
}
|
||||
.worldbuilding .attributes-list {
|
||||
.vtt_sys_ravenous .attributes-list {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.worldbuilding .attributes-list li > * {
|
||||
.vtt_sys_ravenous .attributes-list li > * {
|
||||
margin: 0 3px;
|
||||
height: 28px;
|
||||
line-height: 24px;
|
||||
|
|
@ -176,47 +185,47 @@
|
|||
border-radius: 0;
|
||||
border-bottom: 1px solid #AAA;
|
||||
}
|
||||
.worldbuilding .attributes-list .attribute-col label {
|
||||
.vtt_sys_ravenous .attributes-list .attribute-col label {
|
||||
font-size: 10px;
|
||||
text-align: center;
|
||||
line-height: 1;
|
||||
}
|
||||
.worldbuilding .attributes-list .attribute-col input {
|
||||
.vtt_sys_ravenous .attributes-list .attribute-col input {
|
||||
font-size: 11px;
|
||||
text-align: center;
|
||||
line-height: 1;
|
||||
height: 50%;
|
||||
}
|
||||
.worldbuilding .attribute input[type="text"]::placeholder,
|
||||
.worldbuilding .group-header input[type="text"]::placeholder {
|
||||
.vtt_sys_ravenous .attribute input[type="text"]::placeholder,
|
||||
.vtt_sys_ravenous .group-header input[type="text"]::placeholder {
|
||||
opacity: 0;
|
||||
transition: opacity 0.25s ease-in-out;
|
||||
}
|
||||
.worldbuilding .attribute input[type="text"]:focus::placeholder,
|
||||
.worldbuilding .group-header input[type="text"]:focus::placeholder {
|
||||
.vtt_sys_ravenous .attribute input[type="text"]:focus::placeholder,
|
||||
.vtt_sys_ravenous .group-header input[type="text"]:focus::placeholder {
|
||||
opacity: 1;
|
||||
}
|
||||
.worldbuilding .group-controls {
|
||||
.vtt_sys_ravenous .group-controls {
|
||||
margin: 5px;
|
||||
}
|
||||
.worldbuilding .groups-list {
|
||||
.vtt_sys_ravenous .groups-list {
|
||||
list-style: none;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
.worldbuilding .group {
|
||||
.vtt_sys_ravenous .group {
|
||||
margin: 5px 0 0;
|
||||
padding: 0;
|
||||
}
|
||||
.worldbuilding .group-header {
|
||||
.vtt_sys_ravenous .group-header {
|
||||
align-items: center;
|
||||
background: rgba(0, 0, 0, 0.05);
|
||||
border: 1px solid #AAA;
|
||||
border-radius: 2px;
|
||||
padding: 2px 5px;
|
||||
}
|
||||
.worldbuilding .group-key,
|
||||
.worldbuilding .group-label {
|
||||
.vtt_sys_ravenous .group-key,
|
||||
.vtt_sys_ravenous .group-label {
|
||||
font-weight: bold;
|
||||
border: none;
|
||||
border-bottom: 1px solid #AAA;
|
||||
|
|
@ -224,22 +233,22 @@
|
|||
border-radius: 0;
|
||||
margin-right: 6px;
|
||||
}
|
||||
.worldbuilding .group-key {
|
||||
.vtt_sys_ravenous .group-key {
|
||||
opacity: 0.75;
|
||||
}
|
||||
.worldbuilding .group-label {
|
||||
.vtt_sys_ravenous .group-label {
|
||||
flex: 2;
|
||||
}
|
||||
.worldbuilding .group-dtype {
|
||||
.vtt_sys_ravenous .group-dtype {
|
||||
height: 24px;
|
||||
flex: 0 0 116px;
|
||||
margin: 0 5px;
|
||||
}
|
||||
.worldbuilding.sheet.actor {
|
||||
.vtt_sys_ravenous.sheet.actor {
|
||||
min-width: 560px;
|
||||
min-height: 420px;
|
||||
}
|
||||
.worldbuilding.sheet.item {
|
||||
.vtt_sys_ravenous.sheet.item {
|
||||
min-width: 460px;
|
||||
min-height: 400px;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
.worldbuilding {
|
||||
.vtt_sys_ravenous {
|
||||
.window-content {
|
||||
height: 100%;
|
||||
padding: 5px;
|
||||
|
|
@ -279,13 +279,13 @@
|
|||
}
|
||||
}
|
||||
|
||||
.worldbuilding.sheet.actor {
|
||||
.vtt_sys_ravenous.sheet.actor {
|
||||
min-width: 560px;
|
||||
min-height: 420px;
|
||||
}
|
||||
|
||||
|
||||
.worldbuilding.sheet.item {
|
||||
.vtt_sys_ravenous.sheet.item {
|
||||
min-width: 460px;
|
||||
min-height: 400px;
|
||||
}
|
||||
|
|
|
|||
20
system.json
20
system.json
|
|
@ -1,11 +1,11 @@
|
|||
{
|
||||
"name": "worldbuilding",
|
||||
"title": "Simple World-Building",
|
||||
"description": "A minimalist game system which provides configurable Actor and Item templates to support free-form system agnostic game-play.",
|
||||
"version": "0.6.4",
|
||||
"name": "vtt_sys_ravenous",
|
||||
"title": "Ravenous Game System",
|
||||
"description": "With ravenous hunger.",
|
||||
"version": "0.0.5h",
|
||||
"minimumCoreVersion": "0.8.9",
|
||||
"compatibleCoreVersion": "9",
|
||||
"author": "Atropos",
|
||||
"author": "Cocobug Inc.",
|
||||
"esmodules": ["module/simple.js"],
|
||||
"styles": ["styles/simple.css"],
|
||||
"packs": [],
|
||||
|
|
@ -16,12 +16,12 @@
|
|||
"path": "lang/en.json"
|
||||
}
|
||||
],
|
||||
"gridDistance": 5,
|
||||
"gridUnits": "ft",
|
||||
"gridDistance": 2,
|
||||
"gridUnits": "m",
|
||||
"primaryTokenAttribute": "health",
|
||||
"secondaryTokenAttribute": "power",
|
||||
"url": "https://gitlab.com/foundrynet/worldbuilding/",
|
||||
"manifest": "https://gitlab.com/foundrynet/worldbuilding/raw/0.6.x/system.json",
|
||||
"download": "https://gitlab.com/foundrynet/worldbuilding/-/archive/release-064/worldbuilding-release-064.zip",
|
||||
"url": "https://proxy.dandaedre.com/gitea/Dandaedre/vtt_sys_ravenous",
|
||||
"manifest": "https://proxy.dandaedre.com/gitea/Dandaedre/vtt_sys_ravenous/raw/branch/main/system.json",
|
||||
"download": "https://proxy.dandaedre.com/gitea/Dandaedre/vtt_sys_ravenous/archive/main.zip",
|
||||
"license": "LICENSE.txt"
|
||||
}
|
||||
|
|
|
|||
|
|
@ -2,6 +2,16 @@
|
|||
"Actor": {
|
||||
"types": ["character"],
|
||||
"character": {
|
||||
"caracteristics": {
|
||||
"str": 0,
|
||||
"agi": 0,
|
||||
"per": 0,
|
||||
"chr": 0,
|
||||
"int": 0,
|
||||
"wpr": 0,
|
||||
"psy": 0,
|
||||
"chn": 0
|
||||
},
|
||||
"biography": "",
|
||||
"health": {
|
||||
"value": 10,
|
||||
|
|
@ -13,7 +23,9 @@
|
|||
"min": 0,
|
||||
"max": 5
|
||||
},
|
||||
"attributes": {},
|
||||
"attributes": {
|
||||
"torque": 1
|
||||
},
|
||||
"groups": {}
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -2,21 +2,29 @@
|
|||
|
||||
{{!-- Sheet Header --}}
|
||||
<header class="sheet-header">
|
||||
<img class="profile-img" src="{{data.img}}" data-edit="img" title="{{data.name}}" height="100" width="100" />
|
||||
<div class="header-fields">
|
||||
<h1 class="charname">
|
||||
<input name="name" type="text" value="{{data.name}}" placeholder="Name" />
|
||||
</h1>
|
||||
<div class="resource">
|
||||
<input type="number" name="data.health.value" value="{{systemData.health.value}}"/>
|
||||
<span> / </span>
|
||||
<input type="number" name="data.health.max" value="{{systemData.health.max}}"/>
|
||||
</div>
|
||||
<div class="resource">
|
||||
<input type="number" name="data.power.value" value="{{systemData.power.value}}"/>
|
||||
<span> / </span>
|
||||
<input type="number" name="data.power.max" value="{{systemData.power.max}}"/>
|
||||
<div class="header-container">
|
||||
<div><input name="name" class="pc-name" type="text" placeholder="Name" value="{{data.name}}"></div>
|
||||
<div class="caracs">
|
||||
<div class="caracs-header"><h3>Caracteristiques</h3></div>
|
||||
<div><label for="strenght">Str</label></div>
|
||||
<div><input name="data.caracteristics.str" id="strenght" type="number" value="{{systemData.caracteristics.str}}"></div>
|
||||
<div><label for="intelligence">Int</label></div>
|
||||
<div><input name="data.caracteristics.int" id="intelligence" type="number" value="{{systemData.caracteristics.int}}"></div>
|
||||
<div><label for="agility">Agi</label></div>
|
||||
<div><input name="data.caracteristics.agi" id="agility" type="number" value="{{systemData.caracteristics.agi}}"></div>
|
||||
<div><label for="willpower">WP</label></div>
|
||||
<div><input name="data.caracteristics.wpr" id="willpower" type="number" value="{{systemData.caracteristics.wpr}}"></div>
|
||||
<div><label for="psy">Psy</label></div>
|
||||
<div><input name="data.caracteristics.psy" id="psy" type="number" value="{{systemData.caracteristics.psy}}"></div>
|
||||
<div><label for="charisma">Chr</label></div>
|
||||
<div><input name="data.caracteristics.chr" id="charisma" type="number" value="{{systemData.caracteristics.chr}}"></div>
|
||||
<div><label for="perception">Per</label></div>
|
||||
<div><input name="data.caracteristics.per" id="perception" type="number" value="{{systemData.caracteristics.per}}"></div>
|
||||
<div><label for="chance">Luk</label></div>
|
||||
<div><input name="data.caracteristics.chn" id="chance" type="number" value="{{systemData.caracteristics.chn}}"></div>
|
||||
</div>
|
||||
<div>Zone PV</div>
|
||||
<div>Zone Armure</div>
|
||||
</div>
|
||||
</header>
|
||||
|
||||
|
|
@ -25,6 +33,7 @@
|
|||
<a class="item" data-tab="description">Description</a>
|
||||
<a class="item" data-tab="items">Items</a>
|
||||
<a class="item" data-tab="attributes">Attributes</a>
|
||||
<a class="item" data-tab="torque">Torque</a>
|
||||
</nav>
|
||||
|
||||
{{!-- Sheet Body --}}
|
||||
|
|
@ -99,11 +108,11 @@
|
|||
</header>
|
||||
|
||||
{{!-- Render the attribute list partial. --}}
|
||||
{{> "systems/worldbuilding/templates/parts/sheet-attributes.html" attributes=systemData.ungroupedAttributes dtypes=dtypes}}
|
||||
{{> "systems/vtt_sys_ravenous/templates/parts/sheet-attributes.html" attributes=systemData.ungroupedAttributes dtypes=dtypes}}
|
||||
|
||||
{{!-- Render the grouped attributes partial and control. --}}
|
||||
<div class="groups">
|
||||
{{> "systems/worldbuilding/templates/parts/sheet-groups.html" attributes=systemData.groupedAttributes groups=systemData.groups dtypes=dtypes}}
|
||||
{{> "systems/vtt_sys_ravenous/templates/parts/sheet-groups.html" attributes=systemData.groupedAttributes groups=systemData.groups dtypes=dtypes}}
|
||||
|
||||
<div class="group-controls flexrow">
|
||||
<input class="group-prefix" type="text" value=""/>
|
||||
|
|
@ -111,5 +120,16 @@
|
|||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
{{!-- Torque Tab --}}
|
||||
<div class="tab attributes" data-group="primary" data-tab="torque">
|
||||
<header class="attributes-header flexrow">
|
||||
<span class="attribute-key">{{localize "SIMPLE.AttributeKey"}}</span>
|
||||
<span class="attribute-value">{{localize "SIMPLE.AttributeValue"}}</span>
|
||||
<span class="attribute-label">{{localize "SIMPLE.AttributeLabel"}}</span>
|
||||
<span class="attribute-dtype">{{localize "SIMPLE.AttributeDtype"}}</span>
|
||||
<a class="attribute-control" data-action="create" data-group="{{group}}"><i class="fas fa-plus"></i></a>
|
||||
</header>
|
||||
</div>
|
||||
</section>
|
||||
</form>
|
||||
</form>
|
||||
|
|
|
|||
|
|
@ -41,11 +41,11 @@
|
|||
</header>
|
||||
|
||||
{{!-- Render the attribute list partial. --}}
|
||||
{{> "systems/worldbuilding/templates/parts/sheet-attributes.html" attributes=systemData.ungroupedAttributes dtypes=dtypes}}
|
||||
{{> "systems/vtt_sys_ravenous/templates/parts/sheet-attributes.html" attributes=systemData.ungroupedAttributes dtypes=dtypes}}
|
||||
|
||||
{{!-- Render the grouped attributes partial and control. --}}
|
||||
<div class="groups">
|
||||
{{> "systems/worldbuilding/templates/parts/sheet-groups.html" attributes=systemData.groupedAttributes groups=systemData.groups dtypes=dtypes}}
|
||||
{{> "systems/vtt_sys_ravenous/templates/parts/sheet-groups.html" attributes=systemData.groupedAttributes groups=systemData.groups dtypes=dtypes}}
|
||||
<div class="group-controls flexrow">
|
||||
<input class="group-prefix" type="text" value=""/>
|
||||
<a class="button group-control" data-action="create-group"><i class="fas fa-plus"></i>Add Attribute Group</a>
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@
|
|||
<a class="group-control" data-action="delete-group"><i class="fas fa-trash"></i></a>
|
||||
</div>
|
||||
|
||||
{{> "systems/worldbuilding/templates/parts/sheet-attributes.html" attributes=group.attributes group=groupKey dtypes=../dtypes}}
|
||||
{{> "systems/vtt_sys_ravenous/templates/parts/sheet-attributes.html" attributes=group.attributes group=groupKey dtypes=../dtypes}}
|
||||
</li>
|
||||
{{/each}}
|
||||
</ol>
|
||||
Reference in New Issue