[batch] Compress Russian strings (transliteration)
1 Attachment(s)
Purpose:
Decrease number of bytes of the Russian string by replacing Russian letters by English analogue.Script:
Spoiler
Using: 1. Save your string in file "newnames.ini" |
Re: [batch] Compress Russian strings (transliteration)
Hmm. If you have limited buffer size you just can cut nickname, no?
|
Re: [batch] Compress Russian strings (transliteration)
Like, cut original nick "Nice Assistant" to "Nice Ass" ? :DDD
No. It depends. Where you want to preserve original word completely without any cutting, it is a case. There are lot of use cases. Upcoming examples: - translation in panel: https://forums.alliedmods.net/showpo...5&postcount=22 - Name changer for bad names: https://github.com/Exle/Auto-Name-Changer (I'm often fill new names for replacement that exceed the limit. Since I usually create > 20 options it is a lot of text to replace it manually) - or even if you want to create nickname for yourself that contains russian letters that exceed maximum string size allowed in total. |
Re: [batch] Compress Russian strings (transliteration)
Quote:
I mean i actually don't see big problem in cutting, cause in 80% of cases buffer size is big enough. I knew only one case where i needed smart cutting - vscripting. Buf size for vscript menus is 128 bytes. For that cases i just wrote algorithm which cut long names and replace ending with dots (...) |
Re: [batch] Compress Russian strings (transliteration)
Quote:
But if you insist: here is a name for auto-name-changer: Code:
setinfo name "Ведьмак Колокольчикус" Maximum allowed is 31 byte + NULL. I don't imagine how to cut this nickname without loss of its meaning other than apply transliteration. |
Re: [batch] Compress Russian strings (transliteration)
It's good try to solve Players problem.
But are you sure it's problem really exists? In all menus you enough see name part to determine player and apply any action (vote/etc.). Where did you see the need to show the full name anyway? And this does not negate the fact that you can specify an even longer name, in the general case, the problem is not completely solved. Yes, i understand russian. And i have some russian game servers for L4D2. |
Re: [batch] Compress Russian strings (transliteration)
I don't understand what are you trying to explain me.
It is always good to show full name instead of cutted. Ask anybody. E.g. if my name Stanislav will be auto-cutted to Stanisla, I will not be happy at all. Quote:
Also ++ Here: https://www.dropbox.com/s/l0twg83fhi...names.png?dl=0 And here: https://www.dropbox.com/s/rgjoizx8rf...ames2.png?dl=0 About second: when my server has 16 players, sometimes it is a case for limit of panel buffer. You can use the same replacement technique in plugin to show full names without need to cut anything. |
Re: [batch] Compress Russian strings (transliteration)
I don't try explain or teach. I try to understand. Sorry if i disappointed you.
I just have another point of view and now i got what i wanted - "It is always good to show full name instead of cutted.". It's ok and good job for that case. |
All times are GMT -4. The time now is 06:10. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.