Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include resource name with label #2

Closed
abaines opened this issue Apr 18, 2020 · 4 comments
Closed

Include resource name with label #2

abaines opened this issue Apr 18, 2020 · 4 comments

Comments

@abaines
Copy link
Owner

abaines commented Apr 18, 2020

Mutkanum

It is a Good mod for me. I like it. But it Will be perfect for me if it could put not only icon+quantity, but it adds a label (as "iron"+Icon+quantity, or copper+Icon+quantity).

It's important when number or resources multiplies with some big mods.

https://mods.factorio.com/mod/resourceMarker/discussion/5e498a64bdfade000da2c0ca

Add resource name to map-tag's text.

@abaines
Copy link
Owner Author

abaines commented Jun 9, 2020

So the problem is, what if there are two players on the same force (for which the tag will be displayed), and one speaks Klingon and the other speaks JavaScript. How can the script decided which localization to use?

LuaForce.add_chart_tag takes a string, not a LocalisedString. So somehow there has to be a way to pick which player to use for localization.

Could do something fancy with LuaPlayer.request_translation, like picking the player(s) with the most play time, or something. But this also gets complicated quickly, because the response is an event that will happen after the request for translation.

I think I'm just going to make a global setting that allows appending the un-localized resource name...

@abaines
Copy link
Owner Author

abaines commented Jun 10, 2020

144e5cb

@abaines
Copy link
Owner Author

abaines commented Jun 10, 2020

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant