Shortcut localised_description unused?

Place to get help with not working mods / modding interface.
Post Reply
Mernom
Fast Inserter
Fast Inserter
Posts: 122
Joined: Sun Jul 15, 2018 10:05 pm
Contact:

Shortcut localised_description unused?

Post by Mernom »

I've been working on a mod which adds a shortcut accessed selector item, and I've noticed that shortcuts don't display localised descriptions when moussed over, even if it's defined.

Now, I'm still on an older version (.19), but looking at the changelog, I don't think it was addressed at all. Is that still the case?

Pi-C
Smart Inserter
Smart Inserter
Posts: 1651
Joined: Sun Oct 14, 2018 8:13 am
Contact:

Re: Shortcut localised_description unused?

Post by Pi-C »

Just stumbled across the same problem: I've defined a Prototype/Shortcut with both localised_name and localised_description:
Both localised_name and localised_description exist and are different.
Both localised_name and localised_description exist and are different.
shortcut.png (61.81 KiB) Viewed 602 times
However, the only thing I see used in the game is localised_name:
Only localised_name is used.
Only localised_name is used.
keys_2.png (124.08 KiB) Viewed 602 times
Quite a dilemma: I feel I need a description because selecting an area will do something other (open a GUI with the selected entities, or add selected entities to an existing GUI for alt-select, or remove selected entities from an existing GUI for reverse-select) than clicking on a distinct position ("claim", "lock/unlock", or "summon" a single entity). But the description is too long to be useful as a title -- "GCKI: Keys" is short enough for that to see what kind of shortcut it is, and what mod introduced it.

Suggestion: In the list of available shortcuts (see the left red rectangle in the screenshot above), display localised_name, and use localised_description as tooltip for the shortcut hovered over with the mouse. In the quick-select shortcut list (the red rectangle on the right), combine name and description, so the tooltip is

Code: Select all

{"", {"shortcut-name.name-of-your-shortcut"}, ":\n", {"shortcut-description.your-description"}}
A good mod deserves a good changelog. Here's a tutorial (WIP) about Factorio's way too strict changelog syntax!

Post Reply

Return to “Modding help”