Is there any way to do this:on action event,many times paint?

now i am designing a gui game like russia,
i want to record all the steps of the playing,liks
enity[x] up
entity[y] down
when playser click the button ,I want to replay all the steps,unfornately,
the repaint will happen only once.
for(int i=0;i<allsteps;i++)
entity[x].move();
//when move(),the panel must repaint,but it will not happen.
//how can i achieve it?
}

All the paint requests probably get merged into one, so you only see the last one.
Use a Timer to schedule a move to be played back every x milliseconds.

Similar Messages

Maybe you are looking for

  • Multiple Copies of Same Song:

    Hi, The title may indicate that this is probably a redundant post... I don't think it is. I searched several terms with no success for my question. Here goes: I'm curious about why I have two folders per artist: one in /Home/Music/ and one in /Home/M

  • For those considering the new MBA, a short review.

    I've had my new MBA (1.86GHz, 128 GB SSD) for two days, and I'm delighted with it. I thought, therefore, that it might be useful to post my experience with the machine for anyone considering buying one. The first thing I noticed was how incredibly fa

  • N900 wifi critical issue

    I'm having so much trouble using wifi. and I spent two weekends figuring out a workarround of my problem. When Ever I go out of range or switch off my wifi router while my n900 conntected to it. After some time it gives the following error in dmesg.

  • There is no rule for HP-UX network adapter

    Hello I have installed HP-UX latest management pack on SCOM 2012. briefly my question is Why there is no rule or performance counter to monitor HP-UX (11iv3) servers network adapter?? I have SLES , Redhat, windows servers in my environment and I can

  • Corruption of Icons

    I don't know what happened but all of a sudden all the new icons that get displayed on my desktop and maybe other places (i haven't checked everything) are showing up as randowm icons. I just uploaded 7 pictures from my camera and they are all .jpg b