Skip to content

Commit

Permalink
Merge pull request #12307 from Villain1nGlasses/master
Browse files Browse the repository at this point in the history
[HeroSystem6eHeroic] Added author credit and HERO as default compendium. Styling fixes.
  • Loading branch information
NorWhal authored Nov 20, 2023
2 parents f58b1a9 + f8bdf87 commit 7f5ac56
Show file tree
Hide file tree
Showing 3 changed files with 103 additions and 66 deletions.
106 changes: 67 additions & 39 deletions HeroSystem6eHeroic/HeroSystem6eHeroic.css
Original file line number Diff line number Diff line change
Expand Up @@ -116,8 +116,8 @@

select {
-webkit-appearance: none;
-moz-appearance: none;
appearance: none;
-moz-appearance: none;
appearance: none;
background-color: transparent;
border: none;
padding: 0 1em 0 0;
Expand All @@ -136,24 +136,38 @@
.custom-select,
.custom-select-skill,
.custom-select-alternate,
.custom-select-alternate-skill {
.custom-select-alternate-skill,
.custom-select-option {
display: grid;
grid-template-areas: "select";
align-items: center;
position: relative;
min-width: 34px;
max-height: 20px;
border: 1px solid gray;
border-radius: 3px;
padding: 0px;
padding-bottom: 1px;
padding-left: 0px;
padding-right: 3px;
cursor: pointer;
background-color: #fff;
background-image: linear-gradient(to top, #f9f9f9, #fff 33%);
}

.custom-select,
.custom-select-skill,
.custom-select-alternate,
.custom-select-alternate-skill {
min-width: 34px;
padding-left: 0px;
}

.custom-select-option {
width: 58px;
background-color: red;
padding-left: 4px;
margin-right: 6px;
}

.custom-select-skill,
.custom-select-alternate-skill {
margin-top: 2px;
Expand All @@ -165,17 +179,20 @@
.custom-select-skill select,
.custom-select-alternate select,
.custom-select-alternate-skill select,
.custom-select-option select,
.custom-select::after,
.custom-select-skill::after,
.custom-select-alternate::after,
.custom-select-alternate-skill::after {
.custom-select-alternate-skill::after,
.custom-select-option::after {
grid-area: select;
}

.custom-select::after,
.custom-select-skill::after,
.custom-select-alternate::after,
.custom-select-alternate-skill::after {
.custom-select-alternate-skill::after,
.custom-select-option::after {
content: "";
justify-self: end;
width: 12px;
Expand All @@ -194,6 +211,10 @@
background-color: salmon;
}

.custom-select-option::after {
background-color: dodgerblue;
}

select:focus + .focus {
position: absolute;
top: -1px;
Expand All @@ -207,7 +228,8 @@
.custom-select--disabled,
.custom-select-skill--disabled,
.custom-select-alternate--disabled,
.custom-select-alternate-skill--disabled {
.custom-select-alternate-skill--disabled,
.custom-select-alternate-option--disabled {
cursor: not-allowed;
background-color: #eee;
background-image: linear-gradient(to top, #ddd, #eee 33%);
Expand Down Expand Up @@ -1312,21 +1334,25 @@
background-color: #fff990;
margin: 5px;
width: 450px;
height: 280px;
height: 282px;
margin: 0px;
border: solid 2px goldenrod;
border-radius: 3px;
}

.item-options-row {
display: flex;
flex-direction: row;
justify-content: flex-start;
.item-options-row,
.item-version-row {
align-items: baseline;
min-width: 400px;
max-height: 28px;
margin-left: 10px;
}

.item-options-row {
display: flex;
flex-direction: row;
justify-content: flex-start;
}

/* --------------------------------------------------- */
/* Version Info */
Expand All @@ -1336,16 +1362,19 @@
display: grid;
grid-template-areas: "versionLabel versionInfo";
justify-content: flex-end;
align-items: baseline;
}

.item-version-label h2 {
font-size: 13px;
max-height: 28px;
color: black;
}

.item-version-information input[readonly] {
background-color: #fff990;
max-width: 45px;
color: black;
max-width: 35px;
padding-bottom: 1px;
}

/* --------------------------------------------------- */
Expand Down Expand Up @@ -2695,7 +2724,7 @@
.grid-container-skills-tab .custom-select,
.grid-container-skills-tab .custom-select-skill,
.grid-container-skills-tab .custom-select-alternate,
.grid-container-skills-tab .custom-select-alternate-skill{
.grid-container-skills-tab .custom-select-alternate-skill {
font-size: 13px;
max-width: 110px;
margin-left: 3px;
Expand Down Expand Up @@ -2816,7 +2845,6 @@
}

/* Buttons for skill movers. */

.skill-mover-plus-minus-enclosure {
display: flex;
flex-direction: row;
Expand Down Expand Up @@ -3372,21 +3400,21 @@
justify-content: space-around;
max-width: 594px;
padding-left: 5px;
margin-left: 3px;
margin-left: 4px;
padding-top: 0px;
grid-gap: 3px;
background-color: #fff990;
border: solid 2px goldenrod;
border-radius: 3px;
height: 175px;
min-height: 179px;
}

.subitem-tab-gear-flex-container-armor-row {
display: flex;
flex-direction: row;
justify-content: space-between;
align-items: center;
max-width: 576px;
max-width: 575px;
margin-bottom: 1px;
height: 24px;
}
Expand Down Expand Up @@ -3947,6 +3975,7 @@
display: flex;
flex-direction: column;
justify-content: space-between;
margin-top: 7px;
max-height: 310px;
min-height: 270px;
}
Expand Down Expand Up @@ -3988,17 +4017,18 @@
border: 1px solid lightgray;
text-align: center;
padding-left: 2px;
height: 20px;
height: 18px;
margin: 0px;
margin-left: 6px;
margin-left: 3px;
}

.item-tab-gear-slide-flex-container-martial-maneuvers textarea {
width: 290px;
width: 244px;
border: 1px solid lightgray;
height: 36px;
padding: 1px;
max-height: 37px;
padding: 0px 3px;
font-size: 12px;
margin: 0px;
}

.item-tab-gear-slide-flex-container-maneuvers h1:nth-child(1),
Expand Down Expand Up @@ -4089,7 +4119,6 @@
}

/* Buttons for maneuver movers. */

.maneuver-mover-plus-minus-enclosure {
display: flex;
flex-direction: row;
Expand Down Expand Up @@ -4181,8 +4210,10 @@
display: flex;
flex-direction: row;
justify-content: space-between;
max-height: 40px;
padding-left: 30px;
max-height: 42px;
padding-left: 23px;
padding-right: 55px;
padding-top: 2px;
}

.subitem-tab-gear-slide-flex-container-martial-name-and-points-row {
Expand All @@ -4202,27 +4233,24 @@
}

/* Basic Attack */

.subitem-tab-gear-slide-flex-container-standard-attack {
display: flex;
flex-direction: row;
justify-content: left;
margin-left: 3px;
margin-right: 3px;
margin-top: 3px;
padding-bottom: 2px;
justify-content: space-between;
margin-left: 27px;
margin-right: 0px;
min-width: 374px;
padding-bottom: 7px;
align-items: center;
}

.subitem-tab-gear-slide-flex-container-standard-attack h1 {
max-width: 90px;
margin-right: 5px;
padding-left: 5px;
margin-right: 8px;
}

.subitem-tab-gear-slide-flex-container-standard-attack h2:nth-child(3) {
width: 160px;
.subitem-tab-gear-slide-flex-container-standard-attack h2 {
text-align: left;
margin-right: 100px;
}

.subitem-tab-gear-slide-flex-container-range-modifiers {
Expand Down
56 changes: 32 additions & 24 deletions HeroSystem6eHeroic/HeroSystem6eHeroic.html
Original file line number Diff line number Diff line change
Expand Up @@ -209,19 +209,19 @@ <h1>CP</h1>
<!-- (3) A sticky note for more player notes. -->

<!-- The rule card: -->
<div class="item-portrait-00">
<h1>Welcome!</h1>
<div class="item-portrait-flex-container">
<div class="item-portrait-rule-description">
<h1>Starting Character Points</h1>
<p>Heroic characters are typically built on a base of 125 CP plus up to 50 CP that are offset with Complications. Use the Bonus CP input at the bottom of this sheet to account for free abilities.</p>
</div>
<div class="item-portrait-rule-description">
<h1>Portrait</h1>
<p>You may change this frame to your avatar or to space for more notes with the hidden side arrow buttons.</p>
</div>
<div class="item-portrait-00">
<h1>Welcome!</h1>
<div class="item-portrait-flex-container">
<div class="item-portrait-rule-description">
<h1>Starting Character Points</h1>
<p>Heroic characters are typically built on a base of 125 CP plus up to 50 CP that are offset with Complications. Use the Bonus CP input at the bottom of this sheet to account for free abilities.</p>
</div>
<div class="item-portrait-rule-description">
<h1>Portrait</h1>
<p>You may change this frame to your avatar or to space for more notes with the hidden side arrow buttons.</p>
</div>
</div>
</div>
</div>

<!-- Avatar Portrait Image -->
<div class="item-portrait-01">
Expand Down Expand Up @@ -1212,12 +1212,15 @@ <h1>CP</h1>
<div class="item-tab-gear-slide-flex-container-martial-maneuvers-block">

<!-- Standard Attack -->
<div class="subitem-tab-gear-slide-flex-container-standard-attack">
<div class=custom-button-triangle></div>
<h1>Basic Attack</h1>
<h2 title="@{hiddenManeuverDamage01}">HA STR/5</h2>
<input type="text" value="1/2" name="attr_normalPhase01" title="@{normalPhase01}" tabindex="-1" readonly="">
<button type="action" class="button buttonRollNormalAttack" tabindex="-1" name="act_standardAttackRoll" title="%{standardAttackRoll}">Roll</button>
<div class=".item-flex-maneuver">
<div class="subitem-flex-container-martial-row">
<div class="subitem-tab-gear-slide-flex-container-standard-attack">
<h1>Basic Attack</h1>
<h2 title="@{hiddenManeuverDamage01}">HA STR/5</h2>
<input type="text" value="1/2" name="attr_normalPhase01" title="@{normalPhase01}" tabindex="-1" readonly="">
<button type="action" class="button buttonRollNormalAttack" tabindex="-1" name="act_standardAttackRoll" title="%{standardAttackRoll}">Roll</button>
</div>
</div>
</div>

<input type="hidden" class="sheet-maneuver-toggle" name="attr_maneuverToggle" value="maneuverExpand01" />
Expand Down Expand Up @@ -5755,7 +5758,7 @@ <h1>Display Degree of Success</h1>
</div>

<div class="item-options-row">
<div class="custom-select-skill">
<div class="custom-select-option">
<select name="attr_whisperToGM">
<option value="" selected>Never</option>
<option value="/w GM ">Always</option>
Expand All @@ -5771,7 +5774,7 @@ <h2>Version:</h2>
</div>

<div class="item-version-information">
<input type="text" value="2.1" name="attr_version" title="@{version}" readonly tabindex="-1"/>
<input type="text" value="2.2" name="attr_version" title="@{version}" readonly tabindex="-1"/>
</div>
</div>
</div>
Expand Down Expand Up @@ -6085,6 +6088,7 @@ <h2>Version:</h2>

attributes.theSheetAvatar = values.character_avatar;

// Version Checks
// Check for unversioned sheets
if (values.validateMay23 == undefined) {
// if no points spent, then it's a new sheet
Expand All @@ -6094,7 +6098,6 @@ <h2>Version:</h2>
attributes.validateMay23 = 1;
}
let version = origVersion;


if (version < 1.1) {
values = await _getAttrs(["intelligenceChance", "enhancedPerceptionModifier", "body", "stun", "endurance", "strength", "optionSuperHeroicEndurance"]);
Expand All @@ -6116,13 +6119,18 @@ <h2>Version:</h2>
attributes.whisperToGM = "";
version = 2.1;
}

if (version < 2.2) {
// No updates to attributes needed except version number (for now).
version = 2.2;
}

if (version != origVersion) {
console.log(`Updated ${name} from ${origVersion} to ${version}`);
attributes.version = version;
}

// We are doing this with await's in order to only do a single setAttrs at the end
// We are doing this with awaits in order to only do a single setAttrs at the end
setAttrs(attributes);
});

Expand Down Expand Up @@ -8670,8 +8678,8 @@ <h2>Version:</h2>
normalMessage += " x" + NSTUN + "STUN";
}
if (BODYx != 1) {
normalMessage += " x" + BODYx + "BODY";
killMessage += " x" + BODYx + "BODY";
normalMessage += " x" + BODYx + " BODY";
killMessage += " x" + BODYx + " BODY";
}

var theHitLocation = {
Expand Down
Loading

0 comments on commit 7f5ac56

Please sign in to comment.