Created
March 25, 2014 06:13
-
-
Save naosim/9756083 to your computer and use it in GitHub Desktop.
enchantの初期状態をサクっと作るスクリプト (プロジェクトテンプレート)
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
mkdir js css img | |
echo "download image" | |
cd img | |
curl -s -f -L https://raw.github.com/uei/enchant.js-builds/master/images/chara1.png -O | |
cd .. | |
echo "download enchant.js" | |
cd js | |
curl -s -f -L https://raw.github.com/uei/enchant.js-builds/master/build/enchant.min.js -O | |
echo "create main.js" | |
echo "enchant(); | |
var game = new Core(320, 320); // game stage | |
game.fps = 30; | |
game.onload = function(){ | |
var label = new Label('test'); | |
game.rootScene.addChild(label); | |
}; | |
game.start();">main.js | |
cd .. | |
echo "create index.html" | |
echo '<!DOCTYPE html> | |
<html lang="ja"> | |
<head><script src="js/enchant.min.js"></script></head> | |
<body> | |
<script src="js/main.js"></script> | |
</body> | |
</html>'>index.html |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment