Log inGet started
World

Lantern Depths: Find the Shade Dash, Slay the Thorn Knight

Branchmain
Branchesmain
Commitda5ac13948

README.md

art

The sideScrollerKit's sprite art in six looks (pixel, fantasy, scifi, cartoon, minimal, gothic) and the matching UI palette per look. Gates, shrines, save points and the HUD call it to put the right sheet on an entity.

local Art = require("sideScrollerKit.art")
Art.attach(gate, "gate.crystal", "fantasy")            -- adds/updates a pixelSprites.SpriteSheet, plays "idle"
Art.attach(gate, "gate.crystal", "fantasy", "break")   -- switch animation
local d = Art.sheet("save.bench", "scifi")             -- the SpriteSheet data, sizes in tiles
local pal = Art.palette("scifi")                       -- { bg, panel, ink, accent, accent2, good, bad, text } hex strings
  • Art.LOOKS, Art.SPRITES, Art.SPECS[name] (w, h in tiles and the animation rows).
  • Art.sheet(name, look) returns sheet (material identity), frameWidth, frameHeight, columns, rows, animations, pixelsPerUnit (16 for pixel, 32 for the others), widthTiles, heightTiles. Unknown looks fall back to pixel.
  • Art.attach(entity, name, look, anim?): the entity position is the sprite's bottom-centre (feet).
  • The sheets are only ever resolved through a generated table of string-literal asset.resolve calls, so components that require this module stay publishable.
  • anim on a SpriteSheet is a synced field and is not kept by a scene bake: call Art.attach (or set anim) at runtime, e.g. in a component's awake, not only in build.luau.

The art is painted by sideScrollerKit.artgen; regenerate with require("sideScrollerKit.artgen").generate() then .writeLookup().