Skip to content

Instantly share code, notes, and snippets.

@mvargasmoran
Created November 4, 2013 15:25
Show Gist options
  • Save mvargasmoran/7304158 to your computer and use it in GitHub Desktop.
Save mvargasmoran/7304158 to your computer and use it in GitHub Desktop.
¡Asteroid!
/**
* ¡Asteroid!
8192 128
*/
@keyframes motion{
from{ background-position: 0 0; }
to{ background-position: -8192px 0;}
}
.animated{
margin: 100px auto;
width: 128px; height: 128px;
/* border: 1px solid black;http://www.kevinbertel.com/diablo2/sheets/AI-2HS-A1-hd_LIT-tr_LIT-lg_LIT-ra_LIT-la_LIT-s1_LIT-s2_LIT-rh_CLM-lh_0-sh_0-.gif */
background: url("http://commondatastorage.googleapis.com/codeskulptor-assets/asteroid1.opengameart.warspawn.png") 0 0;
animation: motion 7s infinite steps(64);
}
<!-- content to be placed inside <body>…</body> -->
<img src="http://commondatastorage.googleapis.com/codeskulptor-assets/asteroid1.opengameart.warspawn.png" />
<div class="animated"></div>
// alert('Hello world!');
{"view":"split","fontsize":"100","seethrough":"","prefixfree":"1","page":"css"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment