So, I posted this on github in our repository. I've been considering to fix the naming rule for the voice clips to let avoid conflicts when characters have identical first 4 characters. My proposal was to instead require using a full character name in the clip names.
https://github.com/adventuregamestudio/ags/issues/1456
But then I found there's another separate possible conflict, that is when character name has digits in it.
For example: character names are cGuy1 and cGuy11. And you do this:
cGuy1.Say("&11 word");
cGuy11.Say("&1 word");
Both will result in a voice clip name "guy111".
This of course is a very rare case, but it's still possible. Which means that the current rule has a loophole.
Besides, having any digits in character's name makes following clip number harder to distinguish.
The only way to avoid a situation like that completely is to separate name and number with a symbol that cannot be in a scriptname, but can be in a filename. Such symbol as a dot ('.') or a hyphen ('-'), or else.
I.e. make voice clips called like: guy1.1.ogg or guy1-1.ogg.
What do you think about this?
Yeah, makes sense. Maybe a space? Just looks better aesthetically, IMO... As long as that doesn't interfere with any command-line tools (where spaces in file names often require special handling).
I would prefer no spaces. Spaces are evil and should never exist, everyone should just speak in german.
So, I am ready to merge this in, the only doubt is separator.
I did it with a dot, which makes it look like
- "MyCharacter.1.ogg"
or
- "MyCharacter1.1.ogg" - example of character name with trailing digits.
An alternative is a hyphen, which will make it look like
- "MyCharacter-1.ogg"
or
- "MyCharacter1-1.ogg"