Package org.openpatch.scratch.extension
package org.openpatch.scratch.extension
The public extension API: what an extension jar uses to add to Scratch for Java without
touching its internals. First-party extensions (tiled, save, recorder, drawing) are built on
it alone, which the build checks.
Desktop only: the online IDE has every first-party extension built in and loads no others.
-
ClassDescriptionWhat a layer drawer draws with: it records into the draw list, nothing is drawn at once and no OpenGL is exposed.An extension: found through
ServiceLoader(a line inMETA-INF/services/org.openpatch.scratch.extension.Extension) or registered withWindow.use(...), installed once when the window is created.What an extension may hook into.Decoded pixels from an image format of an extension's.A drawn frame at stage size; its pixels are read back only when asked for.Turns the bytes of an image file into pixels; runs on loading threads.A slot in the input snapshot: polled on the window thread, copied to the game thread with each batch of ticks, so no locking is needed.The window thread's side of the input snapshot, filled byExtensionContext.onInputPoll(Consumer).A key went down or up (auto-repeat never arrives).Draws into a layer of a stage.An exception from learner code, with the learner's frame (null if there is none).Something the mouse did, in stage coordinates.What happened.