Skip to content

Instantly share code, notes, and snippets.

@ZenithRogue
Created January 17, 2019 16:32
Show Gist options
  • Save ZenithRogue/cbc40c464c0e17596c3a439b23dc8785 to your computer and use it in GitHub Desktop.
Save ZenithRogue/cbc40c464c0e17596c3a439b23dc8785 to your computer and use it in GitHub Desktop.
// ==UserScript==
// @name Scratch 2.0 extension converter
// @namespace http://tampermonkey.net/
// @version 0.1
// @description try to take over the world!
// @author NitroCipher
// @match https://scratch.mit.edu/convert
// @grant none
// @require https://cdnjs.cloudflare.com/ajax/libs/jquery/3.3.1/jquery.min.js
// ==/UserScript==
(function() {
'use strict';
var newDesc;
$.ajax({
url: "https://raw.githubusercontent.com/NitroCipher/NitroBlock/master/MainScript.js",
text: "text/plain"
}).done( function (data) {
//alert("done");
var desc = "descriptor" + data.split("var descriptor")[1].split("// Register")[0];
var descriptor;
eval(desc);
//here we go...
descriptor.blocks.foreach(reformat);
$(".box-content").html(newDesc);
});
function reformat(item, index) {
newDesc = newDesc + descriptor.blocks[index];
}
// Your code here...
})();
@devxan
Copy link

devxan commented Aug 2, 2020

What does this do?

@ZenithRogue
Copy link
Author

It is an unfinished version of this script
https://github.com/ZenithRogue/ext2to3/

@devxan
Copy link

devxan commented Aug 2, 2020

It is an unfinished version of this script
https://github.com/ZenithRogue/ext2to3/

Oh wow, this is awesome! Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment