Skip to content

Commit

Permalink
added red health fill to statbar
Browse files Browse the repository at this point in the history
  • Loading branch information
Aidenjn committed Feb 24, 2016
2 parents 5ebd46f + 547c15e commit b458af3
Show file tree
Hide file tree
Showing 2 changed files with 34 additions and 43 deletions.
12 changes: 6 additions & 6 deletions css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ select:hover {
right: 0px;
position: fixed;
width: 20vw;
background: #663300;
background: #FF551C;
transition: width 1s;
/* overflow-x: scroll;*/
height: 25%;
Expand Down Expand Up @@ -220,7 +220,7 @@ select:hover {

#cards li {
height: 17vw;
width: 23vw;
width: 13vw;
border-style: solid;
border-width: 1vw;
border-color: AntiqueWhite;
Expand Down Expand Up @@ -256,24 +256,24 @@ CARDS
**************************************/

.card {
color: yellow;
color: AntiqueWhite;
background: blue;
background-image: url('../images/samTheSham.jpg');
}

.card2 {
.card1 {
color: white;
background: green;
background-image: url('../images/samTheSham.jpg');
}

.card3 {
.card2 {
background: yellow;
color: red;
background-image: url('../images/samTheSham.jpg');
}

.card4 {
.card3 {
background: black;
color: white;
background-image: url('../images/samTheSham.jpg');
Expand Down
65 changes: 28 additions & 37 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ <h3 id="statActions">Remaining Actions:</h3> <!-- Current player actions label -
}


$("#bBar").css("background", "#996633");
$("#bBar").css("background", "#C96A4B");
$("#bBar").css("width", "100%");
$("#cards").delay(680).show(680);

Expand All @@ -91,7 +91,7 @@ <h3 id="statActions">Remaining Actions:</h3> <!-- Current player actions label -
function hideBBar() { // hide the card cabinet a.k.a. bottom bar
if (expanded === true) {
$("#cards").delay(600).show(600).finish();
$("#bBar").css("background", "#663300");
$("#bBar").css("background", "#FF551C");
$("#bBar").css("width", "20vw");
$("#cards").hide(0);
$("#bBar").css("overflowX", "hidden");
Expand Down Expand Up @@ -183,6 +183,8 @@ <h3 id="statActions">Remaining Actions:</h3> <!-- Current player actions label -
$("#statName").html(players[currentPlayer].nick);
$("#statActionNumber").html(actionCounter);
$("#statHealthNumber").html(players[currentPlayer].health);
$("#statName").html(players[currentPlayer].nick);
$("#statCharacter").html(players[currentPlayer].character.type);

} else if (turnCounter === 1) {
moveCounter = Math.floor((Math.random() * players[currentPlayer].character.dice) + 1);
Expand Down Expand Up @@ -230,21 +232,13 @@ <h3 id="statActions">Remaining Actions:</h3> <!-- Current player actions label -
health: 20,
numActions: 3,
cards: [// array of cards: put new cards here
{
attack: 5,
defend: 3,
rarity: 1
},
{
attack: 6,
defend: 0,
rarity: 2
},
{
attack: 2,
defend: 2,
rarity: 2
}
{attack: 4,defend: 2,move: 5,count: 6},
{attack: 5,defend: 1,count: 4},
{attack: 6,defend: 0,count: 2},
{attack: 3,defend: 4,count: 5},
{attack: 3,defend: 0,count: 3},
{attack: 4,defend: 5,count: 2},
{attack: 0,defend: 5,count: 3}
]
},
{
Expand All @@ -254,16 +248,14 @@ <h3 id="statActions">Remaining Actions:</h3> <!-- Current player actions label -
health: 16,
numActions: 2,
cards: [// array of cards: put new cards here
{
attack: 3,
defend: 5,
rarity: 1
},
{
attack: 6,
defend: 0,
rarity: 2
}
{attack: 8,defend: 0,count: 2},
{attack: 4,defend: 1,count: 5},
{attack: 3,defend: 2,count: 7},
{attack: 0,defend: 4,count: 3},
{attack: 5,defend: 0,count: 3},
{attack: 6,defend: 0,count: 1},
{attack: 3,defend: 0,pierce: true,count: 3},
{attack: 3,defend: 3,pierce: true,count: 1}
]
},
{
Expand All @@ -273,16 +265,14 @@ <h3 id="statActions">Remaining Actions:</h3> <!-- Current player actions label -
health: 22,
numActions: 2,
cards: [// array of cards: put new cards here
{
attack: 3,
defend: 5,
rarity: 1
},
{
attack: 6,
defend: 0,
rarity: 2
}
{attack: 8,defend: 0,count: 2},
{attack: 0,defend: 7,count: 3},
{attack: 5,defend: 2,count: 5},
{attack: 3,defend: 2,count: 4},
{attack: 2,defend: 3,count: 4},
{attack: 0,defend: 0,heal: 8,count: 2},
{attack: 0,defend: 0,heal: 2,count: 1},
{attack: 4,defend: 4,count: 4}
],
aimerLine: new Path()
}
Expand Down Expand Up @@ -382,6 +372,7 @@ <h3 id="statActions">Remaining Actions:</h3> <!-- Current player actions label -
$("#statActionNumber").html(actionCounter);
$("#statHealthNumber").html(players[currentPlayer].health);
$("#statName").html(players[currentPlayer].nick);
$("#statCharacter").html(players[currentPlayer].character.type);
setup();
}

Expand Down

0 comments on commit b458af3

Please sign in to comment.