MCPcopy Create free account
hub / github.com/melonjs/melonJS / patchU32

Function patchU32

packages/melonjs/tests/aseprite-parser.spec.js:67–70  ·  view source on GitHub ↗
(buffer, offset, value)

Source from the content-addressed store, hash-verified

65// patch a u32 length field after the fact (chunk/frame size is known once
66// the contents are written)
67function patchU32(buffer, offset, value) {
68 const view = new DataView(buffer);
69 view.setUint32(offset, value, true);
70}
71
72// build a minimal valid aseprite file header (128 bytes total)
73// named fields occupy the first 34 bytes; pad the rest to 128

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected