Hi everyone :)
I have a quick question regarding fonts, or, more to the point, the usage of 2 different fonts. Now, I did look through both the manual and this subforum, but I didn't find a solution to my liking.
So, what I want to do is this: I have the character and an NPC, talking to eachother. However, for the NPC I want to use a different font, to suggest it uses a different language. The font used for this would be a separate one, with none of the letters actually looking like letters :)
Now, I've found 2 solutions so far: either replace unneeded characters in the font with the NPC's characters, or replace the upper- or lowercase letters in the font.
However, I'd rather not do that.
So, is this possible? If so, how?
Thanks :)
Import a second font, and use SetSpeechFont (http://www.adventuregamestudio.co.uk/manual/SetSpeechFont.htm) to switch between them for the different characters. You might be interested in Alynn's CharacterFonts Module (http://www.adventuregamestudio.co.uk/yabb/index.php?topic=27485.0), which does most of the coding for you. (Although, if it's only for one NPC, it's easy enough to do yourself - Alynn's code may still help.)
If you've already seen this, and it's 'not to your liking' - Sorry, AFAIK it's this, or the way you suggested. If you explained why you don't like it, maybe it could be worked around.
Bah beat me to plugging my own module :P
Thanks for the replies, guys :)
I'll have a look at the module -- it seems like the best solution.
As to why I didn't like the replacing font characters idea, it's because of 2 things:
1. I want to use all the available characters
2. I don't want to write gibberish for the NPC, because my idea involves translatng what the NPC says; that is, EGO is supposed to find a translator; is he has it, the NPC will speak using the regular font; if not, the NPC will say the same things, but using the alternate font.
Very easy to do with the charfont module
Say font 2 is your untranslated font, and font 3 is your translated font. cForigner is your character to be translated
if (player.InventoryQuantity(iTranslator.ID) == 1) {
CharFont.SetCharFont(cForigner, 3);
}
else {
CharFont.SetCharFont(cForigner, 2);
}
^ You da man :D