Skip to content

Commit

Permalink
fix: Fixed differences between versions
Browse files Browse the repository at this point in the history
  • Loading branch information
UltraKev authored and xdy committed Aug 21, 2020
1 parent fbd2c96 commit 2d0f1e8
Show file tree
Hide file tree
Showing 9 changed files with 131 additions and 197 deletions.
1 change: 0 additions & 1 deletion src/module/entities/TwodsixActor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ export default class TwodsixActor extends Actor {

for (const skill of Object.values(data.skills as Record<any, any>)) {
const characteristic = skill.characteristic;
console.log(skill)
skill.mod = calcModFor(data.characteristics[characteristic].value);
}
}
Expand Down
1 change: 0 additions & 1 deletion src/module/handlebars.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ export default function registerHandlebarsHelpers():void {
});

Handlebars.registerHelper('shouldShowSkill', function(skill, hideUntrainedSkills) {
// console.log('shouldShowSkill', skill, hideUntrainedSkills)
return skill.trained || hideUntrainedSkills
});

Expand Down
2 changes: 1 addition & 1 deletion static/styles/twodsix.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

7 changes: 6 additions & 1 deletion static/system.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,13 @@
"url": "https://github.com/xdy/twodsix-foundryvtt/",
"manifest": "https://github.com/xdy/twodsix-foundryvtt/releases/latest/download/system.json",
"download": "https://github.com/xdy/twodsix-foundryvtt/releases/latest/download/twodsix.zip",
"version": "0.3.4",
<<<<<<< HEAD
"version": "0.3.8",
"author": "Jonas Karlsson (xdy#3735), Kevin Maree (Ultra Kev#9816), Rob (RobCubed #9180)",
=======
"version": "0.3.0",
"author": "Jonas Karlsson (xdy#3735), Kevin Maree (Ultra Kev#9816)",
>>>>>>> 557c1b7... chore(release): 0.3.0 [skip ci]
"bugs": "",
"changelog": "",
"minimumCoreVersion": "0.6.2",
Expand Down
39 changes: 24 additions & 15 deletions static/template.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
{
"Actor": {
"types": ["traveller"],
"types": [
"traveller"
],
"traveller": {
"name": "",
"homeworld": "",
Expand Down Expand Up @@ -463,7 +465,6 @@
"max": 9,
"mod": 0,
"characteristic": "strength"

},
"language": {
"label": "Languages",
Expand All @@ -481,7 +482,6 @@
"max": 9,
"mod": 0,
"characteristic": "strength"

},
"language-2": {
"label": "Language 2",
Expand All @@ -491,7 +491,6 @@
"max": 9,
"mod": 0,
"characteristic": "strength"

},
"language-3": {
"label": "Language 3",
Expand All @@ -501,7 +500,6 @@
"max": 9,
"mod": 0,
"characteristic": "strength"

},
"language-4": {
"label": "Language 4",
Expand All @@ -511,7 +509,6 @@
"max": 9,
"mod": 0,
"characteristic": "strength"

},
"language-5": {
"label": "Language 5",
Expand All @@ -521,7 +518,6 @@
"max": 9,
"mod": 0,
"characteristic": "strength"

},
"leadership": {
"label": "Leadership",
Expand Down Expand Up @@ -907,11 +903,18 @@
"mod": 0,
"characteristic": "strength"
}
}
},
"contacts": "",
"allies": "",
"enemies": ""
}
},
"Item": {
"types": ["equipment", "weapon", "armor"],
"types": [
"equipment",
"weapon",
"armor"
],
"templates": {
"carried": {
"name": "",
Expand All @@ -934,15 +937,21 @@
}
},
"equipment": {
"templates": ["carried"]
"templates": [
"carried"
]
},
"weapon": {
"templates": ["carried", "weapon"]
"templates": [
"carried",
"weapon"
]
},
"armor": {
"templates": ["carried", "armor"]
"templates": [
"carried",
"armor"
]
}
},
"Contacts": {}

}
}
170 changes: 4 additions & 166 deletions static/templates/actors/actor-sheet.html
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@

{{!-- Sheet Body --}}
<div class="character-tabs-info sheet-body">

