Results 1 to 4 of 4

Thread: SetFont() method for Entity text

  1. #1
    Peasant
    Join Date
    Oct 2010
    Posts
    7

    Default SetFont() method for Entity text

    Hi Seth,
    I've made a little change in the source code that I think is really useful. I added a SetFont(...) method to the MovingEntity class so you can set the font you want to use without changing the fonts that come with the engine.

    There are too versions

    void SetFont( const string &resource_id)
    resource_id is the name of the font resource in the xml

    void SetFont( int font_id)
    font_id is the fontID used by the engine

    here is a patch in case you want to commit this change.

    MarcioGarcia_SetFont_20101115.patch

  2. #2
    Administrator Seth's Avatar
    Join Date
    Jul 2002
    Location
    Japan
    Posts
    5,377

    Default

    Thanks, added. Made some small changes so it it will also allow changing font, and not cause problems if the font can't be initialized.

    If you are going to be doing a lot of patches I will just give you svn write access... the only rule is to not breaking the existing demos.
    Seth A. Robinson
    Robinson Technologies

  3. #3
    Peasant
    Join Date
    Oct 2010
    Posts
    7

    Default

    Well, I can't say I will make a lot of patches. I am in the process of making my game and if I make something useful I will be glad to share it with other Novashell users.

    One thing that I would really like to add is Steering Behaviors, but I not sure if I should dive into the code to make such a big change. I need to finish my game.

  4. #4
    Knight
    Join Date
    Mar 2010
    Posts
    81

    Default

    I've made that modification too, a long time ago :P

    Actually my version of novashell is a lot different I think already...

Similar Threads

  1. What I would need to do to implement a new entity type or something?
    By speeder in forum Novashell Game Creation System
    Replies: 1
    Last Post: 08-18-2010, 05:10 AM
  2. texture drawing method questions
    By ppheathead in forum Official ClanLib SDK Forums
    Replies: 5
    Last Post: 06-10-2009, 07:19 AM
  3. How do I make an entity face a certain direction?
    By Jeral in forum Novashell Game Creation System
    Replies: 2
    Last Post: 12-14-2008, 07:44 PM
  4. Problem with turorial 'convert to entity'
    By hellbound007 in forum Novashell Game Creation System
    Replies: 2
    Last Post: 05-30-2008, 12:58 PM
  5. How to use gui without .run() blocking method ?
    By hubadu in forum Official ClanLib SDK Forums
    Replies: 3
    Last Post: 05-16-2007, 07:48 PM

Bookmarks

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •