Expand description
yog-book — the renderer guide books (the .ybook format,
yog_formats::book) are drawn with, in the game and in Yog-IDLE
(BookRenderer, draw2d alone).
Re-exports§
pub use renderer::BOOK_PNG;pub use renderer::BookRenderer;pub use renderer::CRAFTING_PNG;pub use renderer::LANG;pub use renderer::PageDrawer;pub use state::BookViewState;
Modules§
- layout_
picture - What a recipe layout draws whatever the recipe — its images, its slot frames, its stations — as pieces in the layout’s own pixels: the book and Yog-IDLE’s recipe editor each draw these their own way.
- markup
- Book texts are Yog text (
yog_ui::rich:{b|…},{#rrggbb|…}, …) with words of the book’s own, turned into Yog text’s when the book is prepared: - recipe_
area - A recipe layout on an inventory screen (
<RecipeArea>): its pictures and stations as.yuielements, its places and result as real slots. - renderer
- Book renderer: yog-ui lays the book out and draws its text and
buttons; everything else goes through
draw2dtoo — the sprite sheets, item icons, SVG pages, entities — so the game and Yog-IDLE’s book designer run the same code. - state
- Per-book navigation state.
- theme
- Visual theme for book rendering.
Structs§
Constants§
- BOOK_
SHEET - The image sources the book draws
BOOK_PNGandCRAFTING_PNGas: the loader ships them underassets/yog/textures/gui/book/(Yog-IDLE resolves them to the bytes). The book’s pictures. - CRAFTING_
SHEET - The image sources the book draws
BOOK_PNGandCRAFTING_PNGas: the loader ships them underassets/yog/textures/gui/book/(Yog-IDLE resolves them to the bytes).
Functions§
- ingredient_
items ingredient— items, and tags (#ns:path) — as the items it shows in turn: each tag replaced by its items.- set_
tag_ items - Tells the books how to find an item tag’s items.
- set_
unlocked - Tells the books how to know what the reader has unlocked.
- shown
- Whether
entryshows in the book’s lists: not secret, and its advancement (if it waits for one) had.