Find province command
-
Yeah, with maps becoming larger over time, this is a good feature request. Added to features list.
-
@zlefin Just a mock up. I find visuals very helpful to underscore how something should look or perform.
-
Nice feature request. Might I add that empire management games seldom have the territory/planet search feature more than one click away. Adding this feature to the menu of TripleA will most likely make it two clicks away. But I guess it is better than nothing

Still, if there is ever to be an effort into redesigning the TripleA UI to a more aesthetical layout version, this feature should probably implemented as a small search button/spy glass near the mini map.
And it would be nice if the search window could also lead to a possible territory name list that was scrollable and clickable, leading also to a centering/highlighting of the territory.
Also, maybe a txt file in the map dir could be made to contain a list of none-searchable or hidden territories. A am ofcours thinking of fake territories, like map space used graphically for info or as menus.
-
@zlefin And then you realize you have no idea how to type "Lh没n" or "Lands of the 脡oth茅od" into the territory finder
-
@alkexr Of course, such a feature should better be able to select the closest name to what you're typing, amongst the available ones.
-
ah, ok hepps, nice mockup then, so good I can't tell i'ts not already in game

the use of non-standard characters can indeed be quite a problem; no good way around that unless you enforce a prohibition on non-standard characters in provinces. or you need some sort of mapper that converts non-standard ones to standard ones for matching purposes. and thus every non-standard character needs to have a standard one it clearly maps to (which is true for diacritics, as often happens in lotr stuff iirc)
What hotkeys do we have available to assign this to? Is F available? or ctrl-f maybe given how often that's used for find in different applications? not that we need be in any rush to decide on the hotkey.
-
Couldn't the search line simply ignore the special characters? Instead looking for a match in simply spelling?
So "Lh没n" could then be searched as Lhun?
or "Lands of the 脡oth茅od" could be searched as Lands of the Eotheod?
-
@hepps You'd need a way to map the special 没 character to u and 茅 to e. Essentially a list of supported character mappings.
-
@hepps Yeah, of course, the program doesn't see the characters looking similar to some basic ones, unless of course a full list telling it so; and anyways either the special characters may look or ever be not just a variant of a basic word, for example you can have 脝lf, and you cannot say that is an A or an E, since it became an E in "elf", but it became an A in "Alfred", or you can have words that are multiple, like the German 脽, that would be an ss or sz (also the English W is not a word of the actual Latin alphabet, and started as a way to mean VV, but, of course it's now not "special", but just because it is English (if the Germans would have decided what is standard, probably the 脽 would be on all the world's keyboards as well)) or you can have words that look like some, but eventually became something totally different, like the Polish 艁, that is practically the same sound as the English "W" or Italian "U".
-
Cool, was just making an uniformed suggestion.
-
Could a new properties file be added for games that use special characters?
Say... a "Search Properties" File
Where the map maker defines the plain English character for any and all special characters used within a game?
-
Just wanted to leave this here so people don't spend a lot of time thinking how to convert accented characters to unaccented characters for this feature... In most programming languages (including Java) one can find a library to "normalize" Unicode accented characters to pairs of the corresponding unaccented characters and characters representing the accent marks themselves. Therefore, with some creativity, it should be possible to match the unaccented text a user types to the accented territory names specified in the map.
I was planning on taking a look at this feature, in general, this weekend, but not sure if I'll get to this specific aspect of it.
-
@ssoloff Does it support also alternative characters, like seeing 欠 as W? And how does that work for stuff like 脝 or 脽?
-
@cernel Normalization typically only handles diacritics, and so would not modify the character examples you provided.
If those characters are typically used in maps, and we have to handle them, Java does provide a way to customize how strings are collated so that, for example, "ss" would be considered equal to "脽". However, that's a bit trickier to get right in all scenarios.
Are there examples of such characters in maps today? Or are you simply envisioning them as a possibility in the future?
-
@ssoloff said in Find province command:
Are there examples of such characters in maps today?
Don't think so. Actually, "Battle for Arda" is the only map I can think of with any special characters at all.
-
@cernel Then I'd suggest we just focus on accented characters for now and deal with other issues, such as ligatures, if and when they arise. It will keep the code simpler.

-
Before adding support for strange and very rarely used characters, maybe we should think about if players/people are actually able to chat-type the characters, know what they mean or even pronounce them. Maybe, apart from using the characters for the displaying of territory names visually correct (like in LotR), it might not be smart to implement weird (and unknown to many) characters that people can't use or read correctly.
Most languages have italic style stand-ins for their special characters for practical reason. Maybe that is actually smarter than presenting strange unrecognised characters.
I'm totally for the support of new characters, but I would never use any that might not be obvious and easily recognized when it came to the reading of the characters.

-
There is a pending PR for the first iteration of this feature: https://github.com/triplea-game/triplea/pull/4115
A question that has come up is where would most users expect to find the new Find Territory... command on the TripleA main menu. Typically, such "find" commands would appear on an application's Edit menu. As TripleA has no such menu, this leaves choosing an appropriate location for the new command a bit less straightforward.
As proposed in the above PR, it is at the bottom of the Game menu. Other proposed locations have included:
- Somewhere else on the Game menu (e.g. at the top).
- Somewhere on the View menu.
- Somewhere on the Help menu.
- As the sole item on a new Search menu (which could appear, for example, between the File and View menus).
Any other ideas beyond those proposed above are welcome, as well.
-
I wonder if, in addition to wherever else it is placed; there should be an instance of it in the "territory" tab on the right side of the screen, i.e. when you have the territory tab selected. (the place that also has notes, actions, players, etc)
-
@zlefin I failed to mention above that, as part of the aforementioned PR, the hotkey
Ctrl+Fwill also bring up this feature.If a sufficient number of users feel having an additional Find Territory button on the Territory tab, presumably under the Battle Calculator button, is beneficial, we can certainly add it. If such a button were added, my guess is whatever territory is currently selected in the Territory tab would be used to seed the Find Territory dialog. That, in and of itself, is probably useless since the user already knows where the selected Territory is because they selected it.
But another access point for the dialog couldn't hurt.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 馃挆
Register Login