Lode - Minerals That Draw Themselves
A downloadable asset pack
Ore, gems and specimens for GameMaker, computed from a seed and drawn in pure GML. 48 species, 21 crystal habits, 10 lustres, 10 zoning programs, 10 cuts, 8 host rocks. No sprites, no atlas, no texture page.
This is not a crystal sprite pack. It is the thing that makes them.
The mineral shelf for GameMaker is static art: a folder of PNGs, a fixed set of pictures, and nothing behind them. That is fine until your game needs a stone nobody drew, a half-polished amethyst, a pyrite the player mistook for gold, the forty-first mineral when the pack shipped forty.
Lode ships the generator. A stone is two integers, a species index and a seed, and everything else is computed. Its picture and its physics are the same row: lod_species() returns a species' habit, lustre, zoning, cut, host rock, depth band, Mohs hardness and density together, and the drawing reads the same numbers the assay does. There is no second table and no synchronisation step, so you cannot reach a state where a stone looks like corundum and files like chalk.
What it generates
- 48 species, each a real combination of habit, lustre, zoning, cut and host rock.
- 21 crystal habits, drawn as different constructions rather than one shape at different widths: prismatic, acicular, botryoidal, dendritic, geode, massive, tabular, rhombohedral, octahedral, cubic, bladed, stellate, druzy, fibrous, reniform, columnar, encrusting, scalenohedral, wire, nodular, pyritohedral.
- 10 lustres, 10 zoning programs, 10 faceted cuts, 8 host rocks.
- Every stone renders as a raw specimen in matrix, an extracted rough, a cut gem and a polished cut. That is 124 distinct drawn objects before palettes.
The whole loop, not just the art
Prospect a depth band, assay what you pulled up, cut it with a tool that is hard enough or watch it shatter, polish it, price it, and file it in a specimen cabinet scored by best state.
lod_prospect(depth, seed)a species at that depth, or-1for an empty pan. The empty pan is the point.lod_assay(stone, skill)density and hardness as read, plus a candidate shortlist.lod_cut_outcome(stone, tool_hardness, skill, seed)skated off, cut, or shattered.lod_value(stone)/lod_price(stone)what it is worth, rising with work.lod_cabinet_new / _add / _completion / _missingthe collection.
Every one of those is a pure function: no draw calls, no instance variables, no room state, so you can call them from a server, a unit test or a save-file migration.
The four functions that are the product
var _stone = lod_specimen(lod_species_index("Amethyst"), 20260831, 0);
lod_specimen_draw(_stone, x, y, 96, 96); // draws it, fitted, uniformly scaled
show_debug_message(lod_specimen_label(_stone)); // "Amethyst in basalt"
show_debug_message(lod_price(_stone)); // what it is worth
A stone is a species index and a seed. Store those two numbers, that is the whole save format. A finished specimen caches to a sprite with one call when you need the frames back.
What is in the box
- A
.yympslocal package: import it, openrm_lod_demoand press Play. That room is the whole API in one screen. - Raw, readable GML across 18 scripts. No minification, no extensions, no shaders, no native calls, no internet access.
- Everything namespaced
lod_/LOD_, because GML's global namespace is flat and a collision in your project is a support ticket nobody can debug remotely. - 4,696 in-engine assertions that ship with the package. Build the project and launch it with
-selftestto run them yourself.
Compatibility
GameMaker Studio 2.3+ and GameMaker 2024.x. Built and verified against runtime 2024.14.4.268, the legacy GMS2 runtime that GameMaker has committed to supporting with SDK and critical fixes until at least Q1 2028. It is pure GML with no extensions or shaders, which is the shape GMRT's stated 99% compatibility carries forward.
Stated plainly
GML cannot be unit-tested outside the engine. Everything above is a real Igor build and a real run: exit 0, 0 errors, 337 resources compiled, 4,696 assertions with 0 failures. Every image on this page was rendered by the package's own GML through an Igor-built executable, not by a previewer. The suite computes points and numbers; it cannot see a fill rule or a picture, so those were checked by opening the rendered sheets and looking at them.
AI disclosure
This package was written with AI assistance. Code: yes. Graphics: yes, and there are no graphics files; every image is drawn by the GML in this package at runtime. Sounds: none. Text: yes.
Also from CSAF, for GameMaker
Armoury — weapons is what the ore becomes. Lode generates the minerals and the prospecting; Armoury forges the weapons and tracks what happens to them afterwards.
Chitin — insects · Raiment — characters and clothing · Pastime — minigames · Liege — the NPC day · Charter — auto-cartography · Verdure — cultivation · Effigy — NPC portraits · Hearth — interiors
| Updated | 2 days ago |
| Published | 9 days ago |
| Status | Released |
| Category | Assets |
| Author | CSAF — Core Systems Asset Factory |
| Made with | GameMaker |
| Tags | 2D, crystal, GameMaker, gems, Generator, gml, minerals, mining, Procedural Generation, sourcecode |
| Languages | English |
| AI Disclosure | AI Assisted, Code, Graphics, Text |
Purchase
In order to download this asset pack you must purchase it at or above the minimum price of $12.74 USD. You will get access to the following files:









Leave a comment
Log in with itch.io to leave a comment.