{{!-- Sheet Tab Navigation --}}
<div class="character-tabs">
<nav class="sheet-tabs tabs" data-group="primary">
Expand All @@ -71,176 +71,14 @@
</nav>
</div>


{{!-- Skills Tab --}}
<div class="tab skills" data-group="primary" data-tab="skills">
{{!-- 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="skills grid grid-2col">
<button class="flexrow flex-group-center toggle-skills">
{{#if @root.options.hideUntrainedSkills}}
Hide Untrained
{{else}}
Show Untrained
{{/if}}
</button>


<div class="skills-joat"></div>
<label for="joat" class="flex3 resource-label">Jack of All Trades</label>
<span class="flex4">
<i class="fa fa-arrow-circle-down downgrade-joat downgrade-joat-{{data.jackofalltrades.value}}"></i>
<i class="fa fa-arrow-circle-up upgrade-joat upgrade-joat-{{data.jackofalltrades.value}}"></i>
{{data.jackofalltrades.value}}
</span></div>



<div class="skills grid grid-4col">
<span class="skill-container">
<div class="skill-title">Skill Name</div>
<div class="skill-level">Level</div>
<div class="skill-mod">Modifier</div>
<div class="skill-total">Total</div>
<div class="roll-dice">Roll</div>
</span>
{{#each data.skills as |skill key|}}

{{#if (shouldShowSkill skill @root.options.hideUntrainedSkills)}}

<div class="skill skill-container trained-{{skill.trained}}">

<label for="data.skills.{{key}}.value" class="flex2 resource-label skill-{{skill.trained}}">{{skill.label}}</label>

<span class="skill-arrows flex1">
<i data-label="{{key}}" class="fa fa-arrow-circle-down downgrade-skill-{{skill.trained}} downgrade-skill"></i>

<span class="skill-output" class="flex1 skill-mod" data-label="{{skill.label}}">{{numberFormat (getSkillValueWithJoat skill @root.data.jackofalltrades) decimals=0 sign=true}}</span>

<i data-label="{{key}}" class="fa fa-arrow-circle-up upgrade-skill{{skill.value}} upgrade-skill"></i>
{{data.jackofalltrades.value}}
</span>


<select class="select-mod" name="data.skills.{{key}}.characteristic" value={{skill.characteristic}} >
{{#select skill.characteristic}}
<option value="strength" for="skill-modifier">STR</option>
<option value="dexterity" for="skill-modifier">DEX</option>
<option value="endurance" for="skill-modifier">END</option>
<option value="intellect" for="skill-modifier">INT</option>
<option value="education" for="skill-modifier">EDU</option>
<option value="social" for="skill-modifier">SOC</option>
<option value="psionics" for="skill-modifier">PSI</option>
{{/select}}
</select>

<span class="total-output" class="flex1 skill-mod" data-label="skill.total">{{numberFormat (getTotalSkillValue skill @root.data.jackofalltrades) decimals=0 sign=true}}</span>

<span class="mini-dice"><img class="rollable" data-roll="2d6+{{getSkillValueWithJoat skill @root.data.jackofalltrades}}+{{skill.mod}}" src="./systems/twodsix/assets/d6-icon.svg"/></span>
</span>


</div>
{{/if}}
{{/each}}
</div>
</div>
{{> "systems/twodsix/templates/actors/parts/actor-skills.html"}}

{{!-- Owned Items Tab --}}

<div class="tab items" data-group="primary" data-tab="items">
<ol class="items-list">
<li class="item flexrow item-header">
<div class="item-image"></div>
<div class="item-name">Name</div>
<div class="item-controls">
<a class="item-control item-create" title="Create item" data-type="item"><i class="fas fa-plus"></i> Add
item</a>
</div>
</li>
{{#each actor.gear as |item id|}}
<li class="item flexrow" data-item-id="{{item._id}}">
<div class="item-image"><img src="{{item.img}}" title="{{item.name}}" width="24" height="24" /></div>
<h4 class="item-name">{{item.name}}</h4>
<div class="item-controls">
<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}}
</ol>
</div>
{{> "systems/twodsix/templates/actors/parts/actor-items.html"}}

{{!-- Biography Tab --}}

<div class="tab info" data-group="primary" data-tab="info">
<div class="grid-container">
<div class="contacts"></div>
<div class="allies"></div>
<div class="enemies"></div>
<div class="biography">
{{editor content=data.biography target="data.biography" button=true owner=owner editable=editable}}
</div>
</div>

</div>

<!--
{{!-- Owned Features Tab --}}
<div class="tab features" data-group="primary" data-tab="features">
<ol class="items-list">
<li class="item flexrow item-header">
<div class="item-image"></div>
<div class="item-name">Name</div>
<div class="item-controls">
<a class="item-control item-create" title="Create item" data-type="feature"><i class="fas fa-plus"></i> Add
item</a>
</div>
</li>
{{#each actor.features as |item id|}}
<li class="item flexrow" data-item-id="{{item._id}}">
<div class="item-image"><img src="{{item.img}}" title="{{item.name}}" width="24" height="24" /></div>
<h4 class="item-name">{{item.name}}</h4>
<div class="item-controls">
<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}}
</ol>
</div>
{{!-- Owned Spells Tab --}}
<div class="tab spells" data-group="primary" data-tab="spells">
<ol class="items-list">
<li class="item flexrow item-header">
<div class="item-image"></div>
<div class="item-name">Name</div>
<div class="item-controls"></div>
</li>
{{#each actor.spells as |spells spellLevel|}}
<li class="item flexrow item-header">
<div class="item-name">Level {{spellLevel}} Spells</div>
<div class="item-controls">
<a class="item-control item-create" title="Create item" data-type="spell"
data-spell-level="{{spellLevel}}"><i class="fas fa-plus"></i> Add LVL {{spellLevel}}</a>
</div>
</li>
{{#each spells as |item id|}}
<li class="item flexrow" data-item-id="{{item._id}}">
<div class="item-image"><img src="{{item.img}}" title="{{item.name}}" width="24" height="24" /></div>
<h4 class="item-name">{{item.name}}</h4>
<div class="item-controls">
<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}}
{{/each}}
</ol>
</div>-->
{{> "systems/twodsix/templates/actors/parts/actor-info.html"}}

</div>
</div>
Expand Down
25 changes: 22 additions & 3 deletions static/templates/actors/parts/actor-info.html
Original file line number Diff line number Diff line change
@@ -1,4 +1,23 @@
{{!-- Biography Tab --}}
<div class="tab biography" data-group="primary" data-tab="description">
{{editor content=data.biography target="data.biography" button=true owner=owner editable=editable}}
<div class="tab info" data-group="primary" data-tab="info">
<div class="grid-container">
<div class="contacts">
contacts:
{{{editor content=data.contacts target="data.contacts" button=true owner=owner editable=editable}}}

</div>
<div class="allies">
allies:
{{{editor content=data.allies target="data.allies" button=true owner=owner editable=editable}}}

</div>
<div class="enemies">
enemies:
{{{editor content=data.enemies target="data.enemies" button=true owner=owner editable=editable}}}

</div>
<div class="description">
Description:
{{{editor content=data.description target="data.description" button=true owner=owner editable=editable}}}
</div>
</div>
</div>
17 changes: 8 additions & 9 deletions static/templates/actors/parts/actor-items.html
Original file line number Diff line number Diff line change
@@ -1,14 +1,13 @@
{{!-- Owned Items Tab --}}
<div class="tab items" data-group="primary" data-tab="items">
<ol class="items-list">
<li class="item flexrow item-header">
<div class="item-image"></div>
<div class="item-name">Name</div>
<div class="item-controls">
<a class="item-control item-create" title="Create item" data-type="item"><i class="fas fa-plus"></i> Add
item</a>
</div>
</li>
<!-- <li class="item flexrow item-header">-->
<!-- <div class="item-image"></div>-->
<!-- <div class="item-name">Name</div>-->
<!-- <div class="item-controls">-->
<!-- <a class="item-control item-create" title="Create item" data-type="item"><i class="fas fa-plus"></i> Add-->
<!-- item</a>-->
<!-- </div>-->
<!-- </li>-->
{{#each actor.gear as |item id|}}
<li class="item flexrow" data-item-id="{{item._id}}">
<div class="item-image"><img src="{{item.img}}" title="{{item.name}}" width="24" height="24" /></div>
Expand Down
Loading

0 comments on commit 2d0f1e8

Please sign in to comment.