Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6668701
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T03:04:10+00:00 2026-05-26T03:04:10+00:00

I created a sprite that is 18 frames long and it is supposed to

  • 0

I created a sprite that is 18 frames long and it is supposed to be stationary and run through the frames and loop the animation, but when it runs it moves slowly across the screen as it animates until it hits the last frame then jerks back to the original position where it was suppose to stay at.

I don’t know the reason it does this and have tried to make it smaller sizes and larger sizes, at some sizes it does not move but just animates likes its supposed to do.
If anyone has an answer to why this happens and how to stop it from moving and stay where it is supposed to be it would be greatly appreciated.

I use only 1 row for the sprite and I used gimp to create the sprite and saved it as a png.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T03:04:10+00:00Added an answer on May 26, 2026 at 3:04 am

    The code is rather long thats why I didn’t add it but it based on this tutorial
    aquarium live wallpaper tutorial

    I think I found my answer though, I had the png sprite in a folder I created named drawable, where I put all the images, I tried it again but put the sprite in the other folders this time and it didn’t move, I tried scaling the sprite also which made it go a bit wonky, I was hoping on using scaling instead so it stayed the same size for all screens, this works for normal images but for sprites it causes some issues, maybe I’ll try that with the largest size in the drawable-large-mdpi folder and see if it causes any issues that way.
    I’ll update with that method and let you know.
    It would be nice to have just one image and scale it instead according to screen size.

    Okay I found the answer finally and it might help those creating sprites,the width when divided into the amount frames has to be a whole number since the measurements are in int not float or double, so it moves because when the frame gets divided it came out to a fraction instead which caused it to moves (I guess) whatever that float extra measurement was.
    Example: if the sprite was 100 pixels high and 1082 px wide and I had 15 frames the width of each frame would then be 72.133333333px wide for each frame causing an error that would move the image that extra length while keeping the animation looking nice. now if it was 1080px wide each frame would then be 72px wide a nice whole number and then would animate perfectly.
    So for those creating there own sprites make sure the wide equals out to be a whole number when the frames get divided (My problem was I was creating one image scaling it down and not checking the width of each frame so only one image size usually work, sometimes I got lucky and got two, I should of figured this out because it all runs in int not float for measuring the width.
    Hope this helps out someone else making sprites.
    Sam

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

i've only ever created external .as files that extended a class such as sprite.
How can you add data to a dynamically created MovieClip/Sprite so that the data
i've created a full spectrum color wheel Sprite object that is composed of 1440
i've created a bitmap with data and placed it into a sprite so to
i've created a sprite to drag and drop around the stage. the sprite is
I've created an image which is basically a CSS sprite of 3 images together.
I'm starting on a javascript MMORPG that will actually work smoothly. Currently, I created
I want a sprite that blinks so that it displays frame 1 for say
I have a CCLayer class where I create an animated sprite that is the
I've created a basic orthographic shader that displays sprites from textures. It works great.

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.