Files
001code-html--cocos/scratch-vm/test/snapshot/__snapshots__/tw-forkphorus-515-wait-zero-seconds-in-warp-mode.sb3.tw-snapshot
刘宇飞 6e0a1fbcbb Initial commit of 001code-html Scratch frontend project.
Includes scratch-gui, scratch-vm, scratch-blocks, scratch-render, scratch-l10n, and deployment config.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-06-16 15:37:45 +08:00

81 lines
3.1 KiB
Plaintext

// TW Snapshot
// Input SHA-256: a8576b7695ad77f7d5a7ac9fb76d31f026c0869f16f55d16fa40b85972b43e30
// Sprite1 script
(function factoryXYZ(thread) { const target = thread.target; const runtime = target.runtime; const stage = runtime.getTargetForStage();
const b0 = runtime.getOpcodeFunction("sound_setvolumeto");
const b1 = stage.variables["`jEk@4|i[#Fk?(8x)AV.-my variable"];
const b2 = runtime.getOpcodeFunction("looks_say");
return function* genXYZ () {
yield* executeInCompatibilityLayer({"VOLUME":0,}, b0, false, false, "d", null);
b1.value = 0;
yield* executeInCompatibilityLayer({"MESSAGE":"plan 1",}, b2, false, false, "g", null);
yield* thread.procedures["Wno refresh"]();
yield* thread.procedures["Wruns below with no refresh"]();
if (compareEqual(b1.value, 0)) {
yield* executeInCompatibilityLayer({"MESSAGE":"pass",}, b2, false, false, "v", null);
}
yield* executeInCompatibilityLayer({"MESSAGE":"end",}, b2, false, false, "f", null);
runtime.stopAll();
retire(); return;
retire(); return;
}; })
// Sprite1 Wno refresh
(function factoryXYZ(thread) { const target = thread.target; const runtime = target.runtime; const stage = runtime.getTargetForStage();
const b0 = runtime.getOpcodeFunction("music_restForBeats");
const b1 = runtime.getOpcodeFunction("music_playDrumForBeats");
return function* genXYZ_no_refresh () {
for (var a0 = 30; a0 >= 0.5; a0--) {
thread.timer = timer();
var a1 = Math.max(0, 1000 * 0);
runtime.requestRedraw();
while (thread.timer.timeElapsed() < a1) {
if (isStuck()) yield;
}
thread.timer = null;
yield* executeInCompatibilityLayer({"BEATS":0,}, b0, true, false, "m", null);
yield* executeInCompatibilityLayer({"DRUM":1,"BEATS":0,}, b1, true, false, "b", null);
runtime.ext_scratch3_motion._moveSteps(0, target);
}
return "";
}; })
// Sprite1 Wruns below with no refresh
(function factoryXYZ(thread) { const target = thread.target; const runtime = target.runtime; const stage = runtime.getTargetForStage();
return function* genXYZ_runs_below_with_no_r () {
yield* thread.procedures["Whas refresh"]();
return "";
}; })
// Sprite1 Whas refresh
(function factoryXYZ(thread) { const target = thread.target; const runtime = target.runtime; const stage = runtime.getTargetForStage();
const b0 = runtime.getOpcodeFunction("music_restForBeats");
const b1 = runtime.getOpcodeFunction("music_playDrumForBeats");
return function* genXYZ_has_refresh () {
for (var a0 = 30; a0 >= 0.5; a0--) {
thread.timer = timer();
var a1 = Math.max(0, 1000 * 0);
runtime.requestRedraw();
while (thread.timer.timeElapsed() < a1) {
if (isStuck()) yield;
}
thread.timer = null;
yield* executeInCompatibilityLayer({"BEATS":0,}, b0, true, false, "r", null);
yield* executeInCompatibilityLayer({"DRUM":1,"BEATS":0,}, b1, true, false, "c", null);
runtime.ext_scratch3_motion._moveSteps(0, target);
}
return "";
}; })
// Sprite1 script
(function factoryXYZ(thread) { const target = thread.target; const runtime = target.runtime; const stage = runtime.getTargetForStage();
const b0 = stage.variables["`jEk@4|i[#Fk?(8x)AV.-my variable"];
return function* genXYZ () {
while (true) {
b0.value = ((+b0.value || 0) + 1);
yield;
}
retire(); return;
}; })