Skip to content

Commit

Permalink
Deploying to gh-pages from @ 9ff312f 🚀
Browse files Browse the repository at this point in the history
  • Loading branch information
SuenoImposible committed Nov 3, 2024
1 parent 519635b commit 42aa962
Show file tree
Hide file tree
Showing 17 changed files with 447 additions and 121 deletions.
Binary file added assets/OtherUIElements/SinnerBackup.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/OtherUIElements/Team/DeploymentPanel.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added assets/OtherUIElements/Team/IdHoverOverlayTop.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
204 changes: 156 additions & 48 deletions css/default.css
Original file line number Diff line number Diff line change
Expand Up @@ -114,42 +114,6 @@ button {
z-index: 1;
}

.portrait {
width: 100%;
height: 100%;
}

.id-hover-overlay {
display: none;
position: absolute;
top: -5%;
left: -5%;
width: 110%;
height: 110%;
z-index: 60;
object-fit: cover;
}
.id-card:hover .id-hover-overlay{
display: block;
}
.id-selected-overlay {
display: none;
position: absolute;
top: -3%;
left: -4%;
width: 108%;
height: 106%;
z-index: 50;
object-fit: cover;
background-color: #1c1c1c79;
}
.id-selected-image {
position: absolute;
top: 40%;
left: -3%;
width: 106%;
}

.ego-list-orb .ego-image {
width: 100%;
height: 100%;
Expand Down Expand Up @@ -180,16 +144,6 @@ html, body {
object-fit: cover;
}

.card-frame-overlay {
position: absolute;
top: -5%;
left: -5%;
width: 110%;
height: 110%;
z-index: 20;
object-fit: cover;
}

/* --- MAIN SCREEN --- */

#team-builder{
Expand Down Expand Up @@ -246,6 +200,7 @@ html, body {
vertical-align: middle;
padding: 0.3% 2% 0% 2%;
font-size: 2cqw;
color: rgb(160, 107, 58);
text-align: left;
float: right;
margin-right: 5%;
Expand All @@ -254,6 +209,9 @@ html, body {
justify-content: space-around;
align-items: center;
}
#team-builder-overlay-toggles .font-mikodacs{
font-size: 1.5cqw;
}
#team-builder-overlay-toggles button{
width: 40%;
}
Expand Down Expand Up @@ -318,6 +276,122 @@ html, body {
width: auto;
}

.card-frame-overlay {
position: absolute;
top: -5%;
left: -5%;
width: 110%;
height: 110%;
z-index: 20;
object-fit: cover;
}

.portrait {
width: 100%;
height: 100%;
}

.id-hover-overlay {
display: none;
position: absolute;
top: -5%;
left: -5%;
width: 110%;
height: 110%;
z-index: 100;
object-fit: cover;
}
.id-card:hover .id-hover-overlay{
display: block;
}

.id-hover-overlay-container{
position: absolute;
top: -5%;
left: -5%;
width: 110%;
height: 110%;
z-index: 60;
object-fit: cover;
flex-direction: column;
justify-content: space-between;
}
.id-hover-overlay-container div{
position: absolute;
width: 100%;
display: flex;
text-align: center;
justify-content: center;
align-items: center;
font-size: 1.5cqw;
}
.id-hover-overlay-container div span{
text-shadow: 0 0 25px rgb(254, 95, 0), 0 0 25px rgb(254, 119, 0), 0 0 45px rgb(255, 255, 255);
color: rgb(254, 254, 0);
}
.id-hover-overlay-top{
height: 29%;
}
.id-hover-overlay-bottom{
height: 71%;
bottom: 0;
}
.id-hover-overlay-full{
height: 100%;
}
.hover-target *{
opacity: 0;
transition: opacity 0.2s ease;
}
.hover-target:hover *{
opacity: 1;
}
.id-hover-overlay-image {
position: absolute;
top: 0;
left: 0;
width: 100%;
height: 100%;
object-fit: cover;
}

