Sorting Large Garages

Post Reply
User avatar
Axel Slingerland
Posts: 6470
Joined: 22 Oct 2013 07:55
Location: The Lost Coast

Sorting Large Garages

#1 Post by Axel Slingerland » 28 Oct 2014 06:52

I don't know if this is actually what SCS would call a "bug" or not. It might just be that I don't know beans about the Swiss and Polish alphabets. But I noticed that when you sort large garages alphabetically, that Lodz shows up at the bottom of the list, after Zurich. Sorry, my KB is not set up for some of the characters used in these names in their native languages as they appear in the game and in this list. It's an American KB, after all. However, Google Maps lists both cities that same way. That is why I thought this was at least worth mentioning. It is is intentional, feel free to delete this thread. (There is no need to keep it if it's useless...)

[ external image ]
[ external image ]

Boycott YouTube for Blocking Ad Blockers
User avatar
ohaha
Posts: 11345
Joined: 07 Dec 2012 06:31
Location: Watchin' y'all
Contact:

Re: Sorting Large Garages

#2 Post by ohaha » 28 Oct 2014 06:55

Probably the game sees it as a special character and places it after the last normal letter.
The alpha-numerical ordering differs from one system to another.
e.g. I saw systems where non-capital letters go first, followed by capitals. But, the game uses a different system, and you can clearly see that in the order your mods get loaded: digits first, then capitals, then non-capitals... I think it's some Linux based ordering...
Retired, but still loving it.
User avatar
Axel Slingerland
Posts: 6470
Joined: 22 Oct 2013 07:55
Location: The Lost Coast

Re: Sorting Large Garages

#3 Post by Axel Slingerland » 28 Oct 2014 07:56

Oh well... It seemed odd, so I posted it. But your idea seems quite plausible. Stranger things have happened on Windows based computers.
[ external image ]

Boycott YouTube for Blocking Ad Blockers
User avatar
Cadde
Posts: 6800
Joined: 24 Apr 2013 18:08
Location: Have no fear, i am from the internets!

Re: Sorting Large Garages

#4 Post by Cadde » 28 Oct 2014 12:01

While the question doesn't target the same language. The underlying library does.

http://stackoverflow.com/a/1098160

Basically, it depends on what sorting algorithm and locale you are using.
And what is happening here (in game) is that "ä" = char(228) comes long after "z" = char(122), so it's sorted after z rather than a.
Numbers are sorted before abc...xyz because they appear at char 48 - 57.

http://www.ascii-code.com/

EDIT:

"Ł" isn't part of the standard extended ascii table. So i used "ä" instead.
But the same pretty much applies for unicode if you sort by their position in the table.

In other words, SCS just needs to use a different sorting algo.
But here's where we get into regional differences and localization. Nightmare i tells you. NIGHTMARE!
On extended hiatus.
User avatar
Axel Slingerland
Posts: 6470
Joined: 22 Oct 2013 07:55
Location: The Lost Coast

Re: Sorting Large Garages

#5 Post by Axel Slingerland » 28 Oct 2014 16:51

Cadde wrote:In other words, SCS just needs to use a different sorting algo.
No, I don't think so. I did not think like the computer geek I used to be, and if I had I would have realized what was happening right away. Ten years ago I would have realized what was going on there right off, and wouldn't have given it a second thought. Now days, I need a memory upgrade... And a processor upgrade probably would most likely do me a lot of good as well! [ external image ]
[ external image ]

Boycott YouTube for Blocking Ad Blockers
User avatar
Max
SCS Software
Posts: 6479
Joined: 26 Nov 2012 10:00
Location: SCS, Prague

Re: Sorting Large Garages

#6 Post by Max » 29 Oct 2014 08:01

there is simple char code sorting, thus all not-so-standard characters will be after "Z". most of the time its not a big issue, only Lodz has such character on first place.

and would you read release notes for beta you would see that in 1.14 this was handled by adding special sort string for cities like Lodz .. ;)
Nobody can tell you anything about it. Those who know about it aren't allowed to talk. And those who talk know nothing.
Post Reply

Return to “Bugs 1.11”

Who is online

Users browsing this forum: No registered users and 1 guest