簡(jiǎn)版JS替換Scratch積木源碼
(function (Scratch) {
? ? 'use strict';
? ? class a {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? color1: '#4c97ff',
? ? ? ? ? ? ? ? color2: '#3373cc',
? ? ? ? ? ? ? ? color2: '#3373cc',
? ? ? ? ? ? ? ? id: 'motion',
? ? ? ? ? ? ? ? name: '運(yùn)動(dòng)',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: 'a',
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.COMMAND,
? ? ? ? ? ? ? ? ? ? ? ? text: '恭喜你',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new a());
}(Scratch));
(function (Scratch) {
? ? 'use strict';
? ? class b {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? color1: '#9966ff',
? ? ? ? ? ? ? ? color2: '#774dcb',
? ? ? ? ? ? ? ? color2: '#774dcb',
? ? ? ? ? ? ? ? id: 'looks',
? ? ? ? ? ? ? ? name: '外觀',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: 'a',
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.COMMAND,
? ? ? ? ? ? ? ? ? ? ? ? text: '塊沒了',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new b());
}(Scratch));
(function (Scratch) {
? ? 'use strict';
? ? class c {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? color1: '#cf63cf',
? ? ? ? ? ? ? ? color2: '#bd42bd',
? ? ? ? ? ? ? ? color2: '#bd42bd',
? ? ? ? ? ? ? ? id: 'sound',
? ? ? ? ? ? ? ? name: '聲音',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: 'a',
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.COMMAND,
? ? ? ? ? ? ? ? ? ? ? ? text: '塊被我吃了',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new c());
}(Scratch));
(function(Scratch) {
? 'use strict';
? class d {
? ? getInfo() {
? ? ? ? return {
? ? ? ? color1: '#ffab19',
? ? ? ? color2: '#cf8b17',
? ? ? ? color2: '#cf8b17',
? ? ? ? id: 'event',
? ? ? ? name: '事件',
? ? ? ? blocks: [
? ? ? ? ? {
? ? ? ? ? ? opcode: 'a',
? ? ? ? ? ? blockType: Scratch.BlockType.HAT,
? ? ? ? ? ? text: '啥都不做',
? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? },
? ? ? ? ]
? ? ? };
? ? }
? }
? Scratch.extensions.register(new d());
}(Scratch));
(function (Scratch) {
? ? 'use strict';
? ? class e {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? color1: '#ffab19',
? ? ? ? ? ? ? ? color2: '#cf8b17',
? ? ? ? ? ? ? ? color2: '#cf8b17',
? ? ? ? ? ? ? ? id: 'control',
? ? ? ? ? ? ? ? name: '控制',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: 'a',
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.LOOP,
? ? ? ? ? ? ? ? ? ? ? ? text: '重復(fù)執(zhí)行 0 次',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new e());
}(Scratch));
(function (Scratch) {
? ? 'use strict';
? ? class f {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? color1: '#5cb1d6',
? ? ? ? ? ? ? ? color2: '#2e8eb8',
? ? ? ? ? ? ? ? color2: '#2e8eb8',
? ? ? ? ? ? ? ? id: 'sensing',
? ? ? ? ? ? ? ? name: '偵測(cè)',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: '?',
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.BOOLEAN,
? ? ? ? ? ? ? ? ? ? ? ? text: '啥都不偵測(cè)',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? ? ? '?'() {
? ? ? ? ? ? return "";
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new f());
}(Scratch));
(function (Scratch) {
? ? 'use strict';
? ? class g {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? color1: '#59c059',
? ? ? ? ? ? ? ? color2: '#389438',
? ? ? ? ? ? ? ? color3: '#389438',
? ? ? ? ? ? ? ? id: 'operators',
? ? ? ? ? ? ? ? name: '運(yùn)算',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: '800 + 800',
? ? ? ? ? ? ? ? ? ? ? ? disableMonitor: true,
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.REPORTER,
? ? ? ? ? ? ? ? ? ? ? ? text: '800 + 800',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? ? ? '800 + 800'() {
? ? ? ? ? ? return "16 百";
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new g());
}(Scratch));
(function (Scratch) {
? ? 'use strict';
? ? class h {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? id: 'data',
? ? ? ? ? ? ? ? name: '變量',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: '1 + 1',
? ? ? ? ? ? ? ? ? ? ? ? disableMonitor: true,
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.REPORTER,
? ? ? ? ? ? ? ? ? ? ? ? text: '1 + 1',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? ? ? '1 + 1'() {
? ? ? ? ? ? return "3";
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new h());
}(Scratch));
(function (Scratch) {
? ? 'use strict';
? ? class p {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? id: 'procedures',
? ? ? ? ? ? ? ? name: '自制坤木',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: '并夕夕',
? ? ? ? ? ? ? ? ? ? ? ? disableMonitor: true,
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.BUTTON,
? ? ? ? ? ? ? ? ? ? ? ? text: '積木被偷了?交1000塊錢幫你找回',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: 'emmm',
? ? ? ? ? ? ? ? ? ? ? ? disableMonitor: true,
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.COMMAND,
? ? ? ? ? ? ? ? ? ? ? ? text: '坤木被坤坤拿去打籃球了',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new p());
}(Scratch));
(function (Scratch) {
? ? 'use strict';
? ? class pen {
? ? ? ? getInfo() {
? ? ? ? ? ? return {
? ? ? ? ? ? ? ? blockIconURI: "data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHZpZXdCb3g9IjAgMCA0MCA0MCIgaGVpZ2h0PSI0MCIgd2lkdGg9IjQwIj48dGl0bGU+cGVuLWljb248L3RpdGxlPjxnIHN0cm9rZS1saW5lam9pbj0icm91bmQiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgZmlsbC1ydWxlPSJldmVub2RkIiBmaWxsPSJub25lIiBzdHJva2U9IiM1NzVFNzUiPjxwYXRoIGZpbGw9IiNGRkYiIGQ9Ik04Ljc1MyAzNC42MDJsLTQuMjUgMS43OCAxLjc4My00LjIzN2MxLjIxOC0yLjg5MiAyLjkwNy01LjQyMyA1LjAzLTcuNTM4TDMxLjA2NiA0LjkzYy44NDYtLjg0MiAyLjY1LS40MSA0LjAzMi45NjcgMS4zOCAxLjM3NSAxLjgxNiAzLjE3My45NyA0LjAxNUwxNi4zMTggMjkuNTljLTIuMTIzIDIuMTE2LTQuNjY0IDMuOC03LjU2NSA1LjAxMiI+PC9wYXRoPjxwYXRoIGQ9Ik0yOS40MSA2LjExcy00LjQ1LTIuMzc4LTguMjAyIDUuNzcyYy0xLjczNCAzLjc2Ni00LjM1IDEuNTQ2LTQuMzUgMS41NDYiPjwvcGF0aD48cGF0aCBmaWxsPSIjNEM5N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45MDMuNSAwIC45MDQuNDA0LjkwNC45MDR6Ij48L3BhdGg+PC9nPjwvc3ZnPg==",
? ? ? ? ? ? ? ? id: 'pen',
? ? ? ? ? ? ? ? name: '畫筆',
? ? ? ? ? ? ? ? blocks: [
? ? ? ? ? ? ? ? ? ? {?
? ? ? ? ? ? ? ? ? ? ? ? opcode: '并夕夕',
? ? ? ? ? ? ? ? ? ? ? ? disableMonitor: true,
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.BUTTON,
? ? ? ? ? ? ? ? ? ? ? ? text: '打開并夕夕(bushi',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ? ? {
? ? ? ? ? ? ? ? ? ? ? ? opcode: 'emmm',
? ? ? ? ? ? ? ? ? ? ? ? disableMonitor: true,
? ? ? ? ? ? ? ? ? ? ? ? blockType: Scratch.BlockType.COMMAND,
? ? ? ? ? ? ? ? ? ? ? ? text: '筆沒油了,現(xiàn)在并夕夕下單【九塊九】包郵送到家',
? ? ? ? ? ? ? ? ? ? ? ? isEdgeActivated: false,
? ? ? ? ? ? ? ? ? ? },
? ? ? ? ? ? ? ? ]
? ? ? ? ? ? };
? ? ? ? }
? ? }
? ? Scratch.extensions.register(new pen());
}(Scratch));