#Dynamic Tails & Banners

35 messages · Page 1 of 1 (latest)

mortal sundial
#

Steam: https://steamcommunity.com/sharedfiles/filedetails/?id=3720857242
Mod.io: https://mod.io/g/timberborn/m/dynamic-tails-banners#description

This mod adds Dynamic Tails and Banners to the game. Tails and banners can change based on certain conditions, including custom text and colors that display building or character stats. The mod is also expandable, allowing other mods to add their own dynamic tails and banners.

All dynamic tails and banners are neatly organized in the new Dynamic Tails/Banners group.

Dynamic Tails

This mod includes:

  • Weather Tails: the pattern changes based on the current weather condition.
  • Job Tails: displays the icon of the building where the beaver works.
  • Random Tails: choose from a list of patterns, and each day, one pattern will be randomly selected from the list. You can also optionally make all beavers share the same pattern each day.

Dynamic Banners

Similar to tails, there are also Weather and Random banners. In addition, there are two major banner types that can display icons and text. You can also choose the background color and font size.

  • Icon Stat: displays an avatar icon, such as a building, tree, healthy beaver, contaminated beaver, or sick beaver. It can also display a production building's recipe icon or a storage building's stored-good icon.
  • Dynamic Text: displays your own custom text or one of the relevant stats, such as storage stock, capacity, percentage full, production progress, or population-related stats.

Feel free to suggest any useful stats that I missed. I will be happy to add them. The Stat API is provided by Moddable Timberborn, so it can be used by other mods as well. The text rendering is also a new feature provided by TimberUI that other mods can use to draw text on their own textures.

limber cliff
#

Ideas: Font size should be a slider, and should allow higher values (up to ~200?)

#

Weird text wrapping when I set the text to abcdefghijklmnopqrstuvwxyz:

mortal sundial
mortal sundial
limber cliff
#

Any choice of fonts? or does it have to be Cascadia Mono?

mortal sundial
#

not for now, but I can add a select box by querying the installed fonts

#

Unity actually has an API for it

mortal sundial
limber cliff
#

I have both, testing on win at the moment

mortal sundial
#

it's using the monospace font for now

    public static readonly string[] MonospaceFonts =
    [
        "Cascadia Mono", "Consolas", "Courier New", // Windows
        "SF Mono", "Menlo", "Monaco", "Courier", // Mac
        "DejaVu Sans Mono", "Liberation Mono", "Ubuntu Mono", "Noto Sans Mono", // Linux
    ];

    public static readonly string[] DefaultFonts =
    [
        "Segoe UI", "Arial", "Calibri", "Tahoma", // Windows
        "SF Pro", "Helvetica Neue", "Helvetica", "Arial", // Mac
        "Noto Sans", "DejaVu Sans", "Liberation Sans", "Ubuntu", // Linux
    ];
#

oh I am surprised emoji doesn't crash it, only get ignored.

limber cliff
#

Have to use Kaomoji instead

mortal sundial
limber cliff
#

so unicode works, eg (◕‿◕✿)

mortal sundial
#

so that means fonts like Font Awesome does not work. darn

limber cliff
#

(╯°□°)╯︵ ┻━┻ works too

#

so does ☺

#

so maybe it's just color emoji's?

mortal sundial
#

it works if it's a UTF-16 char without surrogate pair. so ☺ is still in the UTF-16 definition.

#

and so technically Japanese and Chinese are safe, but not emoji

#

currently all the text glyphs' caching unit is char so I would have to rewrite the entire thing to support it, because surrogate pairs are 2 or more chars.

limber cliff
#

none: ☯, text: ☯︎, emoji: ☯️

mortal sundial
#

haven't heard of that

limber cliff
#

(none: \u262f, text: \u262f\ufe0e, emoji: \u262f\ufe0f)

mortal sundial
#

now I wonder how a video is played. is it just a render continously on a Texture2D?

mortal sundial
#

blueprint works too now 🙂

mortal sundial
#

font selection is now supported 😛

#

v10.0.1:

  • Fixed wrong wrapping issue (by updating TimberUI).
  • Added copy options for Power Copy and #1472989429382648008
  • Added Font Selection.
mortal sundial
#

v1.0.2: Fixed a crash when deleting a banner buildings or when beavers with custom decal die.

#

@cerulean laurel this should fix the crash your sent me

#

please tell me if it still happens.