CharacterFonts

From Adventure Game Studio | Wiki
Revision as of 05:29, 19 August 2012 by Monkey'05'06 (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search
The printable version is no longer supported and may have rendering errors. Please update your browser bookmarks and please use the default browser print function instead.

The Character Fonts module by Alynn allows a user to set individual fonts to each character, and display those fonts while talking.

  Script header for module 'CharacterFonts'

  Author: James Favier (Alynn the Yellow Eyed)
   
  Abstract: Allows a user to set individual fonts to each
            character, and display those fonts while
            talking.

  AGS 2.71 and higher


 WARNING:
    Be sure you assign font numbers that actually exist on
    your game, it will break otherwise. Currently there is
    no way to check if the font exists beforehand. If that
    becomes available later I will incorperate it.

---------------------------------------------------------------
 Functions:

   SetCharFont(Character *ch, int font)
      This sets the number of the character (ch) and
      assigns it the font number (font).

   GetCharFont(Character *ch)
      Returns the font number currently in use by
      the character (ch).

   Say(Character *ch, String text)
      Works like Character.Say, but assigns the correct
      font first.

   SayAt(Character *ch, int x, int y, int width, String text)
      Works like Character.SayAt, but assigns the correct
      font first.

   SayBackground(Character *ch, String text)
      Works like Character.SayBackground, but assigns the
      correct font first.

------------------------------------------------------------------

 Version History:
    1.0 Released upon an unsuspecting population
    1.1 Should work with AGS 2.71, maxed out the number of
        possible characters, now uses pointers for the characters.

------------------------------------------------------------------