Skip to content

Instantly share code, notes, and snippets.

@megantaylor
Created November 26, 2017 17:39
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save megantaylor/9a9a8d628a199daab4badc8c1e166ed8 to your computer and use it in GitHub Desktop.
Save megantaylor/9a9a8d628a199daab4badc8c1e166ed8 to your computer and use it in GitHub Desktop.
Exported from Popcode. Click to import: https://popcode.org/?gist=9a9a8d628a199daab4badc8c1e166ed8
<!doctype html>
<html lang="en">
<head>
<meta charset="UTF-8">
<title>Street Fighter Clone</title>
<link rel="stylesheet" href="css/normalize.css">
<link rel="stylesheet" href="css/main.css">
<script src="http://code.jquery.com/jquery.min.js"></script>
<script src="js/app.js"></script>
</head>
<body>
<div id="message">
<h1> Let's make a Street Fighter clone!</h1>
<p>Don't touch CSS or HTML - only javascript!</p>
<ol>
<li>Hover to get Ryu ready.</li>
<li>Click Ryu to make him in throwing stance</li>
<li>When the mouse leaves Ryu, he should be standing still again.</li>
</ol>
</div>
<div class="main">
<div class="ryu">
<div class="ryu-still"></div>
<div class="ryu-ready"></div>
<div class="ryu-throwing"></div>
</div>
<div class="hadouken">
</div>
</div>
</body>
</html>
{"enabledLibraries":["jquery"]}
/*
* {
outline: red 1px solid;
}
*/
body {
background-color: #000;
}
h1, p, li {
color: rgb(255, 255, 255);
max-width: 500px;
margin: auto;
}
.main {
background-color: #fff;
margin-top: 55px;
padding-left: 100px;
width: 100%;
height: 500px;
position: relative;
z-index: 1;
}
.ryu {
width: 659px;
height: 494px;
}
.ryu-ready, .ryu-still, .ryu-throwing, .ryu-cool {
width: 659px;
height: 494px;
}
.ryu-ready {
background-image: url('https://i.imgur.com/nTj3Fxx.gif');
}
.ryu-still {
background-image: url('https://i.imgur.com/90Mmdcm.png');
}
.ryu-throwing {
background-image: url('http://i.imgur.com/Rfj0a80.png');
}
.hadouken, .ryu-ready, .ryu-still, .ryu-throwing {
background-repeat: no-repeat;
}
.hadouken {
background-image: url('https://i.imgur.com/oTyQRvX.gif');
width: 156px;
height: 90px;
display: none;
position: absolute;
z-index: 10;
top: 160px;
left: 520px;
float: left;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment