Added: 1 year ago
From: macheads101
Views: 6,782
Sort by time | Sort by thread (beta)

Link to this comment:

Share to:

All Comments (17)

Sign In or Sign Up now to post a comment!
  • Ive solved the error. The problem is in the paintcomponent method you should take the currentframe++; above the if statment. so first it incremets the frame then it test is current frame biger or equals otherwise the error will be

  • Well the problem is i get only 14 indexes registered not 15.

  • @EldarMK2 just subtract one from the maximum in the loop, I guess.

  • @macheads101 nope,doesnt help

  • @macheads101 or increment the current frame after calling it no?

  • By the same construction of the for loop, i got an array out of range error. I mean i gets ++ till its smaller the array.lenght wich is 15 if "i" gets 15 the loop will stop but at the las it will make i++ and so the program try to operate with array index 16 that is not available.... how can i solve that error ?

  • whenever i type extends jframe implements actionlistener it says java interface needed and anytime there is jframe it says not found. whats wrong with it .i'm using a hp computer, help pls

  • 8:50 - an errors.

  • I always get an error at animator = new Timer(delay, this); but I have my delay int and my implement -.-

  • I was wondering, because you placed counter++ before the call to paint the icon, would this program never actually paint frame 1, that's stored in index 0 of imageArray?

    Thanks for the tutorial

  • @DLNebelim

    Yeah it appears to skip a frame.

    He should increment after painting.

  • hi, thanks for your tutorial...

    now i can make my animation.

    but i want to ask you, how to save the animation to .gif?

  • where do you get those images?

  • Hey thanks a lot for the tutorials, I learned a lot. Just in case anyone was wondering, you can get rid of the run-time errors by swapping lines 24 and 25.

  • @veQue2 Thanks! You are right!!!

  • hey do u think you could make an atm machine in gui ??

  • nice

  • Awesome....Thank you

Loading...
Alert icon
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more