Skip to main content

Page

A class in Root.Township, Alta.Pages.

Asset for a fixed (hand-made) page, such as a recipe or lore page, with its glyph layout. Served by the static page provider.

Constructors​

MemberWhat it is
Page()Use ScriptableObject.CreateInstance instead of new; Unity loads the saved ones from assets.

Fields​

MemberWhat it is
static readonly Vector2 PixelSizePage size in pixels: 640 by 768.
static readonly float SizeRatioHeight divided by width of a page.
2 private and internal fields
MemberWhat it is
private HashedGeneralValue[] componentsBacking field for Components, the hashed assets shown on the page.
private PageData dataBacking field for Data, the page content. Reading Data first ties it to this page.

Properties​

MemberWhat it is
HashedGeneralValue[] Components { get; }Hashed assets the page refers to.
PageData Data { get; }The page's layout data, linked back to this asset before it's returned.

Methods​

MemberWhat it is
uint GetHash()The asset's hash.
int GetProviderID(int preferredProvider)Always the static page provider's id, whatever is preferred.
1 private and internal method
MemberWhat it is
private PageData Alta.Pages.IPageBasis.CreatePage(int preferredProvider)Explicit IPageBasis implementation: returns this page's static Data.

Used in​

Members of other types that take, return or hold a Page: