Wintermute Engine Forum

Wintermute Engine => WME Lite => Development => Topic started by: lazygames on June 06, 2011, 10:34:59 AM

Title: [iOS] problem with ttf fonts
Post by: lazygames on June 06, 2011, 10:34:59 AM
Hi! I have a problem with using ttf-font under iOS/macOS.
Quote
However, on iOS the engine is not able to access the system font directory, for that reason you MUST include .ttf files with the iOS version of your game.

How do this? I create comic.font file with this content:
Code: [Select]
TTFONT
{
  SIZE = 12  
  FILENAME = "fonts\comic.ttf"
  COLOR { 100, 0, 0 }
  ALPHA = 255
}

if launch wmelite on windows - everything ok! Window object loading and text on screen.
if launch on iOS (macOs too) - Game.LoadWindow return null.

Any ideas where is the my wrong?

P.S. I try use bitmap font - everything work's good!
Title: Re: [iOS] problem with ttf fonts
Post by: Mnemonic on June 06, 2011, 10:50:57 AM
You must ensure that the .ttf file is compiled in the game package. To do so, open the project settings in ProjectMan, go to the "Filters" tab, and remove the *.ttf extension from the "Copy as is" field. Ideally move *.ttf to the "Do not compress" field instead, so that the font can be accessed faster.
Title: Re: [iOS] problem with ttf fonts
Post by: lazygames on June 06, 2011, 11:19:13 AM
Thank's a lot!
I forget about this settings!