1
0
mirror of https://github.com/tobspr/shapez.io.git synced 2025-12-16 19:51:50 +00:00
tobspr_shapez.io/res_pipeline/gulpfile.js
theisen1337 43bab84ab3 Updated pipeline for packing textures.
Open source texture packing pipeline  from "https://github.com/odrick/free-tex-packer"
2020-06-11 16:02:05 -04:00

39 lines
828 B
JavaScript

const gulp = require("gulp");
let texturePacker = require('gulp-free-tex-packer');
gulp.task('default', function() {
gulp.src('../res_raw/**/**/*.png')
.pipe(texturePacker({textureName: "atlas0_100"}))
.pipe(gulp.dest('dest/'));
gulp.src('../res_raw/**/**/*.png')
.pipe(texturePacker({
textureName: "atlas0_75",
scale: 0.75,
}))
.pipe(gulp.dest('dest/'));
gulp.src('../res_raw/**/**/*.png')
.pipe(texturePacker({
textureName: "atlas0_50",
scale: 0.50,
}))
.pipe(gulp.dest('dest/'));
gulp.src('../res_raw/**/**/*.png')
.pipe(texturePacker({
textureName: "atlas0_25",
scale: 0.25,
}))
.pipe(gulp.dest('dest/'));
gulp.src('../res_raw/**/**/*.png')
.pipe(texturePacker({
textureName: "atlas0_10",
scale: 0.10,
}))
.pipe(gulp.dest('dest/'));
});