Skip to content

Commit

Permalink
Add compass animation mcmeta. Ref GH-10
Browse files Browse the repository at this point in the history
  • Loading branch information
deathcap committed Jan 24, 2014
1 parent ca42bea commit 93ba472
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions scripts/generate.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ zipTP.file('pack.txt', fs.readFileSync(root + 'pack.txt', 'utf8').replace('SNAPS
processTextures(textureRoot + 'blocks/', 'blocks', 'textures/blocks/', 'assets/minecraft/textures/blocks/');
processTextures(textureRoot + 'items/', 'items', 'textures/items/', 'assets/minecraft/textures/items/');
processSounds();
processAnimations();

fs.writeFileSync(outTP, zipTP.generate(zipOpts), 'binary');
fs.writeFileSync(outRP, zipRP.generate(zipOpts), 'binary');
Expand All @@ -57,6 +58,11 @@ function processSounds() {
zipRP.file('assets/minecraft/sounds/liquid/splash.ogg', new Uint8Array(fs.readFileSync(soundsRoot + '9508_petenice_splash.ogg')), fileOpts);
};

function processAnimations() {
// TODO: more animations. https://github.com/deathcap/ProgrammerArt/issues/10
zipRP.file('assets/minecraft/textures/items/compass.png.mcmeta', JSON.stringify({animation: {}}), fileOpts);
};

function processTextures(thisRoot, category, tpPrefix, rpPrefix) {
var files = fs.readdirSync(thisRoot);

Expand Down

0 comments on commit 93ba472

Please sign in to comment.