Skip to content

Instantly share code, notes, and snippets.

param ([switch]$IsHidden)
if (-not $IsHidden.IsPresent) {
$scriptPath = $MyInvocation.MyCommand.Path
$arguments = "-File `"$scriptPath`" -IsHidden"
Start-Process powershell.exe -ArgumentList $arguments -WindowStyle Hidden
exit
}
Add-Type -AssemblyName System.Windows.Forms
Add-Type -AssemblyName System.Drawing
@Mario0051
Mario0051 / extract-sounds.js
Created April 6, 2019 23:07
Extract sounds from Minecraft [April Fools' Update (2019)].
var fs = require('fs-extra')
var objects = require('./indexes/1.14-af.json').objects
for (var filePath in objects) {
if (!/\/(?:ambient|block|damage|dig|enchant|entity|fire|fireworks|item|liquid|minecart|mob|music|note|portal|random|records|step|tile|ui)\//.test(filePath)) continue
var copyPath = filePath.replace('minecraft/', './')
var hash = objects[filePath].hash
var objectPath = './objects/' + hash.substring(0, 2) + '/' + hash
@Mario0051
Mario0051 / extract-textures.js
Created November 29, 2018 03:03
Extract panorama textures from Minecraft (18w47b's new panoramas)
var fs = require('fs-extra')
var objects = require('./indexes/1.14.json').objects
for (var filePath in objects) {
if (!/\/(?:gui)\//.test(filePath)) continue
var copyPath = filePath.replace('minecraft/', './')
var hash = objects[filePath].hash
var objectPath = './objects/' + hash.substring(0, 2) + '/' + hash
@Mario0051
Mario0051 / extract-textures.js
Last active April 6, 2019 22:58
Extract textures from Minecraft [April Fools' Update (2018)].
var fs = require('fs-extra')
var objects = require('./indexes/1.13-af.json').objects
for (var filePath in objects) {
if (!/\/(?:blocks|colormap|effect|entity|environment|font|gui|items|map|misc|models|painting|particle|texts)\//.test(filePath)) continue
var copyPath = filePath.replace('minecraft/', './')
var hash = objects[filePath].hash
var objectPath = './objects/' + hash.substring(0, 2) + '/' + hash
@Mario0051
Mario0051 / extract-sounds.js
Last active April 6, 2019 23:00
Extract sounds from Minecraft.
var fs = require('fs-extra')
var objects = require('./indexes/1.14.json').objects
for (var filePath in objects) {
if (!/\/(?:ambient|block|damage|dig|enchant|entity|fire|fireworks|item|liquid|minecart|mob|music|note|portal|random|records|step|tile|ui)\//.test(filePath)) continue
var copyPath = filePath.replace('minecraft/', './')
var hash = objects[filePath].hash
var objectPath = './objects/' + hash.substring(0, 2) + '/' + hash