Results 1 to 3 of 3

Thread: Sprites

  1. #1
    Squire
    Join Date
    May 2009
    Location
    South Africa
    Posts
    11

    Default Sprites

    I had a problem of 'sliding' when a sprite walked across the screen, AKA the moonwalk. This was, of course, because the amount of pixels that they moved per tick did not equal the amount of pixels that each frame was supposed to move.

    So I included the offset_x and offset_y for each <Frame/> element in the XML document describing the sprite. Is it my imagination, or does the offset_x really dictate the movement as well. Ever since I included that information my animations seem a lot better, though it 'could' be my imagination.

  2. #2
    Squire
    Join Date
    May 2009
    Location
    South Africa
    Posts
    11

    Default

    Lets say I have a spritesheet. Is it efficient to have 8 animations on it? I mean would each sprite have its own copy of the spritesheet, or do they share it. I assume that it is shared but I just wanted to make sure.

    Thank you!

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

    Default

    So I included the offset_x and offset_y for each <Frame/> element in the XML document describing the sprite. Is it my imagination, or does the offset_x really dictate the movement as well.
    The offset setting only changes where the sprite is drawn. Those .xml settings can also be modified from within the engine.

    It doesn't change the animation speed or entity movement speed, but having it properly lined up does make it look better when an entity turns or such though.

    Lets say I have a spritesheet. Is it efficient to have 8 animations on it? I mean would each sprite have its own copy of the spritesheet, or do they share it. I assume that it is shared but I just wanted to make sure.
    Yep, the spritesheet is shared.
    Seth A. Robinson
    Robinson Technologies

Similar Threads

  1. Sprites and more...
    By Ledorax in forum Novashell Game Creation System
    Replies: 8
    Last Post: 09-28-2009, 04:47 PM
  2. Problem: Using sprites after a gui.run
    By nokturn in forum Official ClanLib SDK Forums
    Replies: 0
    Last Post: 05-16-2007, 06:44 PM
  3. Sprites
    By lixopmstp in forum Official ClanLib SDK Forums
    Replies: 4
    Last Post: 01-21-2007, 02:36 AM
  4. Sprites and Surfaces
    By ART_Adventures in forum Official ClanLib SDK Forums
    Replies: 1
    Last Post: 09-22-2006, 10:03 AM
  5. sprites
    By seyah3 in forum Dink Smallwood HD
    Replies: 0
    Last Post: 02-03-2006, 03:05 AM

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
  •