.id-selected-overlay {
display: none;
position: absolute;
top: -3%;
left: -5%;
width: 110%;
height: 106%;
z-index: 50;
object-fit: cover;
background-color: #1c1c1c79;
}
.id-deployment-order-value-container{
width: 100%;
height: 20%;
position: absolute;
top: 17%;
text-align: center;
}
.id-deployment-order-value{
font-size: 3cqw;
}
.id-deployment-order-value.amber{
text-shadow: 0 0 4px rgb(254, 95, 0), 0 0 8px rgb(254, 95, 0);
color: rgb(255, 185, 0);
}
.id-deployment-order-value.teal{
text-shadow: 0 0 4px rgb(7, 104, 92), 0 0 4px rgb(7, 104, 92), 0 0 8px rgb(7, 104, 92);
color: rgb(34, 255, 227);
}
.deployment-banner {
display: none;
position: absolute;
top: 40%;
left: -3.5%;
width: 107%;
}

.identity-info-overlay {
position: absolute;
top: 0;
Expand Down Expand Up @@ -460,7 +534,7 @@ html, body {
aspect-ratio: 1;
}

#affinity-container {
#affinity-panel {
background-image: url("../assets/OtherUIElements/Team/AffinityPanel.png");
background-size: cover;
background-position: center;
Expand All @@ -471,7 +545,7 @@ html, body {
margin: auto;
}

#affinity-container .label{
#affinity-panel .label{
width: 100%;
aspect-ratio: 3;
padding: 12% 0 0 7%;
Expand Down Expand Up @@ -521,6 +595,40 @@ html, body {
font-size: 2.5cqw;
}

#deployment-panel {
background-image: url("../assets/OtherUIElements/Team/DeploymentPanel.png");
background-size: cover;
background-position: center;
background-repeat: no-repeat;

width: 100%;
padding: 5%;
aspect-ratio: 377/141;
margin: auto;
display: flex;
margin-top: 12%;
}
#deployment-panel div{
display: flex;
text-align: center;
justify-content: center;
align-items: center;
height: 100%;
}
#deployment-label-container{
width: 50%;
font-size: 0.9cqw;
}
#deployment-value-container{
padding-top: 3%;
font-size: 2.5cqw;
width: 50%;
letter-spacing: 0.1cqw;
}
#deployed-max-value{
color: rgb(159, 106, 58)
}

/* --- ID/EGO SELECT --- */

.modal {
Expand Down
2 changes: 1 addition & 1 deletion dist/out.js

Large diffs are not rendered by default.

6 changes: 3 additions & 3 deletions dist/out.js.map

Large diffs are not rendered by default.

17 changes: 13 additions & 4 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,10 @@
<div class="main-body">
<div class="top-row">
<button id="copy-link" class="font-mikodacs">COPY LINK TO TEAM</button>
<div id="team-builder-overlay-toggles" class="font-bebas-kai">
<button class="identity-view-button selected">ID</button>
<button class="ego-view-button">E.G.O</button>
<div id="team-builder-overlay-toggles">
<button class="deploy-view-button font-mikodacs">Deploy</button>
<button class="identity-view-button font-bebas-kai selected">ID</button>
<button class="ego-view-button font-bebas-kai">E.G.O</button>
</div>
</div>
<div class="team-container">
Expand All @@ -42,7 +43,7 @@
</div>
</div>
<div class="right-column">
<div id="affinity-container">
<div id="affinity-panel">
<div class="label font-mikodacs text-shadow">AFFINITIES</div>
<div class="affinity-field font-excelsior-sans">
<div class="affinity-field-icon-container"><img class="wrath-icon"></div>
Expand Down Expand Up @@ -87,6 +88,14 @@
</div>
</div>
</div>
<div id="deployment-panel">
<div id="deployment-label-container" class="font-mikodacs">
<span id="deployment-panel-label">Total Participants</span>
</div>
<div id="deployment-value-container" class="font-excelsior-sans">
<span id="deployed-current-value" class="text-shadow">0</span><span id="deployed-max-value" class="text-shadow">/12</span>
</div>
</div>
</div>
</div>

Expand Down
2 changes: 1 addition & 1 deletion src/Enums/OverlayEnum.ts
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
export enum OverlayEnum {
None = 0,
Ego = 1,
Order = 2
Deployment = 2
}
21 changes: 19 additions & 2 deletions src/Handlers/EquipHandler.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
import { Egos } from "../Consts/OtherConstants";
import { OverlayEnum } from "../Enums/OverlayEnum";
import { RiskLevelEnum } from "../Enums/RiskLevelEnum";
import { SinnerEnum } from "../Enums/SinnerEnum";
import { EgoBase } from "../Models/EgoBase";
Expand All @@ -7,16 +8,23 @@ import { UpdateSinnerIdentityCard, UpdateTeamSinDisplay } from "./UIHandler";
import { UpdateLink } from "./URLHandler";

export function EquipIdentity(identity: IdentityBase): void {
let sinner = globalThis.TeamData.find(sinner => sinner.SinnerEnum == identity.Sinner)!
for (let i = 0; i < 3; i++) { //deduct sins generated by old identity from team total
let skill = globalThis.TeamData.find(sinner => sinner.SinnerEnum == identity.Sinner)!.EquipedIdentity.Skills[i]!;
globalThis.TeamSins[skill.Affinity].Generated -= (3 - i);
if (sinner.DeploymentSlot){
globalThis.DeployedTeamSins[skill.Affinity].Generated -= (3 - i);
}
}
globalThis.TeamData.find(sinner => sinner.SinnerEnum == identity.Sinner)!.EquipedIdentity = identity;
for (let i = 0; i < 3; i++) { //add new sins
globalThis.TeamSins[identity.Skills[i]!.Affinity].Generated += (3 - i);
if (sinner.DeploymentSlot){
globalThis.DeployedTeamSins[identity.Skills[i]!.Affinity].Generated += (3 - i);
}
}
UpdateLink();
UpdateTeamSinDisplay();
UpdateTeamSinDisplay(globalThis.TeamOverlay == OverlayEnum.Deployment);
}

export function EquipEgo(newEgo: EgoBase): void {
Expand All @@ -28,6 +36,9 @@ export function EquipEgo(newEgo: EgoBase): void {
sinner.EquipedEgos.push(baseEgo);
baseEgo.Cost.forEach((cost) => {
globalThis.TeamSins[cost.sin].Used += cost.amount;
if (sinner.DeploymentSlot){
globalThis.DeployedTeamSins[cost.sin].Used += cost.amount;
}
});
}
}
Expand All @@ -36,11 +47,14 @@ export function EquipEgo(newEgo: EgoBase): void {
sinner.EquipedEgos.push(newEgo);
newEgo.Cost.forEach((cost) => {
globalThis.TeamSins[cost.sin].Used += cost.amount;
if (sinner.DeploymentSlot){
globalThis.DeployedTeamSins[cost.sin].Used += cost.amount;
}
});
}
UpdateLink();
UpdateSinnerIdentityCard(newEgo.Sinner);
UpdateTeamSinDisplay();
UpdateTeamSinDisplay(globalThis.TeamOverlay == OverlayEnum.Deployment);
}

export function UnequipEgo(sinnerEnum: SinnerEnum, riskLevel: RiskLevelEnum): void {
Expand All @@ -49,6 +63,9 @@ export function UnequipEgo(sinnerEnum: SinnerEnum, riskLevel: RiskLevelEnum): vo
return ego.RiskLevel == riskLevel;
})?.Cost.forEach((cost) => {
globalThis.TeamSins[cost.sin].Used -= cost.amount;
if (sinner.DeploymentSlot){
globalThis.DeployedTeamSins[cost.sin].Used -= cost.amount;
}
});
sinner.EquipedEgos = sinner.EquipedEgos.filter(function (ego) {
return ego.RiskLevel != riskLevel;
Expand Down
Loading

0 comments on commit 42aa962

Please sign in to comment.