Skip to content

OnlyWorlds Unity SDK 0.38.0

Choose a tag to compare

@tmoosting tmoosting released this 10 Nov 04:12
· 301 commits to main since this release

The map-space profile's layout reading, on schema-dist serial 111. Parity with the TypeScript SDK 4.142.0 (layoutOf)
and the Python package 0.110.0 (layout_of), their test vectors ported, and with the TypeScript SDK 4.144.0 for
OWAiUse.CanPay. A minor release because it adds public API (below).

Added

  • OWMapSpace.LayoutOf(map, maps, pins): one Map's layout keys (the map-space profile's rules 8 to 10, serial 110),
    answered as an OWMapLayout whose ToJson() is the profile's {layout, ground, hand}. Layout is the Map's
    x_layout.method when x_layout is an object whose method is a non-empty string ("hand" for a board,
    OWMapLayout.Board; a method no page names answers itself), else null. Ground, only on a layout map, is the id in
    x_layout.settings.ground.map when it names a Map in maps other than this one, else null; its size is not
    returned, since the served Map's own size wins. Hand is the ids, in code point order, of this Map's Pins a new
    lay-out keeps where they are: every Pin on a board, the Pins whose x_hand is exactly true (never "true" or
    1) on any other layout map, none on a Map that is not a layout map. pins may hold every Pin the caller has: the
    reader keeps those whose map names this Map, reads rows as OWMapSpace.Of does (a row without a non-empty string
    id is no element, a Map row without one no layout map; of two rows with one id the last served), and counts a Pin
    whose element it cannot see. A method's own settings are never read, and nothing here lays Pins out: a tool that
    cannot run a method draws the Pins where they are. OWMapSpace.Of is unchanged and reads neither key.
  • The fixture's twenty-one layout_cases (seventeen at serial 110, four more at 111) pass case by case, whole answers
    in key order, the count held, beside its 34 cases. A case names the Map it reads by map (its id) or, for rows
    with no id, by map_index (positions in its elements), and the replay reads every row a case names. The two
    packages' vectors beyond the fixture are ported (code point order above U+FFFF, the row readings, a method or a
    ground that is not a string, settings never returned).
  • OWAiUse.CanPay (can_pay on AiUsesAsync's rows), parity with the TypeScript SDK 4.144.0: true when a call
    by this account would be paid now, by the same check the call runs (On, the server's daily cap, today's token
    rating against RatingNeed, or a saved AI key that runs the use). Offer a use only when it is true. The server's
    fifth use, lens, is reached through AiAsync("lens", body) and answers as served; it is not typed.

Changed

  • The schema pin moves to v0.34.0-dist.110, then v0.34.0-dist.111 (canonical 00.34.00 unchanged, no schema
    file moved). Serial 110: the map-space profile gains its layout keys, rules 8 to 10 (x_layout on a Map, its
    ground, x_hand on a Pin), and a second, small reading of one Map with seventeen layout_cases beside the
    fixture's cases, which keep their 34 entries unchanged. Serial 111: four more layout_cases (twenty-one: code
    point order, a repeated Pin id, a Pin row and a Map row without a string id), the page's sentence that a Map row
    without a string id is no Map, and a case that names the Map it reads by map_index (positions in its elements)
    when the row has no id. The generated models changed in their serial and published stamps only; the map-space
    fixture's test copy moved with the pin.